sourcebuild.texi (target attributes): Document new "inf" effective target keyword.
[gcc.git] / gcc / ChangeLog
1 2018-11-05 Paul Koning <ni1d@arrl.net>
2
3 * doc/sourcebuild.texi (target attributes): Document new "inf"
4 effective target keyword.
5
6 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
7
8 * config/s390/s390.c (s390_register_move_cost): Increase costs for
9 moves involving the CC reg.
10
11 2018-11-05 Richard Biener <rguenther@suse.de>
12
13 PR tree-optimization/87873
14 * tree-ssa-loop-manip.h (split_loop_exit_edge): Add copy_constants_p
15 argument.
16 * tree-ssa-loop-manip.c (split_loop_exit_edge): Likewise.
17 * tree-vect-loop.c (vect_transform_loop): When splitting the
18 loop exit also create forwarder PHIs for constants.
19 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
20 Handle constant to_arg, add extra checking we match up the correct
21 PHIs.
22
23 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
24
25 * config/s390/s390.md: QImode and HImode for load on condition.
26
27 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
28
29 * config/s390/predicates.md: Fix typo.
30 * config/s390/s390.md: Allow immediates for load on condition.
31
32 2018-11-05 Martin Liska <mliska@suse.cz>
33
34 * alloc-pool.h (struct pool_usage): Use SIZE_AMOUNT.
35 * bitmap.h (struct bitmap_usage): Likewise.
36 * ggc-common.c (SCALE): Remove.
37 (LABEL): Likewise.
38 (struct ggc_usage): Use SIZE_AMOUNT. And update
39 compare method.
40 * ggc-page.c (SCALE): Remove.
41 (STAT_LABEL): Remove.
42 (ggc_print_statistics): Use SIZE_AMOUNT.
43 * gimple.h (SCALE): Remove.
44 (LABEL): Likewise.
45 * input.c (ONE_K): Remove.
46 (ONE_M): Likewise.
47 (SCALE): Likewise.
48 (STAT_LABEL): Likewise.
49 (FORMAT_AMOUNT): Likewise.
50 (dump_line_table_statistics): Use SIZE_AMOUNT.
51 * mem-stats.h (struct mem_usage): Likewise.
52 * rtl.c (dump_rtx_statistics): Likewise.
53 (rtx_alloc_counts): Change type to size_t.
54 (rtx_alloc_sizes): Likewise.
55 (rtx_count_cmp): New.
56 (dump_rtx_statistics): Sort first based on counts.
57 * tree.c (tree_nodes_cmp): New.
58 (tree_codes_cmp): New.
59 (dump_tree_statistics): Sort first based on counts.
60 * system.h (ONE_K): New.
61 (ONE_M): Likewise.
62 (SIZE_SCALE): Likewise.
63 (SIZE_LABEL): Likewise.
64 (SIZE_AMOUNT): Likewise.
65 * tree-cfg.c (dump_cfg_stats): Use SIZE_AMOUNT.
66 * tree-dfa.c (dump_dfa_stats): Likewise.
67 * tree-phinodes.c (phinodes_print_statistics): Likewise.
68 * tree-ssanames.c (ssanames_print_statistics): Likewise.
69 * tree.c (dump_tree_statistics): Likewise.
70 * vec.c (struct vec_usage): Likewise.
71 * trans-mem.c (tm_mangle): Enlarge buffer in order to not
72 trigger a -Werror=format-overflow with
73 --enable-gather-detailed-stats.
74
75 2018-11-05 Martin Liska <mliska@suse.cz>
76
77 * mem-stats.h (mem_alloc_description::release_instance_overhead):
78 Return T *.
79 * vec.c (struct vec_usage): Register m_element_size.
80 (vec_prefix::register_overhead): New arguments: elements and
81 element_size.
82 (vec_prefix::release_overhead): Subtract elements.
83 * vec.h (struct vec_prefix): Change signature.
84 (va_heap::reserve): Pass proper arguments.
85 (va_heap::release): Likewise.
86
87 2018-11-05 Martin Liska <mliska@suse.cz>
88
89 * mem-stats.h (mem_alloc_description::get_list): Fix GNU coding
90 style.
91 * vec.c: Likewise.
92
93 2018-11-05 Richard Biener <rguenther@suse.de>
94
95 * tree-scalar-evolution.h (final_value_replacement_loop): Update
96 prototype.
97 * tree-scalar-evolution.c (final_value_replacement_loop): Return
98 whether anything was done.
99 (scev_const_prop): Remove constant propagation part, fold
100 remains into ...
101 * tree-ssa-loop.c (pass_scev_cprop::execute): ... here.
102 (pass_data_scev_cprop): TODO_cleanup_cfg is now done
103 conditionally.
104
105 2018-11-05 Jakub Jelinek <jakub@redhat.com>
106
107 PR tree-optimization/87859
108 * gimple-ssa-store-merging.c (struct merged_store_group): Add
109 only_constants and first_nonmergeable_order members.
110 (merged_store_group::merged_store_group): Initialize them.
111 (merged_store_group::do_merge): Clear only_constants member if
112 adding something other than INTEGER_CST store.
113 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
114 stores with order >= first_nonmergeable_order. Use
115 merged_store->only_constants instead of always recomputing it.
116 Set merged_store->first_nonmergeable_order if we've skipped any
117 stores. Attempt to merge overlapping INTEGER_CST stores that
118 we would otherwise skip.
119
120 PR sanitizer/87837
121 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
122
123 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
124
125 PR target/87853
126 * config/i386/emmintrin.h (__v16qs): New to cope with option
127 -funsigned-char.
128 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
129 (_mm_cmplt_epi8): Likewise.
130 (_mm_cmpgt_epi8): Likewise.
131
132 2018-11-05 Richard Biener <rguenther@suse.de>
133
134 PR rtl-optimization/87852
135 * fwprop.c (use_killed_between): Only consider single-defs of the
136 use whose definition statement dominates the use.
137
138 2018-11-05 Martin Liska <mliska@suse.cz>
139
140 PR web/87829
141 * doc/invoke.texi: Remove options that are
142 not disabled with -Os.
143
144 2018-11-05 Martin Liska <mliska@suse.cz>
145
146 PR c/87811
147 * doc/extend.texi: Update constrain about the last argument
148 of __builtin_expect_with_probability.
149
150 2018-11-05 Martin Liska <mliska@suse.cz>
151
152 PR c/87811
153 * predict.c (expr_expected_value_1): Verify
154 that last argument is a real constants and emit
155 error.
156
157 2018-11-05 Martin Liska <mliska@suse.cz>
158
159 PR gcov-profile/77698
160 * ipa-profile.c (ipa_profile): Adjust hotness threshold
161 only in LTO mode.
162
163 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
164
165 PR tree-optimization/86572
166 * builtins.c (c_strlen): Handle negative offsets in a safe way.
167
168 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
169
170 PR tree-optimization/87672
171 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
172 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
173
174 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
175
176 PR middle-end/58372
177 * cfgexpand.c (pass_expand::execute): Move the call to
178 finish_eh_generation in front of the call to expand_stack_alignment.
179
180 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
181
182 * common/config/i386/i386-common.c (processor_alias_table): Add
183 znver2 entry.
184 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
185 (case ${target}): Add znver2.
186 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
187 -march=native recognize znver2 processors.
188 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
189 * config/i386/i386.c (m_znver2): New definition.
190 (m_ZNVER): New definition.
191 (m_AMD_MULTIPLE): Includes m_znver2.
192 (processor_cost_table): Add znver2 entry.
193 (processor_target_table): Add znver2 entry.
194 (get_builtin_code_for_version): Set priority for
195 PROCESSOR_ZNVER2.
196 (processor_model): Add M_AMDFAM17H_ZNVER2.
197 (arch_names_table): Ditto.
198 (ix86_reassociation_width): Include znver2.
199 * config/i386/i386.h (TARGET_znver2): New definition.
200 (struct ix86_size_cost): Add TARGET_ZNVER2.
201 (enum processor_type): Add PROCESSOR_ZNVER2.
202 * config/i386/i386.md (define_attr "cpu"): Add znver2.
203 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
204 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
205 (ix86_adjust_cost): Add znver2.
206 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
207 * gcc/doc/extend.texi: Add details about znver2.
208 * gcc/doc/invoke.texi: Add details about znver2.
209
210 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
211
212 PR target/87079
213
214 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
215 pattern.
216
217 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
218
219 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
220 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
221
222 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
223
224 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
225 shrink-wrapping when -mtrack-speculation.
226
227 2018-11-02 Richard Biener <rguenther@suse.de>
228
229 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
230 (pop_cost_one_pair): Do not free pair.
231 (pop_best_coalesce): Likewise.
232 (create_coalesce_list): Initialize obstack.
233 (delete_coalesce_list): Free obstack.
234 (find_coalesce_pair): Obstack-allocate coalesce pairs.
235 (add_cost_one_coalesce): Likewise.
236 (struct live_track): Remove bitmap pointer indirections.
237 (new_live_track): Adjust.
238 (delete_live_track): Likewise.
239 (live_track_remove_partition): Likewise.
240 (live_track_add_partition): Likewise.
241 (live_track_live_p): Likewise.
242 (live_track_process_def): Likewise.
243 (live_track_clear_base_vars): Likewise.
244
245 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
246
247 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
248 * configure: Regenerate.
249 * config.in: Regenerate.
250 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
251 HAVE_AS_REGISTER_PSEUDO_OP guard.
252 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
253 !HAVE_AS_REGISTER_PSEUDO_OP support.
254 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
255 guard.
256
257 2018-11-02 Richard Biener <rguenther@suse.de>
258
259 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
260 with is_type_die.
261
262 2018-11-02 Richard Biener <rguenther@suse.de>
263
264 PR tree-optimization/87776
265 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
266 executable when iterating but running into rpo-vn-max-loop-depth
267 and not eliding the iteration.
268
269 2018-11-30 Jan Hubicka <jh@suse.cz>
270
271 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
272 TYPE_DECL.
273
274 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
275
276 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
277 prototype.
278 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
279 Combine with rs6000_address_for_fpconvert.
280 (rs6000_address_for_fpconvert): Combine with
281 rs6000_force_indexed_or_indirect_mem.
282 (rs6000_expand_vector_init): Change function call from
283 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
284 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
285 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
286 (floatsi<mode>2_lfiwax_mem): Ditto.
287 (floatunssi<mode>2_lfiwzx): Ditto.
288 (floatunssi<mode>2_lfiwzx_mem): Ditto.
289 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
290 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
291 (fix_trunc<mode>si2_stfiwx): Ditto.
292 (fixuns_trunc<mode>si2_stfiwx): Ditto.
293 (float_<mode>si2_hw): Ditto.
294 (floatuns_<mode>si2_hw): Ditto.
295 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
296 (vsx_splat_<mode>): Ditto.
297
298 2018-11-01 Joseph Myers <joseph@codesourcery.com>
299
300 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
301 at end of assembler input text.
302 * configure: Regenerate.
303
304 2018-11-01 Jakub Jelinek <jakub@redhat.com>
305
306 PR tree-optimization/87826
307 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
308 negative or larger or equal to type's precision.
309
310 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
311
312 * opts.c (default_options_table): Do not enable
313 OPT_fdelayed_branch at -Og.
314 * doc/invoke.texi (-fdelayed-branch): Document it.
315
316 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
317
318 * optabs-libfuncs.c (build_libfunc_function_visibility):
319 New, split out from...
320 (build_libfunc_function): ... here.
321 (init_one_libfunc_visibility): New, split out from ...
322 (init_one_libfunc): ... here.
323
324 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
325 scratch register need not be early-clobber. Document the reason
326 why we cannot use ST<OP>.
327
328 2018-10-31 Joseph Myers <joseph@codesourcery.com>
329
330 PR bootstrap/82856
331 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
332 line for second argument of AC_DEFINE_UNQUOTED.
333 * doc/install.texi (Tools/packages necessary for modifying GCC):
334 Update to autoconf 2.69 and automake 1.15.1.
335 * aclocal.m4, config.in, configure: Regenerate.
336
337 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
338
339 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
340 initialization.
341
342 2018-10-31 Martin Liska <mliska@suse.cz>
343
344 PR driver/83193
345 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
346 Add new argument invalid_extension.
347 (aarch64_get_all_extension_candidates): New function.
348 (aarch64_rewrite_selected_cpu): Add NULL to function call.
349 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
350 new argument.
351 (aarch64_get_all_extension_candidates): New function.
352 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
353 argument invalid_extension.
354 (aarch64_parse_cpu): Likewise.
355 (aarch64_print_hint_for_extensions): New function.
356 (aarch64_validate_mcpu): Provide hint about invalid extension.
357 (aarch64_validate_march): Likewise.
358 (aarch64_handle_attr_arch): Pass new argument.
359 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
360 (aarch64_handle_attr_isa_flags): Likewise.
361
362 2018-10-31 Richard Biener <rguenther@suse.de>
363
364 PR middle-end/70359
365 PR middle-end/86270
366 * tree-outof-ssa.c (insert_backedge_copies): Restrict
367 copy generation to useful cases. Place the copy before
368 the definition of the backedge value when possible.
369
370 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
371
372 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
373 * config/arc/arc.c (arc_active_insn): New function.
374 (check_store_cacheline_hazard): Likewise.
375 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
376 (arc_override_options): Disable delay slot scheduler for older
377 A7.
378 (arc_store_addr_hazard_p): New implementation, old one renamed to
379 ...
380 (arc_store_addr_hazard_internal_p): Renamed.
381 (arc_reorg): Don't combine into brcc instructions which are part
382 of hardware hazard solution.
383 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
384 (tune_arc700): Likewise.
385 * config/arc/arc.opt (arc7xx): New tune value.
386 * config/arc/arc700.md: Improve A7 scheduler.
387
388 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
389
390 * config/arc/arc.c (arc_override_options): Remove
391 TARGET_COMPACT_CASESI.
392 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
393 (CASE_VECTOR_MODE): Likewise.
394 (CASE_VECTOR_PC_RELATIVE): Likewise.
395 (CASE_VECTOR_SHORTEN_MODE): Likewise.
396 (CASE_VECTOR_SHORTEN_MODE1): Delete.
397 (ADDR_VEC_ALIGN): Update.
398 (ASM_OUTPUT_CASE_LABEL): Undefine.
399 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
400 (TARGET_BI_BIH): Define.
401 (DEFAULT_BRANCH_INDEX): Likewise.
402 * config/arc/arc.md (casesi): Rework to accept BI/BIH
403 instructions, remove compact_casesi use case.
404 (casesi_compact_jump): Remove.
405 (casesi_dispatch): New pattern.
406 * config/arc/arc.opt: Add mbranch-index option. Deprecate
407 compact_casesi option.
408 * doc/invoke.texi: Document mbranch-index option.
409
410 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
411
412 * config/arc/arc.c (arc_get_tp): Remove function.
413 (arc_emit_call_tls_get_addr): Likewise.
414 (arc_call_tls_get_addr): New function.
415 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
416 * config/arc/arc.md (tls_load_tp_soft): Remove.
417 (tls_gd_get_addr): Likewise.
418
419 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
420
421 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
422 (mulsi3_600_lib): Remove pattern.
423 (umulsi3_highpart_600_lib_le): Likewise.
424 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
425 (umulsidi3): Remove call to umulsidi3_600_lib.
426 (umulsidi3_600_lib): Remove pattern.
427 (peephole2): Remove peephole using the above deprecated patterns.
428
429 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
430
431 PR target/87374
432 * config/arm/arm.c (arm_option_check_internal): Disable the combined
433 use of -mslow-flash-data and -mword-relocations.
434 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
435 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
436 flag_pic.
437 * doc/invoke.texi (-mword-relocations): Mention conflict with
438 -mslow-flash-data.
439 (-mslow-flash-data): Reciprocally.
440
441 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
442
443 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
444 16-byte modes held in GP registers to use an even regno.
445
446 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
447 (aarch64_atomic_ldop_supported_p): Remove.
448 (aarch64_gen_atomic_ldop): Remove.
449 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
450 Fully expand LSE operations here.
451 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
452 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
453 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
454 and use ATOMIC_LDOP instead; use register_operand for the input;
455 drop the split and emit insns directly.
456 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
457 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
458 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
459
460 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
461 (aarch64_gen_atomic_ldop): Don't call it.
462 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
463 Use aarch64_reg_or_zero.
464 (aarch64_atomic_exchange<ALLI>): Likewise.
465 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
466 operand 0; use aarch64_reg_or_zero for input; merge ...
467 (@aarch64_atomic_swp<ALLI>): ... this and remove.
468
469 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
470 (aarch64_split_compare_and_swap): Use it.
471 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
472 test oldval against the proper predicate.
473 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
474 Use nonmemory_operand for expected.
475 (cas_short_expected_pred): New.
476 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
477 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
478 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
479 (aarch64_plushi_operand): New.
480
481 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
482 Force oldval into the rval register for TARGET_LSE; emit the compare
483 during initial expansion so that it may be deleted if unused.
484 (aarch64_gen_atomic_cas): Remove.
485 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
486 Change =&r to +r for operand 0; use match_dup for operand 2;
487 remove is_weak and mod_f operands as unused. Drop the split
488 and merge with...
489 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
490 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
491 (@aarch64_atomic_cas<GPI>): Similarly.
492
493 2018-10-31 Richard Biener <rguenther@suse.de>
494
495 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
496 using ABSU_EXPR.
497
498 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
499
500 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
501 * config/aarch64/aarch64.md: Include saphira.md
502 * config/aarch64/saphira.md: New file for pipeline description.
503
504 2018-10-30 Martin Sebor <msebor@redhat.com>
505
506 PR middle-end/87041
507 * gimple-ssa-sprintf.c (format_directive): Use %G to include
508 inlining context.
509 (sprintf_dom_walker::compute_format_length):
510 Avoid setting POSUNDER4K here.
511 (get_destination_size): Handle null argument values.
512 (get_user_idx_format): New function.
513 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
514 functions, including user-defined with attribute format printf.
515 Use %G to include inlining context.
516 Set POSUNDER4K here.
517
518 2018-10-30 Jan Hubicka <jh@suse.cz>
519
520 * params.def (lto-partitions): Bump from 32 to 128.
521
522 2018-10-30 Jan Hubicka <jh@suse.cz>
523
524 * tree.c
525 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
526 head in file.
527 (free_lang_data_in_type): Forward declare.
528 (fld_type_variant_equal_p): New function.
529 (fld_type_variant): New function
530 (fld_incomplete_types): New hash.
531 (fld_incomplete_type_of): New function
532 (fld_simplfied-type): New function.
533 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
534 (free_lang_data): Allocate and free fld_incomplete_type; update call
535 of free_lang_data_in_decl.
536
537 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
538
539 * gcov.c (output_lines): Remove duplicate line.
540
541 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
542
543 * config/rs6000/rs6000.md (bswapdi2): Force address into register
544 if not in indexed or indirect form.
545 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
546 (bswapdi2_store): Ditto.
547 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
548 helper function.
549 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
550 Prototype for helper function.
551
552 2018-10-30 Martin Sebor <msebor@redhat.com>
553
554 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
555 (target, pragma GCC optimize, pragma GCC target): Ditto.
556
557 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
558
559 * doc/extend.texi: Fix prototype and description of
560 __builtin_expect_with_probability.
561
562 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
563
564 * cgraph.h (clone_function_name_1): Replaced by new
565 clone_function_name_numbered that takes name as string; for
566 privatize_symbol_name_1 use only.
567 (clone_function_name): Renamed to
568 clone_function_name_numbered to be explicit about numbering.
569 (clone_function_name): New two-argument function that does
570 not number its output.
571 (clone_function_name): New three-argument function that
572 takes a number to append to its output.
573 * cgraphclones.c (duplicate_thunk_for_node):
574 (clone_function_name_1): Renamed.
575 (clone_function_name_numbered): Two new functions.
576 (clone_function_name): Improved documentation.
577 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
578 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
579 * final.c (final_scan_insn_1): Use the new clone_function_name
580 without numbering.
581 * multiple_target.c (create_dispatcher_calls): Ditto.
582 (create_target_clone): Ditto.
583 * omp-expand.c (grid_expand_target_grid_body): Ditto.
584 * omp-low.c (create_omp_child_function_name): Ditto.
585 * omp-simd-clone.c (simd_clone_create): Ditto.
586 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
587 new clone_function_name without numbering.
588
589 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
590
591 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
592 Assert that the allocation size is not zero.
593
594 2018-10-30 Richard Biener <rguenther@suse.de>
595
596 PR tree-optimization/87800
597 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
598 non-induction or reduction PHIs.
599
600 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org
601
602 * config/aarch64/falkor-tag-collision-avoidance.c
603 (execute_tag_collision_avoidance): Call df_note_add_problem.
604
605 2018-10-30 Martin Liska <mliska@suse.cz>
606
607 * doc/extend.texi: Fix typo in documentation
608 of __builtin_expect_with_probability.
609
610 2018-10-29 David Malcolm <dmalcolm@redhat.com>
611
612 PR c++/87721
613 * input.c (get_substring_ranges_for_loc): Detect if
614 linemap_resolve_location gives us a NULL map, and reject
615 this case.
616
617 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
618
619 * config.gcc (xstormy16-*-elf): Set tm_d_file.
620
621 2018-10-29 David Malcolm <dmalcolm@redhat.com>
622 Martin Sebor <msebor@redhat.com>
623 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
624
625 * doc/ux.texi (Quoting): New subsection, adapted from material at
626 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
627 MartinSebor and ManuelLopezIbanez.
628 (Fix-it hints): Note that fix-it hints shouldn't be marked for
629 translation.
630
631 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
632
633 PR middle-end/87469
634 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
635 max value.
636
637 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
638
639 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
640
641 2018-10-29 Paul Koning <ni1d@arrl.net>
642
643 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
644
645 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
646
647 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
648 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
649 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
650 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
651 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
652 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
653 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
654 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
655 Change 'vector' to '__vector'.
656 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
657 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
658 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
659 _mm_avg_pu16): Likewise. And, whitespace corrections.
660
661 2018-10-29 Richard Biener <rguenther@suse.de>
662
663 PR tree-optimization/87785
664 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
665 internal defs.
666
667 2018-10-29 Olivier Hainque <hainque@adacore.com>
668
669 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
670
671 2018-10-29 Olivier Hainque <hainque@adacore.com>
672
673 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
674 ports configuration macro, defaults to "gnu".
675 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
676 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
677
678 2018-10-29 Olivier Hainque <hainque@adacore.com>
679
680 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
681
682 2018-10-29 Richard Biener <rguenther@suse.de>
683
684 PR tree-optimization/87790
685 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
686 (vect_make_slp_decision): Adjust.
687 (vect_slp_analyze_bb_1): Likewise.
688 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
689 edges.
690
691 2018-10-29 Richard Biener <rguenther@suse.de>
692
693 PR tree-optimization/87785
694 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
695 and processing.
696 (vect_build_slp_tree): Likewise.
697 (vect_gather_slp_loads): New function.
698 (vect_analyze_slp_instance): Gather loads separately from the
699 SLP tree build.
700
701 2018-10-29 Martin Liska <mliska@suse.cz>
702
703 * Makefile.in: Make dependency to json.o.
704 * doc/gcov.texi: Document new JSON format, remove
705 old intermediate format documentation.
706 * gcov.c (struct function_info): Come up with m_name and
707 m_demangled_name.
708 (function_info::function_info): Initialize it.
709 (function_info::~function_info): Release it.
710 (main): Rename flag_intermediate_format to flag_json_format.
711 (print_usage): Describe --json-format.
712 (process_args): Set flag_json_format.
713 (output_intermediate_line): Remove.
714 (output_intermediate_json_line): Likewise.
715 (get_gcov_intermediate_filename): Return new extension
716 ".gcov.json.gz".
717 (output_intermediate_file): Implement JSON emission.
718 (output_json_intermediate_file): Implement JSON emission.
719 (generate_results): Use ::get_name for function name.
720 Handle JSON output file.
721 (read_graph_file): Use ::get_name instead of cplus_demangle.
722 (read_count_file): Likewise.
723 (solve_flow_graph): Likewise.
724 (add_line_counts): Likewise.
725 (accumulate_line_counts): Use new flag_json_format.
726 (output_function_details): Use ::get_name instead of cplus_demangle.
727 (output_lines): Likewise.
728 * json.cc (test_writing_literals): Add new tests.
729 * json.h (class literal): Add new boolean constructor.
730
731 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
732
733 PR rtl-optimization/87701
734 PR rtl-optimization/87780
735 * combine.c (make_more_copies): Rewrite.
736
737 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
738
739 * doc/generic.texi (ABSU_EXPR): Document.
740 * match.pd (absu(x)*absu(x) -> x*x): Handle.
741 (absu(absu(X)) -> absu(X)): Likewise.
742 (absu(-X) -> absu(X)): Likewise.
743 (absu(X) where X is nonnegative -> X): Likewise.
744
745 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
746
747 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
748 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
749 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
750 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
751 (s-tm-texi): Also check timestamp on d-target.def.
752 (generated_files): Add TM_D_H and d-target-hooks-def.h.
753 (build/genhooks.o): Also depend on D_TARGET_DEF.
754 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
755 variables.
756 * config/aarch64/aarch64-d.c: New file.
757 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
758 Define.
759 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
760 prototype.
761 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
762 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
763 * config/arm/arm-d.c: New file.
764 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
765 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
766 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
767 * config/arm/t-arm (arm-d.o): New rule.
768 * config/default-d.c: New file.
769 * config/glibc-d.c: New file.
770 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
771 * config/i386/i386-d.c: New file.
772 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
773 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
774 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
775 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
776 * config/i386/t-i386 (i386-d.o): New rule.
777 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
778 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
779 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
780 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
781 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
782 * config/mips/mips-d.c: New file.
783 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
784 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
785 * config/mips/t-mips (mips-d.o): New rule.
786 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
787 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
788 * config/powerpcspe/powerpcspe-d.c: New file.
789 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
790 New prototype.
791 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
792 Support GNU D by using 0 as the language type.
793 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
794 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
795 * config/riscv/riscv-d.c: New file.
796 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
797 prototype.
798 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
799 * config/riscv/t-riscv (riscv-d.o): New rule.
800 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
801 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
802 * config/rs6000/rs6000-d.c: New file.
803 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
804 prototype.
805 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
806 Support GNU D by using 0 as the language type.
807 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
808 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
809 * config/s390/s390-d.c: New file.
810 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
811 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
812 * config/s390/t-s390 (s390-d.o): New rule.
813 * config/sparc/sparc-d.c: New file.
814 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
815 prototype.
816 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
817 * config/sparc/t-sparc (sparc-d.o): New rule.
818 * config/t-glibc (glibc-d.o): New rule.
819 * configure: Regenerated.
820 * configure.ac (tm_d_file): New variable.
821 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
822 * doc/contrib.texi (Contributors): Add self for the D frontend.
823 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
824 * doc/install.texi (Configuration): Mention libphobos as an option for
825 --enable-shared. Mention d as an option for --enable-languages.
826 (Testing): Mention check-d as a target.
827 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
828 name suffixes. Mention d as a -x option.
829 * doc/sourcebuild.texi (Top Level): Mention libphobos.
830 * doc/standards.texi (Standards): Add section on D language.
831 * doc/tm.texi: Regenerated.
832 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
833 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
834 * dwarf2out.c (is_dlang): New function.
835 (gen_compile_unit_die): Use DW_LANG_D for D.
836 (declare_in_namespace): Return module die for D, instead of adding
837 extra declarations into the namespace.
838 (gen_namespace_die): Generate DW_TAG_module for D.
839 (gen_decl_die): Handle CONST_DECLSs for D.
840 (dwarf2out_decl): Likewise.
841 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
842 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
843 kinds of aggregates.
844 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
845 * genhooks.c: Include d/d-target.def.
846
847 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
848
849 PR target/85669
850 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
851 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
852 (STACK_DYNAMIC_OFFSET): Likewise.
853
854 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
855
856 PR target/80024
857 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
858 error message.
859
860 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
861
862 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
863 return type and other typos.
864
865 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
866
867 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
868 a shorter sequence with fewer branches.
869 (emit_final_str_compare_gpr): Ditto.
870
871 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
872
873 * config/rs6000/tmmintrin.h: New file.
874 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
875
876 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
877
878 * config/rs6000/mmintrin.h: Enable 32bit compilation.
879 * config/rs6000/xmmintrin.h: Likewise.
880
881 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
882
883 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
884
885 2018-10-26 Richard Biener <rguenther@suse.de>
886
887 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
888 and wrapper.
889 (vect_mark_slp_stmts_relevant): Likewise.
890 (vect_detect_hybrid_slp_stmts): Likewise.
891 (vect_bb_slp_scalar_cost): Likewise.
892 (vect_remove_slp_scalar_calls): Likewise.
893
894 2018-10-26 Jan Hubicka <jh@suse.cz>
895
896 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
897 (warn_types_mismatch): Fix walk of DECL_NAME.
898 (odr_types_equivalent_p): Fix overactive assert.
899
900 2018-10-26 Richard Biener <rguenther@suse.de>
901
902 PR tree-optimization/87105
903 * tree-vectorizer.h (_slp_tree::refcnt): New member.
904 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
905 refcnt.
906 (vect_create_new_slp_node): Initialize refcnt to one.
907 (bst_traits): Move.
908 (scalar_stmts_set_t, bst_fail): Remove.
909 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
910 (vect_build_slp_tree): Add bst_map argument and lookup
911 already created SLP nodes.
912 (vect_print_slp_tree): Handle a SLP graph, print SLP node
913 addresses.
914 (vect_slp_rearrange_stmts): Handle a SLP graph.
915 (vect_analyze_slp_instance): Adjust and free SLP nodes from
916 the CSE map. Fix indenting.
917 (vect_schedule_slp_instance): Add short-cut.
918
919 2018-10-26 Martin Liska <mliska@suse.cz>
920
921 PR testsuite/86158
922 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
923 addr_expr and not with pointers.
924
925 2018-10-26 Jan Hubicka <jh@suse.cz>
926
927 * tree.c (free_lang_data_in_type): Only check main variants.
928 * ipa-devirt.c (warn_odr): Make static.
929 (types_same_for_odr): Drop strict variant.
930 (types_odr_comparable): Likewise.
931 (odr_or_derived_type_p): Look for main variants.
932 (odr_name_hasher::equal): Cleanup comment.
933 (odr_subtypes_equivalent): Add warn and warned arguments; check main
934 variants.
935 (type_variants_equivalent_p): break out from ...
936 (odr_types_equivalent): ... here; go for main variants where needed.
937 (warn_odr): ... here; turn static.
938 (warn_types_mismatch): Compare mangled names of main variants.
939 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
940 (type_with_linkage_p): Sanity check that we look at main variant.
941 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
942 * tree.h (types_same_for_odr): Drop strict argument.
943
944 2018-10-26 Richard Biener <rguenther@suse.de>
945
946 PR tree-optimization/87746
947 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
948 Simplify and fix WRT strided store groups with size not
949 equal to step in element count.
950 (vect_analyze_group_access_1): Dump the whole group.
951
952 2018-10-25 Carl Love <cel@us.ibm.com>
953
954 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
955 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
956 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
957 precicion entry for each overloaded builtin.
958 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
959 VSCEDPUO): Rename overloaded name.
960 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
961 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
962 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
963 define_expand for xscmpexqp instruction.
964 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
965
966 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
967 Jinsong Ji <jji@us.ibm.com>
968
969 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
970 function with vec_sl.
971 (_mm_slli_epi32): Likewise.
972 (_mm_slli_epi64): Likewise.
973 (_mm_srai_epi16): Replace deprecated function with vec_sra.
974 (_mm_srai_epi32): Likewise.
975 (_mm_srli_epi16): Replace deprecated function with vec_sr.
976 (_mm_srli_epi32): Likewise.
977 (_mm_srli_epi64): Likewise.
978 (_mm_sll_epi16): Replace deprecated function with vec_sl.
979 (_mm_sll_epi32): Likewise.
980 (_mm_sll_epi64): Likewise.
981 (_mm_sra_epi16): Replace deprecated function with vec_sra.
982 (_mm_sra_epi32): Likewise.
983 (_mm_srl_epi16): Replace deprecated function with vec_sr.
984 (_mm_srl_epi32): Likewise.
985 (_mm_srl_epi64): Likewise.
986
987 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
988 Jinsong Ji <jji@us.ibm.com>
989
990 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
991 comparison operators with vec_cmp* for compatibility due to
992 unfortunate history; clean up formatting and use types more
993 appropriately.
994 (_mm_sll_epi32): Likewise.
995 (_mm_sll_epi64): Likewise.
996 (_mm_srl_epi16): Likewise.
997 (_mm_srl_epi32): Likewise.
998 (_mm_srl_epi64): Likewise.
999
1000 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
1001 Jinsong Ji <jji@us.ibm.com>
1002
1003 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
1004 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
1005 __vector __bool int. Use vec_cmpgt in preference to deprecated
1006 function vec_vcmpgtfp.
1007 (_mm_max_ps): Likewise.
1008
1009 2018-10-25 Jeff Law <law@redhat.com>
1010
1011 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
1012 if returning false.
1013
1014 2018-10-25 Martin Sebor <msebor@redhat.com>
1015
1016 * doc/extend.texi (aligned): Expand attribute description.
1017 (Alignment): Rename section. Discuss function arguments.
1018
1019 2018-10-25 Jan Hubicka <jh@suse.cz>
1020
1021 * ipa-devirt.c (main_odr_variant): Remove.
1022 (hash_odr_name, types_same_for_odr, types_odr_comparable,
1023 odr_name_hasher::equal, odr_subtypes_equivalent_p):
1024 Drop use of main_odr_variant.
1025 (add_type_duplicate): Silence confused warnings on integer types.
1026 (get_odr_type): Always look for main variant.
1027 (register_odr_type): Simplify.
1028
1029 2018-10-25 Richard Biener <rguenther@suse.de>
1030
1031 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
1032 Initialize ng to silence error with release checking bootstrap.
1033
1034 2018-10-25 Richard Biener <rguenther@suse.de>
1035
1036 * tree-if-conv.c: Include tree-ssa-sccvn.h.
1037 (tree_if_conversion): Run CSE on the if-converted loop body.
1038
1039 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
1040
1041 * config/s390/constraints.md (ZL): New constraint.
1042 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
1043 operands.
1044 * config/s390/s390.md (movdi_larl): Remove.
1045 (movdi_64): Add the LARL alternative.
1046
1047 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
1048
1049 PR bootstrap/87747
1050 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
1051 (RTX_CODE_HWINT_P): New macro.
1052 (rtx_code_size): Use RTX_CODE_HWINT_P ().
1053
1054 2018-10-25 Jan Hubicka <jh@suse.cz>
1055
1056 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
1057 is anonymous.
1058
1059 2018-10-25 Richard Biener <rguenther@suse.de>
1060
1061 PR tree-optimization/87665
1062 PR tree-optimization/87745
1063 * tree-vectorizer.h (get_earlier_stmt): Remove.
1064 (get_later_stmt): Pick up UID from the original non-pattern stmt.
1065
1066 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
1067
1068 * options.texi (Deprecated): Move list to Var section.
1069
1070 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
1071 Jinsong Ji <jji@us.ibm.com>
1072
1073 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
1074 __vector long to __vector long long.
1075 (_mm_cvtpd_ps): Likewise.
1076 (_mm_cvttpd_epi32): Likewise.
1077 (_mm_cvtpi32_pd): Likewise.
1078 (_mm_unpackhi_epi64): Likewise.
1079 (_mm_unpacklo_epi64): Likewise.
1080
1081 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
1082
1083 PR rtl-optimization/87720
1084 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
1085
1086 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
1087
1088 * gimple-ssa-isolate-paths.c
1089 (find_implicit_erroneous_behavior): Do not change code if the
1090 pass is running for warnings only.
1091 (find_explicit_erroneous_behavior): Likewise.
1092
1093 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
1094
1095 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
1096 Define as rs6000_mangle_decl_assembler_name.
1097 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
1098 long double to IEEE long double, switch the names of the long
1099 double built-in functions to be <func>f128 instead of <func>l.
1100
1101 2018-10-24 Martin Sebor <msebor@redhat.com>
1102
1103 * doc/extend.texi (nonnull): List no-argument form. Reference
1104 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
1105
1106 2018-10-24 Richard Biener <rguenther@suse.de>
1107
1108 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
1109
1110 2018-10-24 Martin Liska <mliska@suse.cz>
1111
1112 PR tree-optimization/84436
1113 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
1114 Remove.
1115 (switch_conversion::contains_linear_function_p): New.
1116 (switch_conversion::build_one_array): Support linear
1117 transformation on input.
1118 * tree-switch-conversion.h (struct switch_conversion): Add
1119 contains_linear_function_p declaration.
1120
1121 2018-10-24 Richard Biener <rguenther@suse.de>
1122
1123 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
1124 if its argument is CONSTANT_CLASS_P.
1125
1126 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
1127
1128 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
1129 it is wrong for forward declarations.
1130
1131 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
1132
1133 * config/s390/s390.c (s390_check_qrst_address): Add the missing
1134 SYMBOL_REF_P () check.
1135
1136 2018-10-24 Richard Biener <rguenther@suse.de>
1137
1138 PR tree-optimization/87105
1139 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
1140 dump classification.
1141 (vect_analyze_data_ref_accesses): Handle duplicate loads and
1142 stores by splitting the affected group after the fact.
1143 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
1144 fail the SLP build because of size constraints.
1145
1146 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1147
1148 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
1149 * configure: Regenerate.
1150 * config.in: Regenerate.
1151 * varasm.c (mergeable_string_section): Use readonly_data_section
1152 if linker doesn't support SHF_MERGE with alignment > 8.
1153 (mergeable_constant_section): Likewise.
1154
1155 2018-10-24 Richard Biener <rguenther@suse.de>
1156
1157 PR tree-optimization/84013
1158 * tree-ssa-structalias.c (struct msdi_data): New struct for
1159 marshalling data to walk_stmt_load_store_ops.
1160 (maybe_set_dependence_info): Refactor as callback for
1161 walk_stmt_load_store_ops.
1162 (compute_dependence_clique): Set restrict info on all stmt kinds.
1163
1164 2018-10-24 Martin Liska <mliska@suse.cz>
1165
1166 * cgraph.c (cgraph_node::dump):
1167 Remove reduntant dumps and make tp_first_run dump more compact.
1168
1169 2018-10-24 Richard Biener <rguenther@suse.de>
1170
1171 PR tree-optimization/87665
1172 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
1173 to reflect reality.
1174
1175 2018-10-12 Jeff Law <law@redhat.com>
1176
1177 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
1178 for H8/S.
1179
1180 2018-10-23 Richard Biener <rguenther@suse.de>
1181
1182 * tree-vrp.c (add_assert_info): Guard dump_printf with
1183 dump_enabled_p.
1184 * gimple-ssa-evrp-analyze.c
1185 (evrp_range_analyzer::record_ranges_from_incoming_edge):
1186 Use value_range::ignore_equivs_equal_p.
1187
1188 2018-10-23 Richard Biener <rguenther@suse.de>
1189
1190 PR tree-optimization/87105
1191 PR tree-optimization/87608
1192 * passes.def (pass_all_early_optimizations): Add early phi-opt
1193 after dce.
1194 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
1195 addition to debug stmts.
1196 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
1197 and abs replacement early.
1198 * tree-cfg.c (gimple_empty_block_p): Likewise.
1199
1200 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
1201
1202 PR target/86383
1203 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
1204 specified to configure.
1205 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
1206
1207 2018-10-23 Richard Biener <rguenther@suse.de>
1208
1209 PR tree-optimization/87700
1210 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
1211
1212 2018-10-23 Jakub Jelinek <jakub@redhat.com>
1213
1214 PR target/87674
1215 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
1216 second argument from __mmask16 to __mmask8.
1217 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
1218 _mm_mask_packs_epi32): Likewise.
1219 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
1220 Likewise.
1221 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
1222
1223 2018-10-23 Richard Biener <rguenther@suse.de>
1224
1225 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
1226
1227 2018-10-23 Richard Biener <rguenther@suse.de>
1228
1229 PR tree-optimization/86144
1230 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
1231 over simd attribute.
1232
1233 2018-10-23 Richard Biener <rguenther@suse.de>
1234
1235 PR tree-optimization/87693
1236 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
1237 the case we do not find the taken edge.
1238
1239 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
1240 Jinsong Ji <jji@us.ibm.com>
1241
1242 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
1243 (_mm_store_pd): Use unaligned vector type for pointer cast.
1244 (_mm_maskmoveu_si128): Likewise.
1245 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
1246 (_mm_store_ps): Use unaligned vector type for pointer cast.
1247
1248 2018-10-22 Paul Koning <ni1d@arrl.net>
1249
1250 * symtab.c (symtab_node::increase_alignment): Correct max
1251 alignment check.
1252
1253 2018-10-22 Yury Gribov <tetra2005@gmail.com>
1254
1255 PR tree-optimization/87633
1256 * match.pd: Do not generate unordered integer comparisons.
1257
1258 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1259
1260 PR rtl-optimization/87600
1261 * combine.c: Add include of expr.h.
1262 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
1263 register to a pseudo.
1264 (make_more_copies): New function, add a copy to a new pseudo after
1265 the moves from hard registers into pseudos.
1266 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
1267 later. Call make_more_copies.
1268
1269 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
1270
1271 * lra-constraints.c (process_alt_operands): New local array,
1272 matching_early_clobber. Check matching_early_clobber before
1273 decrementing reject, and set matching_early_clobber after.
1274
1275 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1276
1277 PR target/87598
1278 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
1279 call output_addr_const and hope for the best.
1280
1281 2018-10-22 Richard Biener <rguenther@suse.de>
1282
1283 * gimple-ssa-evrp-analyze.c
1284 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
1285 smarter about what ranges to use.
1286 * tree-vrp.c (add_assert_info): Dump here.
1287 (register_edge_assert_for_2): Instead of here at multiple but
1288 not all places.
1289
1290 * gcc.dg/tree-ssa/evrp12.c: New testcase.
1291 * gcc.dg/predict-6.c: Adjust.
1292 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
1293 * gcc.dg/tree-ssa/vrp02.c: Likewise.
1294 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
1295
1296 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
1297 Richard Biener <rguenther@suse.de>
1298
1299 * bitmap.h: Update data structure documentation, including a
1300 description of bitmap views as either linked-lists or splay trees.
1301 (struct bitmap_element_def): Update comments for splay tree bitmaps.
1302 (struct bitmap_head_def): Likewise.
1303 (bitmap_list_view, bitmap_tree_view): New prototypes.
1304 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
1305 tree_form fields.
1306 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
1307 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
1308 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
1309 released bitmap element here.
1310 (bitmap_element_free): Remove.
1311 (bitmap_elt_clear_from): Work on splay tree bitmaps.
1312 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
1313 this function similar ones such that linked-list bitmap implementation
1314 functions are grouped.
1315 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
1316 and moved for grouping.
1317 (bitmap_list_insert_element_after): Renamed from
1318 bitmap_elt_insert_after, and moved for grouping.
1319 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
1320 (bitmap_tree_link_left, bitmap_tree_link_right,
1321 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
1322 bitmap_tree_link_element, bitmap_tree_unlink_element,
1323 bitmap_tree_find_element): New functions for splay-tree bitmap
1324 implementation.
1325 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
1326 Renamed and moved, see above entries.
1327 (bitmap_tree_listify_from): New function to convert part of a splay
1328 tree bitmap to a linked-list bitmap.
1329 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
1330 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
1331 (bitmap_find_bit): Remove.
1332 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
1333 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
1334 Handle splay tree bitmaps.
1335 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
1336 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
1337 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
1338 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
1339 bitmap_intersect_compl_p, bitmap_ior_and_compl,
1340 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
1341 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
1342 corresponding changes to use linked-list specific bitmap_element
1343 manipulation functions as applicable for efficiency.
1344 (bitmap_tree_to_vec): New function.
1345 (debug_bitmap_elt_file): New function split out from ...
1346 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
1347 (bitmap_print): Likewise.
1348
1349 PR tree-optimization/63155
1350 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
1351 SSA edge worklists.
1352 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
1353 in tree-view.
1354
1355 2018-10-22 Martin Liska <mliska@suse.cz>
1356
1357 PR tree-optimization/87686
1358 Revert
1359 2018-08-29 Martin Liska <mliska@suse.cz>
1360
1361 * tree-switch-conversion.c (switch_conversion::expand):
1362 Strenghten assumption about gswitch statements.
1363
1364 2018-10-22 Martin Liska <mliska@suse.cz>
1365
1366 * ipa-icf.c (sem_item::compare_attributes): Remove.
1367 (sem_item::compare_referenced_symbol_properties): Use
1368 attribute_list_equal instead.
1369 (sem_function::equals_wpa): Likewise.
1370 * ipa-icf.h: Remove compare_attributes.
1371
1372 2018-10-22 Richard Biener <rguenther@suse.de>
1373
1374 PR middle-end/87682
1375 * mem-stats.h (mem_usage::operator==): Fix pasto.
1376
1377 2018-10-22 Richard Biener <rguenther@suse.de>
1378
1379 PR tree-optimization/87640
1380 * tree-vrp.c (set_value_range_with_overflow): Decompose
1381 incomplete result.
1382 (extract_range_from_binary_expr_1): Adjust.
1383
1384 2018-10-22 Martin Jambor <mjambor@suse.cz>
1385
1386 * tree-eh.h (stmt_could_throw_p): Add function parameter.
1387 (stmt_can_throw_external): Likewise.
1388 (stmt_can_throw_internal): Likewise.
1389 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
1390 (lower_eh_constructs_2): Likewise.
1391 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
1392 (stmt_can_throw_external): Likewise.
1393 (stmt_can_throw_internal): Likewise.
1394 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
1395 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
1396 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
1397 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
1398 (pass_lower_eh_dispatch::execute): Pass cfun to
1399 stmt_can_throw_external.
1400 (cleanup_empty_eh): Likewise.
1401 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
1402 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
1403 stmt_can_throw_external instead of pushing it to cfun.
1404 (symbol_table::create_edge): Likewise.
1405 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
1406 stmt_can_throw_internal.
1407 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
1408 to stmt_could_throw_p.
1409 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
1410 stmt_can_throw_internal.
1411 (pass_store_merging::execute): Likewise.
1412 * gimple-ssa-strength-reduction.c
1413 (find_candidates_dom_walker::before_dom_children): Pass cfun to
1414 stmt_could_throw_p.
1415 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
1416 stmt_can_throw_internal.
1417 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
1418 to stmt_can_throw_external.
1419 (check_stmt): Pass cfun to stmt_could_throw_p.
1420 (check_stmt): Pass cfun to stmt_can_throw_external.
1421 (pass_nothrow::execute): Likewise.
1422 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
1423 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
1424 stmt_can_throw_internal.
1425 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
1426 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
1427 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
1428 * tree-complex.c (expand_complex_libcall): Pass cfun to
1429 stmt_could_throw_p and to stmt_can_throw_internal.
1430 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
1431 * tree-inline.c (copy_edges_for_bb): Likewise.
1432 (maybe_move_debug_stmts_to_successors): Likewise.
1433 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
1434 stmt_could_throw_p.
1435 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
1436 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
1437 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
1438 stmt_can_throw_internal.
1439 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
1440 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
1441 stmt_could_throw_p.
1442 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
1443 stmt_can_throw_internal.
1444 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
1445 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
1446 stmt_could_throw_p.
1447 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
1448 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
1449 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
1450 (convert_mult_to_fma_1): Likewise.
1451 (convert_to_divmod): Likewise.
1452 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
1453 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
1454 * tree-ssa-propagate.c
1455 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
1456 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
1457 (maybe_optimize_range_tests): Likewise.
1458 (linearize_expr_tree): Likewise.
1459 (reassociate_bb): Likewise.
1460 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
1461 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
1462 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
1463 (handle_char_store): Likewise.
1464 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
1465 stmt_can_throw_internal.
1466 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
1467 stmt_could_throw_p.
1468 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
1469 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
1470 (vectorizable_simd_clone_call): Likewise.
1471 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
1472 (gimple_stringop_fixed_value): Likewise.
1473
1474 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
1475
1476 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
1477 literal pool references.
1478 (s390_check_qrst_address): Adapt to the new behavior of
1479 s390_loadrelative_operand_p ().
1480
1481 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1482
1483 PR target/72782
1484 * config/i386/sse.md (*andnot<mode>3_bcst): New.
1485
1486 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1487
1488 PR target/72782
1489 * config/i386/sse.md (*<code><mode>3_bcst): New.
1490
1491 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1492
1493 PR target/72782
1494 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
1495 V4DI, V16SI and V8DI.
1496 (*sub<mode>3<mask_name>_bcst): New.
1497 (*add<mode>3<mask_name>_bcst): Likewise.
1498
1499 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
1500 Jinsong Ji <jji@us.ibm.com>
1501
1502 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
1503 __m64 with __vector unsigned long long for compatibility.
1504 (_mm_movemask_epi8): Likewise.
1505 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
1506 (_mm_cvttps_pi32): Likewise.
1507 (_mm_cvtpi32_ps): Likewise.
1508 (_mm_cvtps_pi16): Likewise.
1509 (_mm_loadh_pi): Likewise.
1510 (_mm_storeh_pi): Likewise.
1511 (_mm_movehl_ps): Likewise.
1512 (_mm_movelh_ps): Likewise.
1513 (_mm_loadl_pi): Likewise.
1514 (_mm_storel_pi): Likewise.
1515 (_mm_movemask_ps): Likewise.
1516 (_mm_shuffle_pi16): Likewise.
1517
1518 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1519
1520 PR target/72782
1521 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
1522 __builtin_ia32_vfnmsubpd512_mask.
1523 (_mm512_mask_fnmsub_round_pd): Likewise.
1524 (_mm512_fnmsub_pd): Likewise.
1525 (_mm512_mask_fnmsub_pd): Likewise.
1526 (_mm512_maskz_fnmsub_round_pd): Use
1527 __builtin_ia32_vfnmsubpd512_maskz.
1528 (_mm512_maskz_fnmsub_pd): Likewise.
1529 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
1530 (_mm512_mask_fnmsub_round_ps): Likewise.
1531 (_mm512_fnmsub_ps): Likewise.
1532 (_mm512_mask_fnmsub_ps): Likewise.
1533 (_mm512_maskz_fnmsub_round_ps): Use
1534 __builtin_ia32_vfnmsubps512_maskz.
1535 (_mm512_maskz_fnmsub_ps): Likewise.
1536 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
1537 __builtin_ia32_vfnmsubpd256_mask.
1538 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
1539 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1540 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
1541 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1542 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1543 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
1544 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
1545 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
1546 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
1547 __builtin_ia32_vfnmsubpd.
1548 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
1549 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
1550 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
1551 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
1552 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
1553 * config/i386/i386-builtin.def: Add
1554 __builtin_ia32_vfnmsubpd256_mask,
1555 __builtin_ia32_vfnmsubpd256_maskz,
1556 __builtin_ia32_vfnmsubpd128_mask,
1557 __builtin_ia32_vfnmsubpd128_maskz,
1558 __builtin_ia32_vfnmsubps256_mask,
1559 __builtin_ia32_vfnmsubps256_maskz,
1560 __builtin_ia32_vfnmsubps128_mask,
1561 __builtin_ia32_vfnmsubps128_maskz,
1562 __builtin_ia32_vfnmsubpd512_mask,
1563 __builtin_ia32_vfnmsubpd512_maskz,
1564 __builtin_ia32_vfnmsubps512_mask,
1565 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
1566 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
1567 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
1568 __builtin_ia32_vfnmsubpd256.
1569 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
1570 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
1571 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
1572 Likewise.
1573 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
1574 Likewise.
1575 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
1576 Likewise.
1577 (fmai_vmfnmsub_<mode><round_name>): Likewise.
1578
1579 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1580
1581 PR target/72782
1582 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
1583 __builtin_ia32_vfnmaddpd512_mask.
1584 (_mm512_mask_fnmadd_round_pd): Likewise.
1585 (_mm512_fnmadd_pd): Likewise.
1586 (_mm512_mask_fnmadd_pd): Likewise.
1587 (_mm512_maskz_fnmadd_round_pd): Use
1588 __builtin_ia32_vfnmaddpd512_maskz.
1589 (_mm512_maskz_fnmadd_pd): Likewise.
1590 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
1591 (_mm512_mask_fnmadd_round_ps): Likewise.
1592 (_mm512_fnmadd_ps): Likewise.
1593 (_mm512_mask_fnmadd_ps): Likewise.
1594 (_mm512_maskz_fnmadd_round_ps): Use
1595 __builtin_ia32_vfnmaddps512_maskz.
1596 (_mm512_maskz_fnmadd_ps): Likewise.
1597 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
1598 __builtin_ia32_vfnmaddpd256_mask.
1599 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
1600 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
1601 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
1602 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1603 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1604 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
1605 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
1606 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
1607 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
1608 __builtin_ia32_vfnmaddpd.
1609 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
1610 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
1611 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
1612 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
1613 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
1614 * config/i386/i386-builtin.def: Add
1615 __builtin_ia32_vfnmaddpd256_mask,
1616 __builtin_ia32_vfnmaddpd256_maskz,
1617 __builtin_ia32_vfnmaddpd128_mask,
1618 __builtin_ia32_vfnmaddpd128_maskz,
1619 __builtin_ia32_vfnmaddps256_mask,
1620 __builtin_ia32_vfnmaddps256_maskz,
1621 __builtin_ia32_vfnmaddps128_mask,
1622 __builtin_ia32_vfnmaddps128_maskz,
1623 __builtin_ia32_vfnmaddpd512_mask,
1624 __builtin_ia32_vfnmaddpd512_maskz,
1625 __builtin_ia32_vfnmaddps512_mask,
1626 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
1627 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
1628 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
1629 __builtin_ia32_vfnmaddpd256.
1630 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
1631 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
1632 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
1633 Likewise.
1634 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
1635 Likewise.
1636 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
1637 Likewise.
1638 (fmai_vmfnmadd_<mode><round_name>): Likewise.
1639
1640 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1641
1642 PR target/72782
1643 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
1644 __builtin_ia32_vfmsubpd512_mask.
1645 (_mm512_mask_fmsub_round_pd): Likewise.
1646 (_mm512_fmsub_pd): Likewise.
1647 (_mm512_mask_fmsub_pd): Likewise.
1648 (_mm512_maskz_fmsub_round_pd): Use
1649 __builtin_ia32_vfmsubpd512_maskz.
1650 (_mm512_maskz_fmsub_pd): Likewise.
1651 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
1652 (_mm512_mask_fmsub_round_ps): Likewise.
1653 (_mm512_fmsub_ps): Likewise.
1654 (_mm512_mask_fmsub_ps): Likewise.
1655 (_mm512_maskz_fmsub_round_ps): Use
1656 __builtin_ia32_vfmsubps512_maskz.
1657 (_mm512_maskz_fmsub_ps): Likewise.
1658 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
1659 __builtin_ia32_vfmsubpd256_mask.
1660 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
1661 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1662 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
1663 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1664 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1665 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
1666 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
1667 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
1668 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
1669 __builtin_ia32_vfmsubpd.
1670 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
1671 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
1672 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
1673 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
1674 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
1675 * config/i386/i386-builtin.def: Add
1676 __builtin_ia32_vfmsubpd256_mask,
1677 __builtin_ia32_vfmsubpd256_maskz,
1678 __builtin_ia32_vfmsubpd128_mask,
1679 __builtin_ia32_vfmsubpd128_maskz,
1680 __builtin_ia32_vfmsubps256_mask,
1681 __builtin_ia32_vfmsubps256_maskz,
1682 __builtin_ia32_vfmsubps128_mask,
1683 __builtin_ia32_vfmsubps128_maskz,
1684 __builtin_ia32_vfmsubpd512_mask,
1685 __builtin_ia32_vfmsubpd512_maskz,
1686 __builtin_ia32_vfmsubps512_mask,
1687 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
1688 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
1689 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
1690 __builtin_ia32_vfmsubpd256.
1691 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
1692 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
1693 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
1694 Likewise.
1695 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
1696 Likewise.
1697 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
1698 Likewise.
1699 (fmai_vmfmsub_<mode><round_name>): Likewise.
1700
1701 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1702
1703 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
1704 Remove plus. Renamed to ...
1705 (*sub<mode>3<mask_name>_bcst): This.
1706 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
1707 (*add<mode>3<mask_name>_bcst): This.
1708
1709 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1710
1711 PR target/72782
1712 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
1713
1714 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1715
1716 PR target/87662
1717 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
1718 (_mm_or_epi32): Likewise.
1719 (_mm256_xor_epi32): Likewise.
1720 (_mm_xor_epi32): Likewise.
1721 (_mm256_or_epi64): Likewise.
1722 (_mm_or_epi64): Likewise.
1723 (_mm256_xor_epi64): Likewise.
1724 (_mm_xor_epi64): Likewise.
1725
1726 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
1727
1728 PR target/72782
1729 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
1730
1731 2018-10-20 Jakub Jelinek <jakub@redhat.com>
1732
1733 PR middle-end/87647
1734 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
1735
1736 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
1737
1738 * doc/ux.texi: Move @section directly after @node.
1739
1740 2018-10-19 Jakub Jelinek <jakub@redhat.com>
1741
1742 PR middle-end/85488
1743 PR middle-end/87649
1744 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
1745 depend closely nested inside of loop with ordered clause with
1746 a parameter.
1747
1748 2018-10-19 David Malcolm <dmalcolm@redhat.com>
1749
1750 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
1751 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
1752 * doc/ux.texi: New file.
1753
1754 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
1755
1756 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
1757 be the first CR field allocated.
1758
1759 2018-10-19 Richard Biener <rguenther@suse.de>
1760
1761 PR target/87657
1762 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
1763 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
1764
1765 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1766
1767 PR target/72782
1768 * config/i386/sse.md
1769 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
1770 (*add<mode>3<mask_name>_bcst_2): Likewise.
1771
1772 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1773
1774 * config/i386/sse.md
1775 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1776 Replace nonimmediate_operand with register_operand.
1777 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1778 Likewise.
1779 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1780 Likewise.
1781
1782 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
1783
1784 PR rtl-optimization/87596
1785 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
1786 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
1787 for instructions in FROM..TO range.
1788
1789 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
1790
1791 * cfgexpand.c (expand_one_var): Use specific wording in error message
1792 for non-local frame variables.
1793 * stor-layout.c (layout_decl): Do not issue a warning for them.
1794
1795 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
1796
1797 * haifa-sched.c (priority): Add force_recompute parameter.
1798 (apply_replacement): Call priority () with force_recompute = true.
1799 (restore_pattern): Likewise.
1800
1801 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1802
1803 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
1804 HOST_BITS_PER_WIDE_INT.
1805 (test_vector_ops_duplicate): Likewise.
1806
1807 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1808
1809 PR target/72782
1810 * config/i386/sse.md (VF_AVX512): New.
1811 (avx512bcst): Likewise.
1812 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1813 Likewise.
1814 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1815 Likewise.
1816 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1817 Likewise.
1818
1819 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
1820
1821 * doc/invoke.texi (-dumpversion): Improve grammar.
1822 (-dumpfullversion): Make more consistent with -dumpversion.
1823
1824 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
1825
1826 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
1827 Set JUMP_LABEL to the jump insn.
1828 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
1829 Predict emitted jump and add label to jump insn.
1830
1831 2018-10-18 David Malcolm <dmalcolm@redhat.com>
1832
1833 PR tree-optimization/87562
1834 * input.c (get_substring_ranges_for_loc): Use
1835 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
1836 getting the linemap for the endpoint. Verify that it's either
1837 in the same linemap as the start point's spelling location, or
1838 at least in the same file.
1839
1840 2018-10-18 Richard Biener <rguenther@suse.de>
1841
1842 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
1843 feed width-specific load/store costs through ix86_vec_cost.
1844 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
1845 (k8_cost): Likewise.
1846 (bdver_cost): Likewise.
1847 (znver1_cost): Likewise.
1848 (btver1_cost): Likewise.
1849 (btver2_cost): Likewise.
1850
1851 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1852
1853 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
1854 to simplify subreg of vec_merge.
1855
1856 2018-10-18 Richard Biener <rguenther@suse.de>
1857
1858 * config/i386/i386.c: Fix costing of vector FMA.
1859
1860 2018-10-18 Richard Biener <rguenther@suse.de>
1861
1862 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
1863 and argument.
1864 (ix86_builtin_vectorization_cost): For vec_construct properly
1865 cost insertion into SSE regs.
1866 (...): Adjust calls to ix86_vec_cost.
1867
1868 2018-10-18 Richard Biener <rguenther@suse.de>
1869
1870 PR middle-end/87087
1871 Revert
1872 2018-02-07 Richard Biener <rguenther@suse.de>
1873
1874 PR tree-optimization/84204
1875 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
1876 this place.
1877
1878 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1879
1880 PR target/87537
1881 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
1882 of vec_duplicate.
1883 (test_vector_ops_duplicate): Add test for a scalar subreg of a
1884 VEC_MERGE of a VEC_DUPLICATE.
1885
1886 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1887
1888 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
1889 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
1890 * doc/standards.texi (C Language): Document C2X.
1891 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
1892 (rl78_option_override): Handle "GNU C2X" language name.
1893
1894 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1895
1896 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
1897 Document C17 as published in 2018.
1898
1899 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
1900
1901 PR middle-end/87623
1902 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
1903 bail out if both sides do not have the same storage order.
1904
1905 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1906
1907 * bitmap.c (bitmap_head::dump): New.
1908 * bitmap.h (bitmap_head): Add dump().
1909 * gimple-ssa-evrp-analyze.c
1910 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
1911 (evrp_range_analyzer::set_ssa_range_info): Same.
1912 (evrp_range_analyzer::record_ranges_from_phis): Same.
1913 (evrp_range_analyzer::record_ranges_from_stmt): Same.
1914 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
1915 * gimple-ssa-sprintf.c (get_int_range): Same.
1916 (format_integer): Same.
1917 (sprintf_dom_walker::handle_gimple_call): Same.
1918 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
1919 (ipcp_vr_lattice::top_p): Same.
1920 (ipcp_vr_lattice::bottom_p): Same.
1921 (ipcp_vr_lattice::set_to_bottom): Same.
1922 (ipa_vr_operation_and_type_effects): Same.
1923 (propagate_vr_across_jump_function): Same.
1924 (ipcp_store_vr_results): Same.
1925 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
1926 (ipa_print_node_jump_functions_for_edge): Same.
1927 (ipa_get_value_range): Same.
1928 (ipa_compute_jump_functions_for_edge): Same.
1929 (ipa_write_jump_function): Same.
1930 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
1931 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
1932 Same.
1933 * vr-values.c (set_value_range_to_nonnegative): Same.
1934 (set_value_range_to_truthvalue): Same.
1935 (vr_values::get_value_range): Same.
1936 (vr_values::set_defs_to_varying): Same.
1937 (vr_values::update_value_range): Same.
1938 (symbolic_range_based_on_p): Same.
1939 (vr_values::op_with_boolean_value_range_p): Same.
1940 (vr_values::extract_range_for_var_from_comparison_expr): Same.
1941 (vr_values::extract_range_from_ssa_name): Same.
1942 (vr_values::extract_range_from_binary_expr): Same.
1943 (vr_values::extract_range_from_unary_expr): Same.
1944 (vr_values::extract_range_from_cond_expr): Same.
1945 (vr_values::extract_range_from_comparison): Same.
1946 (vr_values::check_for_binary_op_overflow): Same.
1947 (vr_values::extract_range_basic): Same.
1948 (vr_values::extract_range_from_assignment): Same.
1949 (compare_ranges): Same.
1950 (compare_range_with_value): Same.
1951 (vr_values::adjust_range_with_scev): Same.
1952 (vrp_valueize): Same.
1953 (vrp_valueize_1): Same.
1954 (vr_values::get_vr_for_comparison): Same.
1955 (vr_values::compare_name_with_value): Same.
1956 (vr_values::compare_names): Same.
1957 (vr_values::vrp_evaluate_conditional): Same.
1958 (find_case_label_ranges): Same.
1959 (vr_values::vrp_visit_switch_stmt): Same.
1960 (vr_values::extract_range_from_phi_node): Same.
1961 (vr_values::simplify_div_or_mod_using_ranges): Same.
1962 (vr_values::simplify_bit_ops_using_ranges): Same.
1963 (test_for_singularity): Same.
1964 (range_fits_type_p): Same.
1965 (vr_values::simplify_cond_using_ranges_1): Same.
1966 (vr_values::simplify_switch_using_ranges): Same.
1967 (vr_values::simplify_float_conversion_using_ranges): Same.
1968 (vr_values::two_valued_val_range_p): Same.
1969 (vr_values::add_equivalence): Move to value_range::equiv_add.
1970 * vr-values.h (vr_values::add_equivalence): Remove.
1971 (VR_INITIALIZER): Remove.
1972 * tree-vrp.c (value_range::set): New.
1973 (value_range::equiv_add): New.
1974 (value_range::value_range): New.
1975 (value_range::deep_copy): New.
1976 (value_range::check): New.
1977 (value_range::equal_p): New.
1978 (value_range::ignore_equivs_equal_p): New.
1979 (value_range::operator==): New.
1980 (value_range::operator!=): New.
1981 (value_range::symbolic_p): New.
1982 (value_range::numeric_p): New.
1983 (value_range::set_undefined): New.
1984 (value_range::set_varying): New.
1985 (value_range::may_contain_p): New.
1986 (value_range::equiv_clear): New.
1987 (value_range::singleton_p): New.
1988 (value_range::intersect): New.
1989 (value_range::dump): New.
1990 (value_range::set_and_canonicalize): New.
1991 (set_value_range): Adjust for value_range API.
1992 (set_value_range_to_undefined): Same.
1993 (set_value_range_to_varying): Same.
1994 (set_and_canonicalize_value_range): Same.
1995 (set_value_range_to_nonnull): Same.
1996 (set_value_range_to_null): Same.
1997 (range_is_null): Same.
1998 (range_is_nonnull): Same.
1999 (range_int_cst_p): Same.
2000 (range_int_cst_singleton_p): Same.
2001 (symbolic_range_p): Same.
2002 (range_includes_zero_p): Same.
2003 (value_range_constant_singleton): Same.
2004 (vrp_set_zero_nonzero_bits): Same.
2005 (ranges_from_anti_range): Same.
2006 (extract_range_into_wide_ints): Same.
2007 (extract_range_from_multiplicative_op): Same.
2008 (set_value_range_with_overflow): Same.
2009 (extract_range_from_binary_expr_1): Same.
2010 (extract_range_from_unary_expr): Same.
2011 (dump_value_range): Same.
2012 (debug_value_range): Same.
2013 (vrp_prop::check_array_ref): Same.
2014 (vrp_prop::check_mem_ref): Same.
2015 (vrp_prop::vrp_initialize): Same.
2016 (vrp_prop::visit_stmt): Same.
2017 (intersect_ranges): Same.
2018 (vrp_prop::visit_phi): Same.
2019 (vrp_prop::vrp_finalize): Same.
2020 (determine_value_range_1): Same.
2021 (determine_value_range): Same.
2022 (vrp_intersect_ranges_1): Rename to...
2023 (vrp_intersect_1): this.
2024 (vrp_intersect_ranges): Rename to...
2025 (value_range::intersect_helper): ...this.
2026 (vrp_meet_1): Rename to...
2027 (value_range::union_helper): ...this.
2028 (vrp_meet): Rename to...
2029 (value_range::union_): ...this.
2030 (copy_value_range): Remove.
2031 * tree-vrp.h (struct value_range): Rewrite into a proper class.
2032 (value_range::vrtype): New.
2033 (value_range::type): New.
2034 (value_range::equiv): New.
2035 (value_range::min): New.
2036 (value_range::max): New.
2037 (value_range::varying_p): New.
2038 (value_range::undefined_p): New.
2039 (value_range::null_p): New.
2040 (value_range::equiv_add): New.
2041 (copy_value_range): Remove.
2042
2043 2018-10-17 David Malcolm <dmalcolm@redhat.com>
2044
2045 * Makefile.in (SELFTEST_TARGETS): New.
2046 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
2047 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
2048 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
2049 c/Make-lang.in.
2050 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
2051 (selftest-c++-gdb, selftest-c++-valgrind): Move to
2052 cp/Make-lang.in.
2053 * configure: Regenerate.
2054 * configure.ac (selftest_languages): New.
2055
2056 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
2057
2058 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
2059 overflow wraps argument.
2060 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
2061 wide_int_range_multiplicative_op.
2062 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
2063 overflow wraps argument.
2064 (wide_int_range_multiplicative_op): Same.
2065 (wide_int_range_lshift): Same.
2066 (wide_int_range_div): Same.
2067 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
2068 (wide_int_range_lshift): Same.
2069 (wide_int_range_div): Same.
2070
2071 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
2072
2073 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
2074 use sign as argument.
2075 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
2076 wide_int_range_shift_undefined_p.
2077
2078 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2079
2080 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
2081 Rename to...
2082 (@despeculate_copy<ALLI_TI:mode>): ... This.
2083 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
2084 switch statement.
2085
2086 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2087
2088 * config.gcc: Obsolete *-*-solaris2.10*.
2089 * doc/install.texi (Specific, *-*-solaris2*): Document it.
2090
2091 2018-10-12 Jeff Law <law@redhat.com>
2092
2093 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
2094 reg + sym +- const_int addressing modes.
2095
2096 2018-10-15 David Malcolm <dmalcolm@redhat.com>
2097
2098 * common.opt (fdiagnostics-minimum-margin-width=): New option.
2099 * diagnostic-show-locus.c (layout::layout): Apply the minimum
2100 margin width.
2101 (layout::start_annotation_line): Only print up to 3 of the
2102 margin character, to avoid touching the left-hand side.
2103 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
2104 minimum margin width, as set by test_diagnostic_context's ctor.
2105 (selftest::test_fixit_insert_containing_newline): Likewise.
2106 (selftest::test_fixit_insert_containing_newline_2): Likewise.
2107 (selftest::test_line_numbers_multiline_range): Clear
2108 dc.min_margin_width.
2109 * diagnostic.c (diagnostic_initialize): Initialize
2110 min_margin_width.
2111 * diagnostic.h (struct diagnostic_context): Add field
2112 "min_margin_width".
2113 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
2114 * opts.c (common_handle_option): Handle
2115 OPT_fdiagnostics_minimum_margin_width_.
2116 * selftest-diagnostic.c
2117 (selftest::test_diagnostic_context::test_diagnostic_context):
2118 Initialize min_margin_width to 6.
2119 * toplev.c (general_init): Initialize global_dc->min_margin_width.
2120
2121 2018-10-15 David Malcolm <dmalcolm@redhat.com>
2122
2123 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
2124 Fix usage of "error_at_rich_loc" in the comment.
2125
2126 2018-10-15 Renlin Li <renlin.li@arm.com>
2127
2128 PR target/87563
2129 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
2130 if-conversioned loop when it contains ifn with types not
2131 supported by backend.
2132 * internal-fn.c (expand_direct_optab_fn): Add an assert.
2133 (direct_internal_fn_supported_p): New helper function.
2134 * internal-fn.h (direct_internal_fn_supported_p): Declare.
2135
2136 2018-10-15 Jakub Jelinek <jakub@redhat.com>
2137
2138 PR target/87572
2139 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2140 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2141 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2142
2143 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
2144
2145 PR tree-optimization/87022
2146 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
2147 bits in dist vector rather than the first one.
2148
2149 2018-10-15 Richard Biener <rguenther@suse.de>
2150
2151 PR middle-end/87610
2152 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
2153 (visit_loadstore): When a used restrict tag escaped verify that
2154 the points-to solution of "other" pointers do not include
2155 escaped.
2156 (compute_dependence_clique): If a used restrict tag escaped
2157 communicated that down to visit_loadstore.
2158
2159 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
2160
2161 * config/s390/s390.c (s390_expand_vec_init): Force vector element
2162 into reg if it isn't a general operand.
2163
2164 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2165
2166 PR target/87599
2167 * config/i386/sse.md (*vec_dupv2di): Add register source to
2168 movddup.
2169
2170 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2171
2172 PR target/87572
2173 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2174 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
2175 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2176 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2177
2178 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
2179
2180 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
2181 (notice_args_size): Set it in the current trace if no insn that can
2182 throw internally has been seen yet.
2183 (connect_traces): When connecting args_size between traces, allow the
2184 incoming values not to match if there is an insn setting it before the
2185 first insn that can throw internally; in that case, force the creation
2186 of a CFI note on this latter insn.
2187
2188 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
2189
2190 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
2191 the base class, because using the injected-class-name was not clearly
2192 specified until DR 176.
2193
2194 2018-10-12 Paul Koning <ni1d@arrl.net>
2195
2196 * config/pdp11/pdp11.md (doloop_end): New expander.
2197 (doloop_end_insn): renamed from "doloop_end".
2198 (addqi3): New pattern.
2199 (subqi3): New pattern.
2200 * config/pdp11/predicates.md (incdec_operand): New predicate.
2201
2202 2018-10-12 Yury Gribov <tetra2005@gmail.com>
2203
2204 PR middle-end/81376
2205 * real.c (format_helper::can_represent_integral_type_p): New function
2206 * real.h (format_helper::can_represent_integral_type_p): Ditto.
2207 * match.pd: New pattern.
2208
2209 2018-10-12 Alexandre Oliva <oliva@adacore.com>
2210
2211 * configure.ac: Introduce --enable-large-address-aware
2212 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
2213 * doc/install.texi: Document it.
2214 * configure, config.in: Rebuilt.
2215 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
2216 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
2217 (LINK_SPEC): Insert it.
2218 * config/i386/mingw-w64.h: Likewise.
2219
2220 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
2221
2222 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
2223
2224 PR rtl-optimization/87600
2225 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
2226
2227 2018-10-12 Paul Koning <ni1d@arrl.net>
2228
2229 * doc/md.texi (doloop_end): Document that the pattern code may
2230 need to check operand mode.
2231
2232 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
2233
2234 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
2235 to zero-extend between int and floating-point registers.
2236 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
2237 ldp into floating-point registers. Add type and arch attributes.
2238 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
2239 Use f_loads for type attribute.
2240
2241 2018-10-11 Martin Sebor <msebor@redhat.com>
2242
2243 * doc/extend.texi (attribute packed): Correct typos.
2244
2245 2018-10-11 Martin Sebor <msebor@redhat.com>
2246
2247 * doc/extend.texi (attribute flatten): Mention interaction with
2248 noinline.
2249
2250 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
2251
2252 PR target/87156
2253 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
2254 Set new_decl virtual flag to zero.
2255
2256 2018-10-11 Martin Sebor <msebor@redhat.com>
2257
2258 PR middle-end/87593
2259 * doc/extend.texi (attribute format_arg): Discuss using multiple
2260 attributes on a single function.
2261
2262 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
2263
2264 PR tree-optimization/86829
2265 * match.pd (sin (atan (x))): New simplification rules.
2266 (cos (atan (x))): Likewise.
2267 * real.c (build_sinatan_real): New function.
2268 * real.h (build_sinatan_real): Prototype.
2269
2270 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
2271
2272 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
2273 function.
2274 (fold_mergeeo_helper): New helper function.
2275 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
2276 intrinsics. Correct some whitespace indentation issues.
2277
2278 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
2279
2280 PR target/87511
2281 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
2282 Use HOST_WIDE_INT_1U for shift.
2283
2284 2018-10-11 Doug Rupp <rupp@adacore.com>
2285 Olivier Hainque <hainque@adacore.com>
2286
2287 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
2288 Pass --relax to the linker for RTPs.
2289 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
2290
2291 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
2292 Jan Hubicka <jh@suse.cz>
2293 Martin Jambor <mjambor@suse.cz>
2294
2295 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
2296 the same elements are repeated rather than printing all of them.
2297 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
2298 "repeated" elements.
2299 * read-rtl-function.c (test_loading_repeat): New function.
2300 (read_rtl_function_c_tests): Call test_loading_repeat.
2301 * rtl-tests.c (test_dumping_repeat): New function.
2302 (rtl_tests_c_tests): Call test_dumping_repeat.
2303
2304 2018-10-11 Richard Biener <rguenther@suse.de>
2305
2306 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
2307 bdver?_cost): Unify to ...
2308 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
2309 * config/i386/i386.c (processor_cost_table): Adjust.
2310
2311 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
2312
2313 PR middle-end/87574
2314 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
2315 the thunk when expanding to GIMPLE.
2316
2317 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
2318
2319 * varasm.c (mergeable_string_section): Don't try to move zero-length
2320 strings to the merge section.
2321
2322 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
2323
2324 PR target/87573
2325 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
2326
2327 2018-10-10 Jakub Jelinek <jakub@redhat.com>
2328
2329 PR target/87550
2330 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
2331 to special_args set.
2332
2333 2018-10-10 Richard Biener <rguenther@suse.de>
2334
2335 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
2336 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
2337 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
2338 and recursing and pattern terminating the recursion on SSE
2339 vector width using ix86_expand_reduc.
2340 (reduc_sminmax_scal_<mode>): Split into part reducing to half
2341 width and recursing and SSE2 vector variant doing the final
2342 reduction with ix86_expand_reduc.
2343 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
2344 with terminating the recursion at AVX level, splitting that
2345 to SSE there.
2346
2347 2018-10-09 David Malcolm <dmalcolm@redhat.com>
2348
2349 * genmatch.c (error_cb): Rename to...
2350 (diagnostic_cb): ...this, converting int params to enums.
2351 (fatal_at): Update for renaming.
2352 (warning_at): Likewise.
2353 (main): Likewise.
2354 * input.c (selftest::ebcdic_execution_charset::apply):
2355 Update for renaming of...
2356 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
2357 to...
2358 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
2359 converting level and reason to enums.
2360 (class selftest::lexer_error_sink): Rename to...
2361 (class selftest::lexer_test_options): ...this, renaming field
2362 "m_errors" to "m_diagnostics".
2363 (selftest::lexer_test_options::apply): Update for renaming of...
2364 (selftest::lexer_test_options::on_error): ...this, renaming to...
2365 (selftest::lexer_test_options::on_diagnostic): ...this
2366 converting level and reason to enums.
2367 (selftest::test_lexer_string_locations_raw_string_unterminated):
2368 Update for renamings.
2369 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
2370 "reason".
2371
2372 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
2373
2374 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
2375 * config/rs6000/pmmintrin.h: New file.
2376
2377 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
2378
2379 PR tree-optimization/86659
2380 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
2381
2382 2018-10-09 Richard Biener <rguenther@suse.de>
2383
2384 PR tree-optimization/63155
2385 * tree-ssa-structalias.c: Include tree-ssa.h.
2386 (get_constraint_for_ssa_var): For undefs return nothing_id.
2387 (find_func_aliases): Cleanup PHI handling.
2388
2389 2018-10-09 Richard Biener <rguenther@suse.de>
2390
2391 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
2392 replacements.
2393
2394 2018-10-09 Martin Liska <mliska@suse.cz>
2395
2396 * asan.c (asan_emit_stack_protection): If a stack variable
2397 is located in a same file as current function, then emit
2398 line info into variable definition string.
2399
2400 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2401
2402 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
2403 information.
2404
2405 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2406
2407 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
2408 on the thunk.
2409
2410 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2411
2412 PR tree-optimization/86659
2413 * gimple-match.h (struct gimple_match_op): Add reverse field.
2414 (gimple_match_op::set_op): New overloaded method.
2415 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
2416 the REF_REVERSE_STORAGE_ORDER flag on the value.
2417 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
2418 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
2419
2420 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2421
2422 PR middle-end/63155
2423 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
2424 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
2425
2426 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2427
2428 PR target/87517
2429 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
2430 Defined with __builtin_ia32_vfmaddsubpd512_mask.
2431
2432 2018-10-08 Richard Biener <rguenther@suse.de>
2433
2434 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
2435 cost the same as AVX128 ones.
2436
2437 2018-10-08 Paul Koning <ni1d@arrl.net>
2438
2439 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
2440 (expand_block_move): New function.
2441 * config/pdp11/pdp11.c (output_block_move): Remove.
2442 (expand_block_move): New function.
2443 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
2444 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
2445 (*movmemhi1): Remove.
2446
2447 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
2448
2449 * config/s390/2827.md: Increase latencies for some FP instructions.
2450
2451 2018-10-08 Richard Biener <rguenther@suse.de>
2452
2453 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
2454 Open a dump scope.
2455 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
2456 * tree-vectorizer.h (dump_stmt_cost): Adjust.
2457 (add_stmt_cost): Dump return value of the hook.
2458
2459 2018-10-08 Richard Biener <rguenther@suse.de>
2460
2461 PR tree-optimization/63155
2462 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
2463 (ssa_propagation_engine::ssa_propagate): Remove redundant
2464 bitmap bit clearing.
2465
2466 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
2467
2468 PR rtl-optimization/86939
2469 PR rtl-optimization/87479
2470 * ira.h (non_conflicting_reg_copy_p): New prototype.
2471 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
2472 (make_hard_regno_dead): Don't add conflicts for register
2473 ignore_reg_for_conflicts.
2474 (make_object_dead): Likewise.
2475 (non_conflicting_reg_copy_p): New function.
2476 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
2477 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
2478 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
2479 (make_hard_regno_dead): Don't add conflicts for register
2480 ignore_reg_for_conflicts. Remove special conflict handling of
2481 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
2482 check_pic_pseudo_p and update callers.
2483 (mark_pseudo_dead): Don't add conflicts for register
2484 ignore_reg_for_conflicts.
2485 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
2486
2487 2018-10-05 Andrew Waterman <andrew@sifive.com>
2488 Jim Wilson <jimw@sifive.com>
2489
2490 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
2491 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
2492 new pattern using HONOR_SNANS that emits one extra instruction.
2493
2494 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2495
2496 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
2497 patterns): Merge SI and DI patterns to a GPR pattern.
2498 (unnamed define_insn and define_split for record form of that): Merge
2499 to a single define_insn_and_split pattern.
2500
2501 2018-10-05 David Malcolm <dmalcolm@redhat.com>
2502
2503 PR c++/56856
2504 * input.c (expand_location_to_spelling_point): Add param "aspect"
2505 and use rather than hardcoding LOCATION_ASPECT_CARET.
2506 (get_substring_ranges_for_loc): Handle the case of a single token
2507 within a macro expansion.
2508 * input.h (expand_location_to_spelling_point): Add "aspect" param,
2509 defaulting to LOCATION_ASPECT_CARET.
2510
2511 2018-10-05 Paul Koning <ni1d@arrl.net>
2512
2513 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
2514 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
2515 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
2516 (pdp11_guard_type): New function.
2517
2518 2018-10-05 Paul Koning <ni1d@arrl.net>
2519
2520 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
2521 * config/pdp11/pdp11.opt (mfloat32): Remove.
2522 (mfloat64): Remove.
2523 * doc/invoke.texi (pdp11 -mfloat32): Remove:
2524 (pdp11 -mfloat64): Remove.
2525
2526 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2527
2528 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
2529 (*cmp<mode>_cc_i387): Ditto.
2530 (*cmpu<mode>_cc_i387): Ditto.
2531 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2532 * config/i386/i386.c (ix86_expand_fp_compare): Remove
2533 "scratch" argument.
2534 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
2535 Emit x86_sahf_1 pattern.
2536 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
2537 (ix86_expand_carry_flag_compare): Ditto.
2538
2539 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2540
2541 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
2542 to reg_or_0_operand. Add "C" constraint.
2543 (*cmpxf_cc_i387): Ditto.
2544 (*cmp<mode>_i387): Change operand 2 predicate
2545 to nonimm_or_0_operand. Add "C" constraint.
2546 (*cmp<mode>_cc_i387): Ditto.
2547 (*cmp<mode>_0_i387): Remove insn pattern.
2548 (*cmp<mode>_0_cc_i387): Ditto.
2549
2550 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2551
2552 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
2553 * config/i386/predicates.md (nonimm_or_0_operand): Rename
2554 from vector_move_operand. Update all uses.
2555
2556 2018-10-05 Martin Sebor <msebor@redhat.com>
2557
2558 PR tree-optimization/87490
2559 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
2560 consistently.
2561
2562 2018-10-05 Richard Biener <rguenther@suse.de>
2563
2564 PR tree-optimization/63155
2565 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
2566 vertical space in dumpfiles.
2567 * tree-ssa-propagate.h
2568 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
2569 * tree-ssa-propagate.c (cfg_blocks_back): New global.
2570 (ssa_edge_worklist_back): Likewise.
2571 (curr_order): Likewise.
2572 (cfg_blocks_get): Remove abstraction.
2573 (cfg_blocks_add): Likewise.
2574 (cfg_blocks_empty_p): Likewise.
2575 (add_ssa_edge): Add to current or next worklist based on
2576 RPO index.
2577 (add_control_edge): Likewise.
2578 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
2579 into ...
2580 (ssa_propagation_engine::ssa_propagate): ... here. Unify
2581 iteration from CFG and SSA edge worklist so we process
2582 everything in RPO order, prioritizing forward progress
2583 over iteration.
2584 (ssa_prop_init): Allocate new worklists, do not dump
2585 immediate uses.
2586 (ssa_prop_fini): Free new worklists.
2587
2588 2018-10-05 Richard Biener <rguenther@suse.de>
2589
2590 * tree-core.h (tree_block::abstract_flag): Remove.
2591 (tree_block::block_num): Make full 32bits.
2592 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
2593 * tree.h (BLOCK_ABSTRACT): Remove.
2594 * dwarf2out.c (gen_lexical_block_die): Remove dead code
2595 resulting from BLOCK_ABSTRACT being always false.
2596 (gen_inlined_subroutine_die): Likewise.
2597 (gen_block_die): Likewise.
2598 * tree.c (block_ultimate_origin): Likewise.
2599 * tree-pretty-print.c (dump_block_node): Remove code dealing
2600 with BLOCK_ABSTRACT.
2601 * tree-ssa-live.c (dump_scope_block): Likewise.
2602 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
2603 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
2604
2605 2018-10-05 Richard Biener <rguenther@suse.de>
2606
2607 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
2608 is asked for initialize mode to the component mode of the
2609 vector type.
2610
2611 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2612
2613 PR target/87522
2614 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
2615 assembler for -mavx.
2616 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
2617
2618 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2619
2620 PR target/87509
2621 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
2622 RS6000_BTM_DFP.
2623 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
2624 to be DImode. When using mffscrn, force the operand to a register.
2625
2626 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
2627
2628 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
2629 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
2630 X87MODEF mode iterator.
2631 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
2632 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
2633 X87MODEF mode iterator.
2634
2635 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
2636
2637 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
2638 -Wno-prio-ctor-dtor.
2639
2640 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2641
2642 * Makefile.in (OBJS): Add opt-problem.o.
2643 * dump-context.h: Include "selftest.h.
2644 (selftest::temp_dump_context): New forward decl.
2645 (class dump_context): Make friend of class
2646 selftest::temp_dump_context.
2647 (dump_context::dump_loc_immediate): New decl.
2648 (class dump_pretty_printer): Move here from dumpfile.c.
2649 (class temp_dump_context): Move to namespace selftest.
2650 (temp_dump_context::temp_dump_context): Add param
2651 "forcibly_enable_dumping".
2652 (selftest::verify_dumped_text):
2653 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
2654 (selftest::verify_item):
2655 (ASSERT_IS_TEXT): Move here from dumpfile.c.
2656 (ASSERT_IS_TREE): Likewise.
2657 (ASSERT_IS_GIMPLE): Likewise.
2658 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
2659 to...
2660 (dump_context::dump_loc_immediate): ...this new function.
2661 (class dump_pretty_printer): Move to dump-context.h.
2662 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
2663 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
2664 (temp_dump_context::temp_dump_context): Move to "selftest"
2665 namespace. Add param "forcibly_enable_dumping", and use it to
2666 conditionalize the use of m_pp;
2667 (selftest::verify_dumped_text): Make non-static.
2668 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
2669 (selftest::verify_item): Make non-static.
2670 (ASSERT_IS_TEXT): Move to dump-context.h.
2671 (ASSERT_IS_TREE): Likewise.
2672 (ASSERT_IS_GIMPLE): Likewise.
2673 (selftest::test_capture_of_dump_calls): Pass "true" for new
2674 param of temp_dump_context.
2675 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
2676 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
2677 TDF_COMPARE_DEBUG.
2678 * opt-problem.cc: New file.
2679 * opt-problem.h: New file.
2680 * optinfo-emit-json.cc
2681 (selftest::test_building_json_from_dump_calls): Pass "true" for
2682 new param of temp_dump_context.
2683 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
2684 (optinfo::emit_for_opt_problem): New function.
2685 (optinfo::emit): Clarity which emit_item is used.
2686 * optinfo.h (optinfo::get_dump_location): New accessor.
2687 (optinfo::emit_for_opt_problem): New decl.
2688 (optinfo::emit): Make const.
2689 * selftest-run-tests.c (selftest::run_tests): Call
2690 selftest::opt_problem_cc_tests.
2691 * selftest.h (selftest::opt_problem_cc_tests): New decl.
2692 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
2693 bool to opt_result, converting fprintf messages to
2694 opt_result::failure_at calls. Add "stmt" param for use by the
2695 failure_at calls.
2696 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
2697 (runtime_alias_check_p): Convert return type from bool to
2698 opt_result, converting dump_printf calls to
2699 opt_result::failure_at, using the statement DDR_A for their
2700 location.
2701 (find_data_references_in_stmt): Convert return type from bool to
2702 opt_result, converting "return false" to opt_result::failure_at
2703 with a new message.
2704 * tree-data-ref.h: Include "opt-problem.h".
2705 (dr_analyze_innermost): Convert return type from bool to opt_result,
2706 and add a const gimple * param.
2707 (find_data_references_in_stmt): Convert return type from bool to
2708 opt_result.
2709 (runtime_alias_check_p): Likewise.
2710 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
2711 dr_analyze_innermost.
2712 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
2713 Convert return type from bool to opt_result, adding a message for
2714 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
2715 (vect_analyze_data_ref_dependence): Convert return type from bool
2716 to opt_result. Change sense of return type from "false"
2717 effectively meaning "no problems" to "false" meaning a problem,
2718 so that "return false" becomes "return opt_result::success".
2719 Convert "return true" calls to opt_result::failure_at, using
2720 the location of statement A rather than vect_location.
2721 (vect_analyze_data_ref_dependences): Convert return type from bool
2722 to opt_result.
2723 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
2724 calls to opt_result::failure_at, using the stmt location rather
2725 than vect_location.
2726 (vect_verify_datarefs_alignment): Convert return type from bool
2727 to opt_result.
2728 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
2729 into multiple more-tightly-scoped copies.
2730 (vect_analyze_data_refs_alignment): Convert return type from bool
2731 to opt_result.
2732 (vect_analyze_data_ref_accesses): Likewise, converting a
2733 "return false" to a "return opt_result::failure_at", adding a
2734 new message.
2735 (vect_prune_runtime_alias_test_list): Convert return type from
2736 bool to opt_result, converting dump_printf_loc to
2737 opt_result::failure_at. Add a %G to show the pertinent statement,
2738 and use the stmt's location rather than vect_location.
2739 (vect_find_stmt_data_reference): Convert return type from
2740 bool to opt_result, converting dump_printf_loc to
2741 opt_result::failure_at, using stmt's location.
2742 (vect_analyze_data_refs): Convert return type from bool to
2743 opt_result. Convert "return false" to "return
2744 opt_result::failure_at", adding messages as needed.
2745 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
2746 type from bool to opt_result.
2747 (vect_determine_vf_for_stmt): Likewise.
2748 (vect_determine_vectorization_factor): Likewise, converting
2749 dump_printf_loc to opt_result::failure_at, using location of phi
2750 rather than vect_location.
2751 (vect_analyze_loop_form_1): Convert return type from bool to
2752 opt_result, converting dump_printf_loc calls, retaining the use of
2753 vect_location.
2754 (vect_analyze_loop_form): Convert return type from loop_vec_info
2755 to opt_loop_vec_info.
2756 (vect_analyze_loop_operations): Convert return type from bool to
2757 opt_result, converting dump_printf_loc calls, using the location
2758 of phi/stmt rather than vect_location where available. Convert
2759 various "return false" to "return opt_result::failure_at" with
2760 "unsupported phi" messages.
2761 (vect_get_datarefs_in_loop): Convert return type from bool to
2762 opt_result. Add a message for the
2763 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
2764 (vect_analyze_loop_2): Convert return type from bool to
2765 opt_result. Ensure "ok" is set to a opt_result::failure_at before
2766 each "goto again;", adding new messages where needed.
2767 Add "unsupported grouped {store|load}" messages.
2768 (vect_analyze_loop): Convert return type from loop_vec_info to
2769 opt_loop_vec_info.
2770 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
2771 bool to opt_result.
2772 * tree-vect-stmts.c (process_use): Likewise, converting
2773 dump_printf_loc call and using stmt location, rather than
2774 vect_location.
2775 (vect_mark_stmts_to_be_vectorized): Likeise.
2776 (vect_analyze_stmt): Likewise, adding a %G.
2777 (vect_get_vector_types_for_stmt): Convert return type from bool to
2778 opt_result, converting dump_printf_loc calls and using stmt
2779 location, rather than vect_location.
2780 (vect_get_mask_type_for_stmt): Convert return type from tree to
2781 opt_tree, converting dump_printf_loc calls and using stmt location.
2782 * tree-vectorizer.c: Include "opt-problem.h.
2783 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
2784 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
2785 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
2786 enabled, use it to report at the top level "couldn't vectorize
2787 loop" followed by the problem.
2788 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
2789 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
2790 to opt_result.
2791 (vect_analyze_stmt): Likewise.
2792 (vect_get_vector_types_for_stmt): Likewise.
2793 (tree vect_get_mask_type_for_stmt): Likewise.
2794 (vect_analyze_data_ref_dependences): Likewise.
2795 (vect_enhance_data_refs_alignment): Likewise.
2796 (vect_analyze_data_refs_alignment): Likewise.
2797 (vect_verify_datarefs_alignment): Likewise.
2798 (vect_analyze_data_ref_accesses): Likewise.
2799 (vect_prune_runtime_alias_test_list): Likewise.
2800 (vect_find_stmt_data_reference): Likewise.
2801 (vect_analyze_data_refs): Likewise.
2802 (vect_analyze_loop): Convert return type from loop_vec_info to
2803 opt_loop_vec_info.
2804 (vect_analyze_loop_form): Likewise.
2805 (vect_analyze_slp): Convert return type from bool to opt_result.
2806
2807 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2808
2809 * doc/invoke.texi (-fopt-info): Document new "internals"
2810 sub-option.
2811 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
2812 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
2813 MSG_ALL_KINDS.
2814 (optinfo_verbosity_options): Add "internals".
2815 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
2816 (dump_context::apply_dump_filter_p): New member function.
2817 (dump_context::dump_loc): Use apply_dump_filter_p rather than
2818 explicitly masking the dump_kind.
2819 (dump_context::begin_scope): Increment the scope depth first. Use
2820 apply_dump_filter_p rather than explicitly masking the dump_kind.
2821 (dump_context::emit_item): Use apply_dump_filter_p rather than
2822 explicitly masking the dump_kind.
2823 (dump_dec): Likewise.
2824 (dump_hex): Likewise.
2825 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
2826 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
2827 (opt_info_switch_p): Update handling of default
2828 MSG_OPTIMIZED_LOCATIONS to cope with default of
2829 MSG_PRIORITY_USER_FACING.
2830 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
2831 masking the dump_kind.
2832 (selftest::test_capture_of_dump_calls): Update test_dump_context
2833 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
2834 than MSG_ALL. Generalize scope test to be run at all four
2835 combinations of with/without MSG_PRIORITY_USER_FACING and
2836 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
2837 for each of the two values.
2838 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
2839 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
2840 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
2841 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
2842 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
2843 with MSG_PRIORITY_*.
2844 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
2845 dump messages as MSG_PRIORITY_USER_FACING.
2846 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
2847 about the interaction with MSG_PRIORITY_*.
2848
2849 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
2850
2851 * varasm.c (output_constant): Add new parameter merge_strings.
2852 Make strings properly zero terminated in merge string sections.
2853 (mergeable_string_section): Don't fail if the last char is non-zero.
2854 (assemble_variable_contents): Handle merge string sections.
2855 (assemble_variable): Likewise.
2856 (assemble_constant_contents): Likewise.
2857 (output_constant_def_contents): Likewise.
2858 (output_constructor_array_range,
2859 output_constructor_regular_field): Adjust call to output_constant.
2860 (output_object_block): Adjust call to assemble_constant_contents
2861 and assemble_variable_contents.
2862
2863 2018-10-04 Martin Liska <mliska@suse.cz>
2864
2865 PR c/87483
2866 * cgraphunit.c (process_function_and_variable_attributes):
2867 Warn about a function with alias attribute and a body.
2868
2869 2018-10-04 Martin Liska <mliska@suse.cz>
2870
2871 PR ipa/82625
2872 * multiple_target.c (redirect_to_specific_clone): New function.
2873 (ipa_target_clone): Use it.
2874 * tree-inline.c: Fix comment.
2875
2876 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2877
2878 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
2879 fields.
2880 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
2881 (gcc::dump_manager::register_pass): New member function, adapted
2882 from loop body in gcc::pass_manager::register_pass, adding a
2883 call to update_dfi_for_opt_info.
2884 (gcc::dump_manager::opt_info_enable_passes): Store the
2885 -fopt-info options into the new fields. Move the loop
2886 bodies into...
2887 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
2888 function.
2889 * dumpfile.h (struct opt_pass): New forward decl.
2890 (gcc::dump_manager::register_pass): New decl.
2891 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
2892 (class gcc::dump_manager): Add fields "m_optgroup_flags",
2893 "m_optinfo_flags", and "m_optinfo_filename".
2894 * passes.c (gcc::pass_manager::register_pass): Move all of the
2895 dump-handling code to gcc::dump_manager::register_pass.
2896
2897 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
2898
2899 PR rtl-optimization/87466
2900 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
2901 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
2902 * doc/tm.texi: Regenerate.
2903 * ira-lives.c (process_bb_node_lives): Use the new target hook.
2904 * lra-lives.c (process_bb_lives): Likewise.
2905 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
2906 Define.
2907
2908 2018-10-04 Tamar Christina <tamar.christina@arm.com>
2909
2910 * params.c (add_params): Fix initialization.
2911
2912 2018-10-04 Martin Liska <mliska@suse.cz>
2913
2914 PR gcov-profile/84107
2915 * tree-profile.c (init_ic_make_global_vars):
2916 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
2917 Come up with new ic_tuple* variables. Emit
2918 __gcov_indirect_call{,_topn} variables.
2919 (gimple_gen_ic_profiler): Access the variable
2920 and emit gimple.
2921 (gimple_gen_ic_func_profiler): Access
2922 __gcov_indirect_call.callee field.
2923 (gimple_init_gcov_profiler): Use ptr_type_node.
2924 * value-prof.c (gimple_ic): Use ptr_type_node.
2925
2926 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2927
2928 PR tree-optimization/85787
2929 * ipa-pure-const.c (malloc_candidate_p_1): Move most of malloc_candidate_p
2930 into this function and add support for detecting multiple phis.
2931 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
2932
2933 2018-10-04 Martin Liska <mliska@suse.cz>
2934
2935 PR ipa/87491
2936 * ipa-inline.c (inline_to_all_callers_1):
2937 Call ultimate_alias_target for node being inlined.
2938
2939 2018-10-03 Jeff Law <law@redhat.com>
2940
2941 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
2942 target's wchar_t.
2943 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
2944 * tree.h (get_typenode_from_name): Prototype.
2945
2946 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2947
2948 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
2949 Change operand 2 predicate to nonimmediate_operand.
2950 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2951
2952 2018-10-03 Martin Sebor <msebor@redhat.com>
2953 Jeff Law <law@redhat.com>
2954
2955 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
2956 initialize it.
2957 (get_string_length): Detect unterminated arrays.
2958 (format_string): Same.
2959 (format_directive): Warn about unterminated arrays.
2960 (handle_gimple_call): Mark statements with no_warning as needed.
2961
2962 2018-10-03 Jim Wilson <jimw@sifive.com>
2963
2964 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
2965 also define __riscv_abi_rve. Delete trailing white space.
2966
2967 2018-10-03 Paul Koning <ni1d@arrl.net>
2968
2969 Enable LRA register allocator for PDP11.
2970 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
2971 (R): Likewise.
2972 (D): Likewise.
2973 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
2974 * config/pdp11/pdp11.opt (-mlra): New option.
2975 * doc/invoke.texi (PDP-11 Options): Document -mlra.
2976
2977 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2978
2979 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
2980 (*<absneg:code>extend<mode>xf2): Ditto.
2981
2982 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2983
2984 PR tree-optimization/87415
2985 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
2986 precision fields.
2987
2988 2018-10-02 Jeff Law <law@redhat.com>
2989
2990 * gimple-fold.c (get_range_strlen): Only set *nonstr when
2991 an unterminated string is discovered. Bubble up range
2992 even for unterminated strings.
2993 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
2994 indicates the string was not terminated via NONSTR.
2995
2996 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2997
2998 * tree-vrp.c (extract_range_from_unary_expr): Special case all
2999 pointer conversions.
3000 Do not do anything special for anti-ranges.
3001
3002 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
3003
3004 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
3005 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
3006
3007 2018-10-03 Martin Liska <mliska@suse.cz>
3008
3009 PR gcov-profile/86109
3010 * coverage.c (coverage_begin_function): Do not
3011 mark lambdas as artificial.
3012 * tree-core.h (struct GTY): Remove tm_clone_flag
3013 and introduce new lambda_function.
3014 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
3015
3016 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
3017
3018 PR target/87474
3019 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
3020 P8_VECTOR and VSX are enabled.
3021
3022 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
3023
3024 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
3025 0x3907 as CPU model number.
3026
3027 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
3028
3029 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
3030 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
3031 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
3032 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
3033 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
3034 * config/s390/s390.md: Likewise. Rename also the cpu attribute
3035 value from arch12 to z14.
3036
3037 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
3038
3039 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
3040 (isinfxf2): Ditto.
3041 (isinf<mode>2): Ditto.
3042
3043 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
3044
3045 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
3046 before emitting fxam. Perform calculations in XFmode.
3047
3048 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
3049
3050 * match.pd (((X /[ex] A) +- B) * A): New transformation.
3051
3052 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
3053
3054 PR middle-end/87319
3055 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
3056 * tree.c (signed_or_unsigned_type_for): Handle complex.
3057
3058 2018-10-02 Jeff Law <law@redhat.com>
3059
3060 * gimple-fold.c (get_range_strlen): Remove dead code.
3061
3062 2018-10-02 Martin Sebor <msebor@redhat.com>
3063 Jeff Law <law@redhat.com>
3064
3065 * builtins.c (unterminated_array): Add new arguments.
3066 If argument is not terminated, bubble up size and exact
3067 state to callers.
3068 (expand_builtin_strnlen): Detect, avoid expanding
3069 and diagnose unterminated arrays.
3070 (c_strlen): Fill in offset of start of unterminated strings.
3071 * builtins.h (unterminated_array): Update prototype.
3072
3073 2018-10-02 Richard Biener <rguenther@suse.de>
3074
3075 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
3076 of haddv4df, first reduce to SSE width and exploit the fact
3077 that we only need element zero with the reduction result.
3078 (reduc_plus_scal_v2df): Likewise.
3079
3080 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
3081
3082 * dojump.h (do_jump): Delete.
3083 (do_jump_1): Likewise.
3084 (split_comparison): Move around.
3085 * dojump.c (do_jump): Make static.
3086 (do_jump_1): Likewise.
3087 (jumpifnot): Move around.
3088 (jumpifnot_1): Likewise.
3089 (jumpif): Likewise.
3090 (jumpif_1): Likewise.
3091 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
3092
3093 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
3094
3095 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
3096 insns in the delay slot and add_insn_after for the jump insn.
3097
3098 2018-10-02 Richard Biener <rguenther@suse.de>
3099
3100 * tree-inline.c (expand_call_inline): Use the location of
3101 the callee declaration for the inline-entry marker.
3102 * final.c (notice_source_line): Remove special-casing of
3103 NOTE_INSN_INLINE_ENTRY.
3104
3105 2018-10-01 Carl Love <cel@us.ibm.com>
3106
3107 PR 69431
3108 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
3109 (__builtin_mtfsb0): New.
3110 (__builtin_mtfsb1): New.
3111 ( __builtin_set_fpscr_rn): New.
3112 (__builtin_set_fpscr_drn): New.
3113 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
3114 (rs6000_expand_set_fpscr_rn_builtin): Add.
3115 (rs6000_expand_set_fpscr_drn_builtin): Add.
3116 (rs6000_expand_builtin): Add case statement entries for
3117 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
3118 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
3119 RS6000_BUILTIN_MFFSL.
3120 (rs6000_init_builtins): Add ftype initialization and def_builtin
3121 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
3122 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
3123 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
3124 rs6000_mffscdrn): Add define_insn.
3125 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
3126 * doc/extend.texi: Add documentation for the builtins.
3127
3128 2018-10-01 Richard Biener <rguenther@suse.de>
3129
3130 PR tree-optimization/87465
3131 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
3132 causing branch miscounts.
3133
3134 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3135
3136 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
3137 aarch64_option_default_param): New.
3138 (params.h): Include.
3139 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
3140 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
3141 stack-clash protection validation code.
3142
3143 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3144
3145 * params.c (validate_param): New.
3146 (add_params): Use it.
3147 (set_param_value): Refactor param validation into validate_param.
3148 (diagnostic.h): Include.
3149 * diagnostic.h (diagnostic_ready_p): New.
3150
3151 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3152
3153 * params.c (set_param_value):
3154 Add index of parameter being validated.
3155 * common/common-target.def (option_validate_param): New.
3156 * common/common-targhooks.h (default_option_validate_param): New.
3157 * common/common-targhooks.c (default_option_validate_param): New.
3158 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
3159 * doc/tm.texi: Regenerate.
3160
3161 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3162
3163 PR target/86486
3164 * config/aarch64/aarch64.c (aarch64_override_options_internal):
3165 Add validation for stack-clash parameters and set defaults.
3166
3167 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3168
3169 PR target/86486
3170 * configure.ac: Add stack-clash-protection-guard-size.
3171 * doc/install.texi: Document it.
3172 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
3173 * params.def: Update comment for guard-size.
3174 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
3175 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
3176 * configure: Regenerate.
3177
3178 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3179
3180 PR target/86486
3181 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
3182 STACK_DYNAMIC_OFFSET): New.
3183 * config/aarch64/aarch64.c (aarch64_layout_frame):
3184 Update outgoing args size.
3185 (aarch64_stack_clash_protection_alloca_probe_range,
3186 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3187
3188 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3189
3190 PR target/86486
3191 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
3192 probe ranges.
3193 * target.def (stack_clash_protection_alloca_probe_range): New.
3194 (stack_clash_protection_final_dynamic_probe): Remove.
3195 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
3196 (default_stack_clash_protection_final_dynamic_probe): Remove.
3197 * targhooks.c: Likewise.
3198 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3199 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
3200 * doc/tm.texi: Regenerate.
3201
3202 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3203
3204 PR target/86486
3205 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
3206 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
3207 aarch64_clamp_to_uimm12_shift): New.
3208 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
3209 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
3210
3211 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3212
3213 PR target/86486
3214 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
3215
3216 2018-10-01 Jeff Law <law@redhat.com>
3217 Richard Sandiford <richard.sandiford@linaro.org>
3218 Tamar Christina <tamar.christina@arm.com>
3219
3220 PR target/86486
3221 * config/aarch64/aarch64.md
3222 (probe_stack_range): Add k (SP) constraint.
3223 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
3224 STACK_CLASH_MAX_UNROLL_PAGES): New.
3225 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
3226 stack probes for stack clash.
3227 (aarch64_allocate_and_probe_stack_space): New.
3228 (aarch64_expand_prologue): Use it.
3229 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
3230 (aarch64_sub_sp): Add emit_move_imm optional param.
3231
3232 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
3233
3234 PR tree-optimization/87261
3235 * match.pd: Remove trailing whitespace.
3236 Add (x & y) | ~(x | y) -> ~(x ^ y),
3237 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
3238
3239 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3240
3241 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
3242 constraints.
3243 (ashlsi3_insn): Update instruction constraints.
3244 (ashrsi3_insn): Likewise.
3245 (rotrsi3): Likewise.
3246 (add_shift): Likewise.
3247 * config/arc/constraints.md (Csz): New 32 bit constraint. It
3248 avoids placing in the limm field small constants which, otherwise,
3249 could end into a small instruction.
3250
3251 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3252
3253 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
3254 destination register is not odd-even.
3255 (umaddsidi4_split): Likewise.
3256
3257 2018-10-01 Richard Biener <rguenther@suse.de>
3258
3259 * tree-inline.c (expand_call_inline): Store origin of fn
3260 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
3261 * tree.c (block_ultimate_origin): Simplify and do some
3262 checking.
3263
3264 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
3265
3266 * config/i386/mmx.md (EMMS): New int iterator.
3267 (emms): New int attribute.
3268 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
3269 EMMS int iterator. Explicitly declare clobbers.
3270 (mmx_emms): Remove expander.
3271 (mmx_femms): Ditto.
3272 * config/i386/predicates.md (emms_operation): Remove predicate.
3273 (vzeroall_pattern): New predicate.
3274 (vzeroupper_pattern): Rename from vzeroupper_operation.
3275 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
3276 vzeroupper_pattern and vzeroall_pattern predicates.
3277
3278 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
3279
3280 PR rtl-optimization/86939
3281 * ira-lives.c (make_hard_regno_born): Rename from this...
3282 (make_hard_regno_live): ... to this. Remove update to conflict
3283 information. Update function comment.
3284 (make_hard_regno_dead): Add conflict information update. Update
3285 function comment.
3286 (make_object_born): Rename from this...
3287 (make_object_live): ... to this. Remove update to conflict information.
3288 Update function comment.
3289 (make_object_dead): Add conflict information update. Update function
3290 comment.
3291 (mark_pseudo_regno_live): Call make_object_live.
3292 (mark_pseudo_regno_subword_live): Likewise.
3293 (mark_hard_reg_dead): Update function comment.
3294 (mark_hard_reg_live): Call make_hard_regno_live.
3295 (process_bb_node_lives): Likewise.
3296 * lra-lives.c (make_hard_regno_born): Rename from this...
3297 (make_hard_regno_live): ... to this. Remove update to conflict
3298 information. Remove now uneeded check_pic_pseudo_p argument.
3299 Update function comment.
3300 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
3301 to conflict information. Update function comment.
3302 (mark_pseudo_live): Remove update to conflict information. Update
3303 function comment.
3304 (mark_pseudo_dead): Add conflict information update.
3305 (mark_regno_live): Call make_hard_regno_live.
3306 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
3307 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
3308
3309 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
3310
3311 PR target/87370
3312 * config/i386/i386.c (construct_container): Use TImode for
3313 BLKmode values in 2 integer registers.
3314
3315 2018-09-29 Jeff Law <law@redhat.com>
3316
3317 * builtins.c (unterminated_array): Pass in c_strlen_data * to
3318 c_strlen rather than just a tree *.
3319 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
3320 Update recursive calls appropriately. If caller did not provide a
3321 suitable data pointer, create a local one. When a non-terminated
3322 string is discovered, bubble up information about the string via the
3323 c_strlen_data object.
3324 * builtins.h (c_strlen): Update prototype.
3325 (c_strlen_data): New structure.
3326 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
3327 For a type 2 call, if c_strlen indicates a non-terminated string
3328 use the length of the non-terminated string.
3329 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
3330
3331 2018-09-29 Jakub Jelinek <jakub@redhat.com>
3332
3333 PR target/87467
3334 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
3335 __m512d type for __A argument rather than __m512.
3336
3337 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
3338
3339 * match.pd (simple_comparison): Don't optimize if either operand is
3340 a function pointer when target needs function pointer canonicalization.
3341
3342 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3343
3344 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
3345 power5 .. power9 to remove indirection.
3346 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
3347 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
3348 ASM_CPU_476_SPEC): Delete.
3349 (ASM_CPU_SPEC): Adjust.
3350 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
3351 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
3352
3353 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3354
3355 * config.in: Delete HAVE_AS_DCI.
3356 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
3357 * config/rs6000/rs6000.h: Ditto.
3358 * configure.ac: Delete HAVE_AS_DCI.
3359 * configure: Regenerate.
3360
3361 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3362
3363 * config.in (HAVE_AS_LWSYNC): Delete.
3364 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3365 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
3366 do it as a .long .
3367 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3368 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
3369 as a .long .
3370 * configure.ac: Delete HAVE_AS_LWSYNC.
3371 * configure: Regenerate.
3372
3373 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3374 Pierre-Marie de Rodat <derodat@adacore.com>
3375
3376 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
3377 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
3378 (cgraph_node::create_thunk): Add indirect_offset parameter.
3379 (thunk_adjust): Likewise.
3380 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
3381 and initialize the corresponding field with it.
3382 (cgraph_node::dump): Dump indirect_offset field.
3383 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
3384 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
3385 (thunk_adjust): Add indirect_offset parameter and deal with it.
3386 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
3387 pass it to thunk_adjust. Do not call the target hook if it's non-zero
3388 or if the thunk is external or local. Fix formatting. Do not chain
3389 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
3390 if any, in the GIMPLE representation.
3391 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
3392 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
3393 (input_node): Read indirect_offset field.
3394 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
3395 call to thunk_adjust.
3396 * tree-nested.c (struct nesting_info): Add thunk_p field.
3397 (create_nesting_tree): Set it.
3398 (convert_all_function_calls): Copy static chain from targets to thunks.
3399 (finalize_nesting_tree_1): Return early for thunks.
3400 (unnest_nesting_tree_1): Do not finalize thunks.
3401 (gimplify_all_functions): Do not gimplify thunks.
3402
3403 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3404
3405 * opt-suggestions.c (option_proposer::build_option_suggestions):
3406 Release "option_values".
3407
3408 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3409
3410 * coverage.c (get_coverage_counts): Convert problem-reporting dump
3411 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
3412 * dumpfile.c (kind_as_string): New function.
3413 (dump_loc): Rather than a hardcoded prefix of "note: ", use
3414 kind_as_string to vary the prefix based on dump_kind.
3415 (selftest::test_capture_of_dump_calls): Update for above.
3416
3417 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3418
3419 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
3420 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
3421
3422 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3423
3424 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
3425 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
3426 INVALID_REGNUM instead of FPSR_REG.
3427 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
3428 * config/i386/i386.md: Update comment of FP compares.
3429 (fldenv): Do not clobber FPSR_REG.
3430
3431 2018-09-28 Richard Biener <rguenther@suse.de>
3432
3433 * tree.h (BLOCK_ORIGIN): New.
3434 * omp-expand.c (grid_expand_target_grid_body): Assign
3435 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
3436 * tree-inline.c (remap_block): Likewise.
3437 * auto-profile.c (get_function_decl_from_block): Simplify
3438 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
3439 * langhooks.c (lhd_print_error_function): Likewise.
3440 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
3441 Likewise.
3442 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
3443 * tree.c (block_nonartificial_location): Likewise.
3444 (block_ultimate_origin): Likewise.
3445 * tree-pretty-print.c (percent_K_format): Likewise. Remove
3446 no longer needed LTO case.
3447
3448 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
3449 Jan Hubicka <jh@suse.cz>
3450 Martin Jambor <mjambor@suse.cz>
3451
3452 * simplify-rtx.c (simplify_merge_mask): New function.
3453 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
3454 same masks are used in op1 or op2.
3455 (test_vec_merge): New function.
3456 (test_vector_ops): Call test_vec_merge.
3457
3458 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3459
3460 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
3461 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
3462 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
3463 (cypress_costs): Set it.
3464 (supersparc_costs): Likewise.
3465 (hypersparc_costs): Likewise.
3466 (leon_cost): Likewise.
3467 (leon3_costs): Likewise.
3468 (sparclet_costs): Likewise.
3469 (ultrasparc_costs): Likewise.
3470 (ultrasparc_costs): Likewise.
3471 (niagara_costs): Likewise.
3472 (niagara2_costs): Likewise.
3473 (niagara3_costs): Likewise.
3474 (niagara4_costs): Likewise.
3475 (niagara7_costs): Likewise.
3476 (m8_costs): Likewise.
3477 (TARGET_CAN_FOLLOW_JUMP): Define.
3478 (pass_work_around_errata::gate): Minor tweak.
3479 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
3480 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
3481 Automaitcally clear MASK_FSMULD mask for V7 processors.
3482 (sparc_can_follow_jump): New static function.
3483 (output_ubranch): Deal with CROSSING_JUMP_P.
3484 (sparc_use_sched_lookahead): Rewrite using switch statement.
3485 (sparc_issue_rate): Reorder.
3486 (sparc_branch_cost): New function.
3487
3488 2018-09-27 Martin Sebor <msebor@redhat.com>
3489
3490 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
3491 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
3492 (int_fits_type_p): Same.
3493
3494 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
3495
3496 * config/i386/i386.md (FPCR_REG): Remove.
3497 (UNSPEC_FLDCW): Remove.
3498 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
3499 (x86_fldcw_1): Remove insn pattern.
3500 (fnstenv): Do not clobber FPCR_REG.
3501 (fldenv): Ditto.
3502 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
3503 (CALL_USED_REGISTERS): Ditto.
3504 (REG_ALLOC_ORDER): Ditto.
3505 (REG_CLASS_CONTENTS): Ditto.
3506 (HI_REGISTER_NAMES): Ditto.
3507 (ADDITIONAL_REGISTER_NAMES): Use defines instead
3508 of numerical constants.
3509 * config/i386/i386.c (regclass_map): Remove fpsr register.
3510 (dbx_register_map): Ditto.
3511 (dbx64_register_map): Ditto.
3512 (svr4_dbx_register_map): Ditto.
3513 (print_reg): Do not handle FPCR_REG.
3514
3515 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
3516
3517 PR target/87149
3518 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
3519 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
3520 Delete, always treat as true.
3521 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
3522 Ditto. Simplify remaining code.
3523 * config/powerpcspe/powerpcspe.h: Ditto.
3524 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
3525 Simplify remaining code.
3526 (rs6000_expand_builtin): Ditto.
3527 * config/rs6000/rs6000.h: Ditto.
3528 * configure.ac: Ditto.
3529 * configure: Regenerate.
3530
3531 2018-09-27 Martin Liska <mliska@suse.cz>
3532
3533 * coverage.c (get_coverage_counts): Revert the formatting
3534 of missing profile opt info.
3535
3536 2018-09-27 Richard Biener <rguenther@suse.de>
3537
3538 PR debug/37801
3539 PR debug/87440
3540 * dwarf2out.c (set_block_origin_self): Do not mark outermost
3541 block as we do not output that.
3542 (gen_inlined_subroutine_die): Elide the originally outermost
3543 block, matching what we do for concrete instances.
3544 (decls_for_scope): Add parameter specifying whether to recurse
3545 to subblocks.
3546
3547 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
3548 Tom de Vries <tom@codesourcery.com>
3549
3550 PR 82089
3551
3552 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
3553 STORE_FLAG_VALUE == 1.
3554
3555 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
3556
3557 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
3558 constant definitions.
3559 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
3560 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
3561 ("speculation_barrier"): New expander definition.
3562
3563 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
3564
3565 PR gcov-profile/86957
3566 * common.opt: New warning option -Wmissing-profile.
3567 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
3568 * doc/invoke.texi: Document -Wmissing-profile.
3569
3570 2018-09-26 Jim Wilson <jimw@sifive.com>
3571
3572 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
3573 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
3574
3575 2018-09-26 Martin Sebor <msebor@redhat.com>
3576
3577 * tree.c (zerop): Change return type to bool.
3578 (integer_zerop, integer_onep, integer_each_onep): Same.
3579 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3580 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3581 (real_onep, real_minus_onep, chain_index): Same.
3582 (print_type_hash_statistics, type_list_equal): Same.
3583 * tree.h (zerop): Same.
3584 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
3585 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3586 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3587 (real_onep, real_minus_onep, chain_index): Same.
3588 (print_type_hash_statistics, type_list_equal): Same.
3589
3590 2018-09-26 Jim Wilson <jimw@sifive.com>
3591
3592 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
3593
3594 2018-09-26 Jakub Jelinek <jakub@redhat.com>
3595
3596 PR target/87414
3597 * config/i386/i386.c: Include debug.h and dwarf2out.h.
3598 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
3599 call.
3600
3601 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
3602
3603 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
3604
3605 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3606
3607 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
3608 and FP_SECOND_SSE_REGS.
3609 (REG_CLASS_NAMES): Ditto.
3610 (REG_CLASS_CONTENTS): Ditto.
3611 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
3612 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
3613 (ix86_preferred_output_reload_class): Ditto.
3614 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
3615 clobber constraint to "=&f".
3616 (fix_truncdi_i387): Ditto.
3617 (lrintxfdi2): Ditto.
3618 (fistdi2_<rounding>): Ditto.
3619 (fpremxf4_i387): Change "=u" constraint to "=f".
3620 (fprem1xf4_i387): Ditto.
3621 (sincosxf3): Ditto.
3622 (fptanxf4_i387): Ditto.
3623 (fxtractxf3_i387): Ditto.
3624 (fscalexf4_i387): Ditto.
3625 (atan2xf3): Change "u" constraint to "f".
3626 (fyl2xxf3_i387): Ditto.
3627 (fyl2xp1xf3_i387): Ditto.
3628
3629 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3630
3631 PR target/87439
3632 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
3633 for removed I387_MASK_PM entity.
3634
3635
3636 2018-09-26 Jeff Law <law@redhat.com>
3637 Revert
3638 2018-09-26 Alexey Neyman <stilor@att.net>
3639
3640 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3641 headers are no longer pulled in by <isl/val.h>.
3642
3643 2018-09-26 Richard Biener <rguenther@suse.de>
3644
3645 PR debug/87443
3646 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
3647 or concrete instance DIE to the tree. Create abstract origin
3648 attributes also for concrete instances.
3649
3650 2018-09-26 Alexey Neyman <stilor@att.net>
3651
3652 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3653 headers are no longer pulled in by <isl/val.h>.
3654
3655 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
3656
3657 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
3658 Use new helper functions.
3659 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
3660 Use new helper functions.
3661 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
3662 aarch_mm_needs_release): New declarations.
3663 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
3664 aarch_mm_needs_release): New.
3665
3666 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
3667
3668 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
3669 (arm32_output_mi_thunk): Deal with long calls.
3670
3671 2018-09-26 Richard Biener <rguenther@suse.de>
3672
3673 PR debug/87428
3674 PR debug/87362
3675 * tree-inline.c (expand_call_inline): When the location
3676 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
3677 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
3678 the inserted BLOCK to make inlined_function_outer_scope_p
3679 recognize it.
3680 * dwarf2out.c (add_call_src_coords_attributes): Do not add
3681 coords for reserved locations.
3682
3683 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3684
3685 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
3686 (*call_indirect_nonlocal_sysv<mode>): Ditto.
3687 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
3688 (*sibcall_nonlocal_sysv<mode>): Ditto.
3689 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
3690 (<bd>_<mode>): Ditto.
3691 (<bd>tf_<mode>): Ditto.
3692
3693 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3694
3695 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
3696 control string as a list of templates instead of as C code.
3697 (*altivec_movti): Ditto.
3698 * config/rs6000/darwin.md (movdf_low_di): Ditto.
3699
3700 2018-09-25 Jim Wilson <jimw@sifive.com>
3701
3702 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
3703 when target symbol is weak.
3704
3705 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
3706
3707 PR c/87387
3708 * builtins.c (unterminated_array): Simplify.
3709 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
3710 where pointer arithmetic is safe.
3711
3712 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3713
3714 PR target/86987
3715 * config/rs6000/altivec.md (altivec_vspltb): Use
3716 const_0_to_15_operand instead of u5bit_cint_operand.
3717 (*altivec_vspltb_internal): Ditto.
3718 (altivec_vspltb_direct): Ditto.
3719 (altivec_vsplth): Use const_0_to_7_operand instead of
3720 u5bit_cint_operand.
3721 (*altivec_vsplth_internal): Ditto.
3722 (altivec_vsplth_direct): Ditto.
3723 (altivec_vspltw): Use const_0_to_3_operand instead of
3724 u5bit_cint_operand.
3725 (*altivec_vspltw_internal): Ditto.
3726 (altivec_vspltw_direct): Ditto.
3727 (altivec_vspltsf): Ditto.
3728 (*altivec_vspltsf_internal): Ditto.
3729 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
3730 various splats with the proper size immediate. Reorder the various
3731 cases by ascending size of immediate, and put all such together.
3732
3733 2018-09-25 Richard Biener <rguenther@suse.de>
3734
3735 PR debug/83941
3736 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
3737 GC-ification.
3738 (maybe_create_die_with_external_ref): Do not create
3739 DW_TAG_imported_unit here.
3740 (add_abstract_origin_attribute): Handle external BLOCK refs.
3741 (dwarf2out_abstract_function): Simplify LTO case.
3742 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
3743 rather than using maybe_create_die_with_external_ref.
3744
3745 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
3746
3747 PR target/71278
3748 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
3749 (frndintxf2_mask_pm_i387): Ditto.
3750 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
3751 Enable for !flag_trapping_math.
3752 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
3753 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
3754 Change operand 1 predicate to nonimmediate_operand.
3755 (attr "i387_cw"): Remove mask_pm.
3756 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
3757 (enum ix86_entity): Remove I387_MASK_PM.
3758 * config/i386/i386.c (ix86_i387_mode_needed): Do not
3759 handle I387_MASK_PM.
3760 (ix86_mode_needed): Ditto.
3761 (ix86_mode_after): Ditto.
3762 (ix86_mode_entry): Ditto.
3763 (ix86_mode_exit): Ditto.
3764 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
3765
3766 2018-09-25 Jakub Jelinek <jakub@redhat.com>
3767
3768 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
3769 to_update_switch_stmts to vNULL instead of calling create on them
3770 immediately.
3771
3772 2018-09-25 Richard Biener <rguenther@suse.de>
3773
3774 PR tree-optimization/87402
3775 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
3776 (visit_phi): Re-instantiate handling of supposed to be VARYING
3777 but non-VARYING backedge value.
3778
3779 2018-09-25 Richard Biener <rguenther@suse.de>
3780
3781 PR debug/83941
3782 * dwarf2out.c (struct sym_off_pair): New.
3783 (external_die_map): New global.
3784 (lookup_decl_die): When in LTO create DIEs lazily from the
3785 external_die_map.
3786 (lookup_block_die): New function, create DIEs lazily in LTO.
3787 (equate_block_to_die): New function.
3788 (dwarf2out_die_ref_for_decl): During WPA get the association
3789 from the external DIE map.
3790 (dwarf2out_register_external_die): Record mapping into the
3791 external DIE map.
3792 (maybe_create_die_with_external_ref): New function split out from
3793 DIE generation part of old dwarf2out_register_external_die.
3794 (add_abstract_origin_attribute): Do not return the DIE. When
3795 in LTO reference externals directly.
3796 (dwarf2out_abstract_function): When in LTO ignore calls for
3797 decls with external DIEs (already present abstract instances).
3798 (gen_call_site_die): Adjust.
3799 (add_high_low_attributes): Likewise.
3800 (gen_lexical_block_die): Likewise.
3801 (gen_inlined_subroutine_die): Likewie.
3802 (gen_block_die): Likewise.
3803 (dwarf2out_inline_entry): Likewise.
3804 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
3805 DIEs.
3806
3807 2018-09-25 Martin Liska <mliska@suse.cz>
3808
3809 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
3810 integers and not by a float value.
3811
3812 2018-09-25 Martin Liska <mliska@suse.cz>
3813
3814 PR fortran/87394
3815 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
3816 instead of NULL.
3817 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
3818 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
3819 * godump.c (go_format_type): Remove extra parenthesis.
3820
3821 2018-09-25 Martin Liska <mliska@suse.cz>
3822
3823 * alias.c (set_dest_equal_p): Remove unused function.
3824 * config/i386/i386.c (def_builtin_pure2): Likewise.
3825 * diagnostic-show-locus.c (class layout): Remove
3826 unused field.
3827 (layout::layout): Likewise here.
3828 * dump-context.h (class temp_dump_context): Likewise.
3829 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
3830 (add_AT_loclistsptr): Likewise.
3831 (add_AT_offset): Likewise.
3832 (get_AT_hi_pc): Likewise.
3833 (is_comdat_die): Likewise.
3834 (type_is_enum): Likewise.
3835 (ceiling): Likewise.
3836 (add_AT_vms_delta): Likewise.
3837 (is_class_die): Likewise.
3838 * edit-context.c (class line_event): Remove unused field.
3839 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
3840 unused function.
3841 * ipa-cp.c (ipa_get_vr_lat): Likewise.
3842 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
3843 (ok_for_base_p_nonstrict): Likewise.
3844 * tree-chrec.c (is_not_constant_evolution): Likewise.
3845 (chrec_fold_poly_cst): Likewise.
3846 * tree-if-conv.c (has_pred_critical_p): Likewise.
3847 * tree-ssa-coalesce.c (print_exprs): Likewise.
3848 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
3849 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
3850 * tree-vrp.c (value_ranges_intersect_p): Likewise.
3851 (value_range_nonnegative_p): Likewise.
3852
3853 2018-09-25 Martin Liska <mliska@suse.cz>
3854
3855 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
3856 Do not handle "GNU Pascal".
3857 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
3858 Likewise.
3859 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
3860 from documentation. Likewise.
3861 * dbxout.c (dbxout_range_type): Likewise.
3862 * doc/cpp.texi: Likewise.
3863 * doc/extend.texi: Likewise.
3864 * doc/frontends.texi: Likewise.
3865 * doc/invoke.texi: Remove Pascal entry.
3866 * tree.def (CLEANUP_POINT_EXPR): Likewise.
3867 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
3868
3869 2018-09-25 Martin Liska <mliska@suse.cz>
3870
3871 PR middle-end/86078
3872 * doc/invoke.texi: Document all parameters and remove default
3873 of the parameters.
3874
3875 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
3876
3877 PR bootstrap/87417
3878 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
3879 contains HOST_WIDE_INTs when computing its size.
3880
3881 2018-09-24 Jim Wilson <jimw@sifive.com>
3882
3883 PR target/87391
3884 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
3885 not TARGET_RVE.
3886 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
3887
3888 2018-09-24 Andrew Pinski <apinski@marvell.com>
3889
3890 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
3891 access prev before checking it for NULLness in the
3892 AARCH64_FUSE_CMP_BRANCH case.
3893
3894 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
3895
3896 PR target/82699
3897 * config/i386/i386.c (rest_of_insert_endbranch): Set
3898 endbr_queued_at_entrance to true and don't insert ENDBR if
3899 x86_function_profiler will be called.
3900 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
3901 is true.
3902 * config/i386/i386.h (machine_function): Add
3903 endbr_queued_at_entrance.
3904
3905 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3906
3907 * genattrtab.c (mk_attr_alt): Use alternative_mask.
3908 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
3909 types.
3910 (check_attr_test): Use alternative_mask.
3911 (get_attr_value): Likewise.
3912 (compute_alternative_mask): Use alternative_mask and XWINT.
3913 (make_alternative_compare): Use alternative_mask.
3914 (attr_alt_subset_p): Use XWINT.
3915 (attr_alt_subset_of_compl_p): Likewise.
3916 (attr_alt_intersection): Use alternative_mask and XWINT.
3917 (attr_alt_union): Likewise.
3918 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
3919 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
3920 (simplify_test_exp): Use alternative_mask and XWINT.
3921 (write_test_expr): Use alternative_mask and XWINT, adjust bit
3922 number calculation to support 64 bits. Generate code that
3923 checks 64-bit masks.
3924 (main): Use alternative_mask.
3925 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
3926
3927 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3928
3929 PR target/80080
3930 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
3931 RETURN+USE when returning via %r14.
3932
3933 2018-09-24 Martin Liska <mliska@suse.cz>
3934
3935 * gcov.c (output_lines): Print colorization legend
3936 for both flag_use_colors and flag_use_hotness_colors.
3937 Reword the help.
3938
3939 2018-09-24 Martin Liska <mliska@suse.cz>
3940
3941 * coverage.c (get_coverage_counts): Use warning_at
3942 with current_function_decl location. Use %qD in warning
3943 message.
3944
3945 2018-09-24 Martin Liska <mliska@suse.cz>
3946
3947 * memory-block.h (memory_block_pool::release): Annotate with
3948 valgrind that the memory is not accessible.
3949
3950 2018-09-24 Martin Liska <mliska@suse.cz>
3951
3952 PR sanitizer/85774
3953 * asan.c: Make asan_handled_variables extern.
3954 * asan.h: Likewise.
3955 * cfgexpand.c (expand_stack_vars): Make sure
3956 a representative is unpoison if another
3957 variable in the partition is handled by
3958 use-after-scope sanitization.
3959
3960 2018-09-24 Richard Biener <rguenther@suse.de>
3961
3962 PR tree-optimization/63155
3963 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
3964 the worklist when the edge of the respective argument isn't
3965 executable.
3966
3967 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3968
3969 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
3970 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
3971 (MASK_CLASS_P): Update for rename.
3972 (MAYBE_MASK_CLASS_P): Ditto.
3973 (REG_CLASS_NAMES): Update.
3974 (REG_CLASS_CONTENT): Update.
3975 * config/i386/i386.c (regclass_map): Update for MASK_REG
3976 and ALL_MASK_REGS rename.
3977 * config/i386/constraints.md (Yk): Update for rename.
3978 (k): Ditto.
3979
3980 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3981
3982 * config/i386/i386.h (enum reg_class): Remove
3983 EVEX_SSE_REGS and MOD4_SSE_REGS.
3984 (REG_CLASS_NAMES): Update.
3985 (REG_CLASS_CONTENT): Update.
3986 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
3987 registers as ALL_SSE_REGS.
3988 (ix86_additional_allocno_class_p): Remove.
3989 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
3990 (ix86_register_priority): Lower priority of EVEX SSE registers.
3991 Use IN_RANGE macro where appropriate.
3992 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
3993 AVX-5124VNNIW checks.
3994 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
3995 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
3996 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
3997 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
3998 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
3999 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
4000 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
4001 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
4002 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
4003 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
4004 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
4005 * config/i386/constraints.md (Yh): Remove.
4006
4007 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
4008
4009 * config/i386/i386.c (regclass_map): Declare integer REX registers
4010 as GENERAL_REGS.
4011
4012 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
4013
4014 * doc/service.texi (Service): Switch the fsf.org link to https.
4015
4016 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
4017
4018 PR target/86798
4019 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4020 Define to speculation_safe_value_not_needed.
4021
4022 2018-09-21 Florian Weimer <fweimer@redhat.com>
4023
4024 PR middle-end/81035
4025 * doc/extend.texi (Common Function Attributes): Mention that
4026 noreturn suppresses tail call optimization.
4027
4028 2018-09-21 Jeff Law <law@redhat.com>
4029
4030 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
4031 vr_values::cleanup_edges_and_switches.
4032 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
4033 vr_values class.
4034 (identify_jump_threads): Remove EDGE_IGNORE handling.
4035 (execute_vrp): Move handling of to_remove_edges and
4036 to_update_switch_stmts into vr_values class member functions.
4037 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
4038 (to_update_switch_stmts): Likewise.
4039 * vr-values.c: Include cfghooks.h.
4040 (vr_values::vr_values): Initialize to_remove_edges and
4041 to_update_switch_stmts.
4042 (vr_values::~vr_values): Verify to_remove_edges and
4043 to_update_switch_stmts are empty.
4044 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
4045 (vr_values::cleanup_edges_and_switches): New member function.
4046 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
4047 function. Add new data members.
4048
4049 2018-09-21 David Malcolm <dmalcolm@redhat.com>
4050
4051 PR tree-optimization/87309
4052 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
4053 calls with pflags and alt_flags.
4054 (selftest::test_capture_of_dump_calls): Add test of interaction of
4055 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
4056
4057 2018-09-21 Olivier Hainque <hainque@adacore.com>
4058
4059 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
4060
4061 2018-09-21 Olivier Hainque <hainque@adacore.com>
4062
4063 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
4064
4065 2018-09-21 Olivier Hainque <hainque@adacore.com>
4066
4067 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
4068 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
4069 (VXWORKS_LIBS_RTP): Minor reordering.
4070
4071 2018-09-21 Olivier Hainque <hainque@adacore.com>
4072
4073 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
4074 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
4075
4076 2018-09-21 Olivier Hainque <hainque@adacore.com>
4077
4078 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
4079 (PTRDIFF_TYPE): Likewise.
4080
4081 2018-09-21 Olivier Hainque <hainque@adacore.com>
4082
4083 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
4084 triplet, similar to support for VxWorks7.
4085 * config/vxworks-dummy.h: Provide a default definition
4086 of TARGET_VXWORKS64 to 0.
4087
4088 2018-09-21 Olivier Hainque <hainque@adacore.com>
4089
4090 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
4091 * config/vxworks-dummy.h: here.
4092
4093 2018-09-21 Olivier Hainque <hainque@adacore.com>
4094
4095 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
4096
4097 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
4098 Bo Zhou <zbo.zhou@hisilicon.com>
4099
4100 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
4101 * config/aarch64/aarch64-tune.md: Regenerated.
4102 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
4103 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
4104 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
4105
4106 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
4107 Julian Brown <julian@codesourcery.com>
4108
4109 * builtins.c (get_builtin_sync_mem): Handle address spaces.
4110
4111 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4112
4113 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
4114 if the call takes a static chain.
4115
4116 2018-09-21 Martin Liska <mliska@suse.cz>
4117
4118 * auto-profile.c (autofdo_source_profile::read): Do not
4119 set sum_all.
4120 (read_profile): Do not add working sets.
4121 (read_autofdo_file): Remove sum_all.
4122 (afdo_callsite_hot_enough_for_early_inline): Remove const
4123 qualifier.
4124 * coverage.c (struct counts_entry): Remove gcov_summary.
4125 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
4126 do not support GCOV_TAG_PROGRAM_SUMMARY.
4127 (get_coverage_counts): Remove summary and expected
4128 arguments.
4129 * coverage.h (get_coverage_counts): Likewise.
4130 * doc/gcov-dump.texi: Remove -w option.
4131 * gcov-dump.c (dump_working_sets): Remove.
4132 (main): Do not support '-w' option.
4133 (print_usage): Likewise.
4134 (tag_summary): Likewise.
4135 * gcov-io.c (gcov_write_summary): Do not dump
4136 histogram.
4137 (gcov_read_summary): Likewise.
4138 (gcov_histo_index): Remove.
4139 (gcov_histogram_merge): Likewise.
4140 (compute_working_sets): Likewise.
4141 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
4142 it not obsolete.
4143 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
4144 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
4145 (GCOV_HISTOGRAM_SIZE): Remove.
4146 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
4147 (struct gcov_summary): Simplify rapidly just
4148 to runs and sum_max fields.
4149 (gcov_histo_index): Remove.
4150 (NUM_GCOV_WORKING_SETS): Likewise.
4151 (compute_working_sets): Likewise.
4152 * gcov-tool.c (print_overlap_usage_message): Remove
4153 trailing empty line.
4154 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
4155 (output_lines): Remove program related line.
4156 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
4157 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
4158 histogram.
4159 (input_profile_summary): Do not read it.
4160 (merge_profile_summaries): And do not merge it.
4161 (input_symtab): Do not call removed function.
4162 * modulo-sched.c (sms_schedule): Do not print sum_max.
4163 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
4164 removed when histogram method was invented.
4165 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
4166 mode.
4167 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
4168 GCOV coding style.
4169 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
4170 and dump selected value.
4171 * profile.c (add_working_set): Remove.
4172 (get_working_sets): Likewise.
4173 (find_working_set): Likewise.
4174 (get_exec_counts): Do not work with working sets.
4175 (read_profile_edge_counts): Do not inform as sum_max is removed.
4176 (compute_branch_probabilities): Likewise.
4177 (compute_value_histograms): Remove argument for call of
4178 get_coverage_counts.
4179 * profile.h: Do not make gcov_summary const.
4180
4181 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
4182
4183 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
4184
4185 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4186
4187 PR tree-optimization/86990
4188 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
4189 Check that the entire merged store group is made of constants only for
4190 overlapping stores.
4191
4192 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
4193
4194 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
4195 (VTABLE_VERIFICATION_SPEC): Likewise.
4196 (SANITIZER_EARLY_SPEC): Likewise.
4197 (SANITIZER_SPEC): Likewise.
4198 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
4199 * doc/invoke.texi (Link Options): Document -r.
4200
4201 2018-09-20 Richard Biener <rguenther@suse.de>
4202
4203 PR middle-end/87054
4204 * gimplify.c (gimplify_expr): Retain alignment of
4205 addressable lvalue in dereference.
4206
4207 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
4208
4209 PR bootstrap/87013
4210 * configure.ac: Check for .loc is_stmt support.
4211 * configure, config.in: Rebuilt.
4212 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
4213 if not supported.
4214
4215 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4216
4217 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
4218 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
4219 -misel=no.
4220
4221 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4222
4223 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
4224 VECTOR_OTHER.
4225 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
4226 case VECTOR_OTHER.
4227
4228 2018-09-20 Marek Polacek <polacek@redhat.com>
4229
4230 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
4231
4232 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4233
4234 PR tree-optimization/87288
4235 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
4236 into account when determining PEELING_FOR_NITERS.
4237
4238 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4239
4240 PR tree-optimization/86877
4241 * tree-vect-loop.c (vect_analyze_loop_2): Call
4242 vect_verify_datarefs_alignment.
4243
4244 2018-09-19 Marek Polacek <polacek@redhat.com>
4245
4246 * doc/invoke.texi: Document -Wclass-conversion.
4247
4248 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
4249
4250 * config/pa/pa.c (pa_adjust_priority): Delete.
4251 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
4252
4253 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
4254 (atomic_storehi): Likewise.
4255 (atomic_storesi): Likewise.
4256 (atomic_loaddi): Restore compare and swap exchange loop code.
4257
4258 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
4259
4260 PR rtl-optimization/86902
4261 * combine.c (try_combine): When changing the CC mode used, don't change
4262 an unrelated mode in other_insn to that new CC mode.
4263
4264 2018-09-19 David Malcolm <dmalcolm@redhat.com>
4265
4266 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
4267 with %T in place of calls to dump_generic_expr.
4268 (prune_runtime_alias_test_list): Likewise.
4269 (create_runtime_alias_checks): Likewise.
4270 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
4271 (vect_analyze_data_ref_dependence): Likewise.
4272 (vect_slp_analyze_data_ref_dependence): Likewise.
4273 (vect_record_base_alignment): Likewise. Use %G in place of call
4274 to dump_gimple_stmt.
4275 (vect_compute_data_ref_alignment): Likewise.
4276 (verify_data_ref_alignment): Likewise.
4277 (vect_find_same_alignment_drs): Likewise.
4278 (vect_analyze_group_access_1): Likewise.
4279 (vect_analyze_data_ref_accesses): Likewise.
4280 (dependence_distance_ge_vf): Likewise.
4281 (dump_lower_bound): Likewise.
4282 (vect_prune_runtime_alias_test_list): Likewise.
4283 (vect_find_stmt_data_reference): Likewise.
4284 (vect_analyze_data_refs): Likewise.
4285 (vect_create_addr_base_for_vector_ref): Likewise.
4286 (vect_create_data_ref_ptr): Likewise.
4287 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
4288 (vect_can_advance_ivs_p): Likewise.
4289 (vect_update_ivs_after_vectorizer): Likewise.
4290 (vect_gen_prolog_loop_niters): Likewise.
4291 (vect_prepare_for_masked_peels): Likewise.
4292 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
4293 (vect_determine_vectorization_factor): Likewise.
4294 (vect_is_simple_iv_evolution): Likewise.
4295 (vect_analyze_scalar_cycles_1): Likewise.
4296 (vect_analyze_loop_operations): Likewise.
4297 (report_vect_op): Likewise.
4298 (vect_is_slp_reduction): Likewise.
4299 (check_reduction_path): Likewise.
4300 (vect_is_simple_reduction): Likewise.
4301 (vect_create_epilog_for_reduction): Likewise.
4302 (vect_finalize_reduction:): Likewise.
4303 (vectorizable_induction): Likewise.
4304 (vect_transform_loop_stmt): Likewise.
4305 (vect_transform_loop): Likewise.
4306 (optimize_mask_stores): Likewise.
4307 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
4308 (vect_split_statement): Likewise.
4309 (vect_recog_over_widening_pattern): Likewise.
4310 (vect_recog_average_pattern): Likewise.
4311 (vect_determine_min_output_precision_1): Likewise.
4312 (vect_determine_precisions_from_range): Likewise.
4313 (vect_determine_precisions_from_users): Likewise.
4314 (vect_mark_pattern_stmts): Likewise.
4315 (vect_pattern_recog_1): Likewise.
4316 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
4317 (vect_record_max_nunits): Likewise.
4318 (vect_build_slp_tree_1): Likewise.
4319 (vect_build_slp_tree_2): Likewise.
4320 (vect_print_slp_tree): Likewise.
4321 (vect_analyze_slp_instance): Likewise.
4322 (vect_detect_hybrid_slp_stmts): Likewise.
4323 (vect_detect_hybrid_slp_1): Likewise.
4324 (vect_slp_analyze_operations): Likewise.
4325 (vect_slp_analyze_bb_1): Likewise.
4326 (vect_transform_slp_perm_load): Likewise.
4327 (vect_schedule_slp_instance): Likewise.
4328 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
4329 (vect_mark_stmts_to_be_vectorized): Likewise.
4330 (vect_init_vector_1): Likewise.
4331 (vect_get_vec_def_for_operand): Likewise.
4332 (vect_finish_stmt_generation_1): Likewise.
4333 (vect_check_load_store_mask): Likewise.
4334 (vectorizable_call): Likewise.
4335 (vectorizable_conversion): Likewise.
4336 (vectorizable_operation): Likewise.
4337 (vectorizable_load): Likewise.
4338 (vect_analyze_stmt): Likewise.
4339 (vect_is_simple_use): Likewise.
4340 (vect_get_vector_types_for_stmt): Likewise.
4341 (vect_get_mask_type_for_stmt): Likewise.
4342 * tree-vectorizer.c (increase_alignment): Likewise.
4343
4344 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
4345
4346 * doc/rtl.texi: Adjust vec_select description.
4347 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
4348 non-constant selectors.
4349
4350 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
4351
4352 * config/aarch64/aarch64-protos.h
4353 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
4354 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
4355 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
4356 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
4357 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
4358 (AARCH64_FL_PROFILE): Move index so flags are ordered.
4359 (AARCH64_ISA_RCPC8_4): New flag.
4360 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
4361 to aarch64_offset_9bit_signed_unscaled_p.
4362 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
4363 and use stlur.
4364 * config/aarch64/constraints.md (Ust): New constraint.
4365 * config/aarch64/predicates.md.
4366 (aarch64_9bit_offset_memory_operand): New predicate.
4367 (aarch64_rcpc_memory_operand): New predicate.
4368
4369 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
4370
4371 PR rtl-optimization/87361
4372 * rtlanal.c (nonzero_bits1): Revert accidental change.
4373
4374 2018-09-19 Richard Biener <rguenther@suse.de>
4375
4376 PR tree-optimization/87349
4377 PR tree-optimization/87342
4378 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
4379
4380 2018-09-18 Marek Polacek <polacek@redhat.com>
4381
4382 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
4383 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
4384
4385 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4386
4387 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
4388
4389 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4390
4391 PR rtl-optimization/86882
4392 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
4393
4394 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
4395
4396 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
4397 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
4398
4399 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
4400
4401 PR other/87353
4402 * doc/invoke.texi (Link Options): Fix formatting and grammar.
4403
4404 2018-09-18 Richard Biener <rguenther@suse.de>
4405
4406 PR middle-end/63155
4407 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
4408 (compute_samebase_partition_bases): Likewise.
4409 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
4410 (gimple_can_coalesce_p): Simplify.
4411
4412 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
4413
4414 Handle a library implementation of ffs calling __builtin_ffs.
4415 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
4416 (mmix_init_libfuncs): New function: make __builtin_ffs expand
4417 to __ffsdi2.
4418
4419 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4420
4421 * diagnostic-show-locus.c (class layout_range): Add field
4422 "m_original_idx".
4423 (layout_range::layout_range): Add "original_idx" param and use it
4424 to initialize new field.
4425 (make_range): Use 0 for original_idx.
4426 (layout::layout): Pass in index to calls to
4427 maybe_add_location_range.
4428 (layout::maybe_add_location_range): Add param "original_idx" and
4429 pass it on to layout_range.
4430 (layout::print_any_labels): Pass on range->m_original_idx to
4431 get_text call.
4432 (gcc_rich_location::add_location_if_nearby): Use 0 for
4433 original_idx.
4434 * gcc-rich-location.h (text_range_label::get_text): Update for new
4435 param.
4436 (range_label_for_type_mismatch::get_text): Likewise.
4437
4438 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4439
4440 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
4441
4442 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4443
4444 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
4445 format_string_diagnostic_t.
4446 (fmtwarn_n): Likewise.
4447 * substring-locations.c
4448 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
4449 (format_warning_n_va): Convert to...
4450 (format_string_diagnostic_t::emit_warning_n_va): ...this.
4451 (format_warning_va): Convert to...
4452 (format_string_diagnostic_t::emit_warning_va): ...this.
4453 (format_warning_at_substring): Convert to...
4454 (format_string_diagnostic_t::emit_warning): ...this.
4455 (format_warning_at_substring_n): Convert to...
4456 (format_string_diagnostic_t::emit_warning_n): ...this.
4457 * substring-locations.h (class format_string_diagnostic_t): New
4458 class.
4459 (format_warning_va): Convert to
4460 format_string_diagnostic_t::emit_warning_va.
4461 (format_warning_n_va): Convert to
4462 format_string_diagnostic_t::emit_warning_n_va.
4463 (format_warning_at_substring): Convert to
4464 format_string_diagnostic_t::emit_warning.
4465 (format_warning_at_substring_n): Convert to
4466 format_string_diagnostic_t::emit_warning_n.
4467
4468 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
4469 Bernd Schmidt <bernds_cb1@t-online.de>
4470
4471 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
4472 SImode args.
4473
4474 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4475
4476 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
4477 operand 0 predicate to nonimmediate operand.
4478 (rint<mode>2_frndint): Remove insn pattern.
4479 (rint<mode>2): Change operand 1 predicate to general_operand.
4480 Extend operand 1 to XFmode and generate rintxf2 insn.
4481 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
4482 Do not use X87MODEF mode macro.
4483 (frndintxf2_<rounding>_i387): Rename from
4484 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
4485 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
4486 to XFmode and generate significandxf3 insn.
4487
4488 2018-09-17 Richard Biener <rguenther@suse.de>
4489
4490 PR tree-optimization/87328
4491 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
4492 visiting unexecutable backedges when not iterating.
4493 (do_rpo_vn): Mark all edges not executable even when not
4494 iterating.
4495
4496 2018-09-17 Martin Jambor <mjambor@suse.cz>
4497
4498 PR c/63886
4499 * doc/invoke.texi (Warning Options): Likewise.
4500
4501 2018-09-17 Richard Biener <rguenther@suse.de>
4502
4503 PR tree-optimization/87301
4504 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
4505 clean EH info from leftover copy assignments.
4506
4507 2018-09-17 Martin Liska <mliska@suse.cz>
4508
4509 PR gcov-profile/85871
4510 * gcov.c (output_intermediate_file): Fix out of bounds
4511 access.
4512
4513 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
4514
4515 * config/arc/arc.c: Object attributes for core4 not reflected
4516 correctly.
4517 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
4518 core3).
4519
4520 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
4521
4522 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
4523
4524 2018-09-17 Martin Liska <mliska@suse.cz>
4525
4526 * doc/gcov.texi: Document new option --use-hotness-colors.
4527 * gcov.c (struct source_info): Declare new field.
4528 (source_info::source_info): Set default for maximum_count.
4529 (print_usage): Add new -q option.
4530 (process_args): Process it.
4531 (accumulate_line_info): Save src->maximum_count.
4532 (output_line_beginning): Make color line number if
4533 flag_use_hotness_colors is set.
4534 (output_line_details): Pass default argument value.
4535 (output_lines): Pass src->maximum_count.
4536
4537 2018-09-17 Martin Liska <mliska@suse.cz>
4538
4539 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
4540 Use processor_names table.
4541 * config/i386/i386.c (ix86_default_align): Use
4542 processor_cost_table for alignment values.
4543 (ix86_option_override_internal): Use processor_names.
4544 (ix86_function_specific_print): Likewise.
4545 * config/i386/i386.h (struct processor_costs):
4546 Add alignment values.
4547 (struct ptt): Remove and replace with const char *.
4548 * config/i386/x86-tune-costs.h (struct processor_costs):
4549 Declare default alignments for all costs.
4550
4551 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
4552
4553 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
4554 symbolics or VR_VARYING ranges for ABS_EXPR.
4555 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
4556 when range will wrap.
4557
4558 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
4559
4560 PR middle-end/86864
4561 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
4562 before and after a JUMP_TABLE_DATA.
4563
4564 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
4565
4566 PR middle-end/87188
4567 * dojump.c (do_compare_and_jump): Canonicalize function pointers
4568 when one operand is a function pointer. Use POINTER_TYPE_P and
4569 FUNC_OR_METHOD_TYPE_P.
4570 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
4571 * fold-const.c (build_range_check): Likewise.
4572 * match.pd (simple_comparison): Likewise.
4573
4574 2018-09-14 David Malcolm <dmalcolm@redhat.com>
4575
4576 PR c/82967
4577 * spellcheck.c (get_edit_distance_cutoff): New function.
4578 (selftest::test_edit_distance_unit_test_oneway): Rename to...
4579 (selftest::test_get_edit_distance_one_way): ...this.
4580 (selftest::test_get_edit_distance_unit): Rename to...
4581 (selftest::test_get_edit_distance_both_ways): ...this.
4582 (selftest::test_edit_distances): Move tests to this new function,
4583 and test some more pairs of strings. Update for above renaming.
4584 (selftest::get_old_cutoff): New function.
4585 (selftest::test_get_edit_distance_cutoff): New function.
4586 (selftest::assert_suggested_for): New function.
4587 (ASSERT_SUGGESTED_FOR): New macro.
4588 (selftest::assert_not_suggested_for): New function.
4589 (ASSERT_NOT_SUGGESTED_FOR): New macro.
4590 (selftest::test_suggestions): New function.
4591 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
4592 tests to selftest::test_edit_distances and call it. Add calls to
4593 selftest::test_get_edit_distance_cutoff and
4594 selftest::test_suggestions.
4595 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
4596 (best_match::consider): Replace hard-coded cutoff calculation with
4597 a call to...
4598 (best_match::get_cutoff): New declaration.
4599 (best_match::get_best_meaningful_candidate): Likewise.
4600
4601 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4602
4603 * builtins.c (fold_builtin_strlen): Remove TODO comment.
4604
4605 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4606
4607 revert:
4608 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
4609
4610 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
4611 terminated string literal.
4612
4613 2018-09-14 Martin Sebor <msebor@redhat.com>
4614
4615 * builtins.c (unterminated_array): Handle ARRAY_REF.
4616 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
4617 * builtins.h (unterminated_array): Declare extern.
4618 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
4619 arrays.
4620 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
4621 calls.
4622
4623 2018-09-14 Martin Sebor <msebor@redhat.com>
4624 Jeff Law <law@redhat.com>
4625
4626 * builtins.c (unterminated_array): New.
4627 (expand_builtin_strcpy): Adjust.
4628 (expand_builtin_strcpy_args): Detect unterminated arrays.
4629 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
4630 unterminated arrays.
4631 * gimple-fold.h (get_maxval_strlen): Add argument.
4632 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
4633
4634 * gimple-fold.c (get_range_strlen): Add argument.
4635 (get_maxval_strlen): Adjust.
4636 * gimple-fold.h (get_range_strlen): Add argument.
4637
4638 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
4639
4640 * config/i386/movdirintrin.h: Fix copyright year.
4641
4642 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
4643
4644 * reg-stack.c: Include regs.h.
4645 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
4646 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
4647 FIRST_STACK_REG, not DFmode.
4648 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
4649 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
4650 (change stack): Default register mode to the reg_raw_mode of
4651 FIRST_STACK_REG, not DFmode.
4652 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
4653 (*swapxf): Rename from swapxf.
4654
4655 2018-09-14 Carl Love <cel@us.ibm.com>
4656
4657 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
4658 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
4659
4660 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
4661
4662 PR target/87224
4663 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
4664 alternatives.
4665
4666 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
4667
4668 PR target/85628
4669 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
4670
4671 2018-09-14 Jason Merrill <jason@redhat.com>
4672
4673 Fix --enable-gather-detailed-mem-stats.
4674 * hash-table.c (hash_table_usage): Change from variable to function.
4675 * hash-table.h: Adjust.
4676 * Makefile.in: Add missing dependencies on hash-table.h.
4677
4678 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4679
4680 PR tree-optimization/87259
4681 PR lto/87283
4682 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
4683 execute_cse_reciprocals_1 has tried transforming.
4684
4685 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
4686
4687 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
4688 VR_VARYING for PLUS/MINUS_EXPR.
4689
4690 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
4691
4692 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
4693 formatting.
4694
4695 2018-09-14 Richard Biener <rguenther@suse.de>
4696
4697 PR middle-end/63155
4698 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
4699 bits for the merged partition.
4700
4701 2018-09-13 Martin Sebor <msebor@redhat.com>
4702 Bernd Edlinger <bernd.edlinger@hotmail.de>
4703
4704 * builtins.h (c_srlen): Add argument.
4705 * builtins.c (warn_string_no_nul): New function.
4706 (c_strlen): Add argument and use it. Update recursive calls.
4707 Pass DECL argument to string_constant to get info on non
4708 terminated strings. Update *NONSTR as needed.
4709 (fold_builtin_strlen): Add argument to calls to c_strlen.
4710 Warn for unterminated arrays.
4711 (warn_string_no_null): Add prototype.
4712 * expr.c (string_constant): Update arguments. Update recursive
4713 calls appropriately. Detect missing NUL terminator and outermost
4714 declaration its missing in.
4715 Improve checks for arrays with nonzero lower bound or elements
4716 that are not a single byte. Simplify offset computation.
4717 Simplify checks for non-NUL terminated strings.
4718 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
4719 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
4720
4721 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
4722
4723 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
4724 correctly.
4725 * fold-const.c (c_getstr): Fix function comment. Remove unused third
4726 argument. Fix range checks.
4727 * fold-const.h (c_getstr): Adjust protoype.
4728 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
4729 string is constant but contains no NUL byte.
4730
4731 * expr.c (string_constant): Adjust function comment.
4732 Remove bogus check for zero termination.
4733
4734 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
4735
4736 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
4737 (get_constant_size): Don't make STRING_CSTs larger than they are.
4738 (check_string_literal): New check function for STRING_CSTs.
4739 (output_constant): Use it.
4740
4741 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
4742
4743 PR target/86812
4744 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
4745
4746 2018-09-13 Richard Biener <rguenther@suse.de>
4747
4748 PR tree-optimization/87263
4749 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
4750 (struct unwind_state): Add max_rpo field.
4751 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
4752 Compute max_rpo, the max RPO number a block can be backwards reached
4753 from. Re-write non-iterating mode to a RPO ordered worklist approach,
4754 separating it from the iterating mode.
4755
4756 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4757
4758 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
4759 (rfs_decision): New scheduling decision.
4760
4761 2018-09-13 Richard Biener <rguenther@suse.de>
4762
4763 PR bootstrap/87134
4764 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
4765 (vn_nary_op_insert_pieces_predicated): Do not write useless
4766 valid_dominated_by_p entry outside of the allocated storage.
4767
4768 2018-09-13 Omar Sandoval <osandov@osandov.com>
4769 Tom de Vries <tdevries@suse.de>
4770
4771 PR debug/86985
4772 * dwarf2out.c (is_c): New function.
4773 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
4774
4775 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
4776
4777 PR target/85628
4778 * config/aarch64/aarch64.md (*aarch64_bfxil):
4779 Define.
4780 * config/aarch64/constraints.md (Ulc): Define.
4781 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
4782 Define.
4783 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
4784 New function.
4785
4786 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4787
4788 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
4789 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
4790 aarch64_layout_frame call.
4791 (aarch64_expand_epilogue): Likewise.
4792 (aarch64_initial_elimination_offset): Likewise.
4793 (aarch64_get_separate_components): Likewise.
4794 (aarch64_use_return_insn_p): Likewise.
4795 (aarch64_layout_frame): Remove unneeded check.
4796
4797 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4798
4799 * configure.ac: Only append
4800 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
4801 gcc_config_arguments if it was never reconfigured or last reconfigure
4802 was with different arguments.
4803 * configure: Regenerated.
4804
4805 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4806 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4807
4808 PR middle-end/87290
4809 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
4810 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
4811
4812 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4813
4814 PR tree-optimization/87287
4815 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
4816 X % C == 0 to X % (unsigned) C == 0 optimization to ...
4817 * match.pd (X % C == 0): ... here. New optimization.
4818
4819 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4820
4821 PR middle-end/82853
4822 * expr.h (maybe_optimize_mod_cmp): Declare.
4823 * expr.c (mod_inv): New function.
4824 (maybe_optimize_mod_cmp): New function.
4825 (do_store_flag): Use it.
4826 * cfgexpand.c (expand_gimple_cond): Likewise.
4827
4828 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
4829 Julian Brown <julian@codesourcery.com>
4830
4831 PR middle-end/86336
4832 * gimplify.c (gimplify_scan_omp_clauses): Set
4833 target_firstprivatize_array_bases in OpenACC parallel and kernels
4834 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
4835 OpenACC data regions.
4836
4837 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
4838
4839 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
4840 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
4841
4842 2018-09-12 Richard Biener <rguenther@suse.de>
4843
4844 PR tree-optimization/87280
4845 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
4846 edge but unreachable target.
4847 (do_rpo_vn): For conservatively handling a PHI only mark
4848 the backedge executable but not the block reachable.
4849
4850 2018-09-12 Richard Biener <rguenther@suse.de>
4851
4852 PR tree-optimization/87266
4853 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
4854 visited blocks.
4855
4856 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
4857
4858 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
4859 constants.
4860 ("trunc<BFP:mode><DFP_ALL:mode>2")
4861 ("trunc<DFP_ALL:mode><BFP:mode>2")
4862 ("extend<BFP:mode><DFP_ALL:mode>2")
4863 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
4864 according to the target operand type.
4865
4866 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4867 Andreas Krebbel <krebbel@linux.ibm.com>
4868
4869 PR tree-optimization/86844
4870 * gimple-ssa-store-merging.c
4871 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
4872 there are any overlapping stores in between them, make sure they are
4873 also coalesced or we give up completely.
4874
4875 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4876
4877 PR middle-end/87248
4878 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
4879 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
4880
4881 2018-09-12 Tom de Vries <tdevries@suse.de>
4882
4883 * common.opt (gdescribe-dies): Add option.
4884 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
4885 attribute for artifical and nameless decls.
4886 (dwarf2out_register_external_die): Add description attribute to
4887 external reference die.
4888 (add_desc_attribute): New functions.
4889 (gen_subprogram_die): Add description attribute to
4890 DW_TAG_call_site_parameter.
4891 * tree-pretty-print.c (print_generic_expr_to_str): New function.
4892 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
4893 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
4894 -gno-describe-dies.
4895 (@item -gdescribe-dies): Add.
4896
4897 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4898
4899 * tree-vrp.c (vrp_shift_undefined_p): Remove.
4900 (extract_range_from_binary_expr_1: Call
4901 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
4902 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
4903 depend on sign.
4904
4905 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4906
4907 * gimple-ssa-warn-alloca.c
4908 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
4909 field for ALLOCA_BOUND_*_LARGE.
4910
4911 2018-09-11 Nathan Sidwell <nathan@acm.org>
4912
4913 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
4914
4915 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4916
4917 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
4918 for clobbers. Remove obsolete comment.
4919
4920 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4921
4922 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
4923 mpxchk, mpxld and mpxst types.
4924 (define_attr length_immediate): Remove all processing of mpx types.
4925 (define_attr prefix_0f): Ditto.
4926 (define_attr memory): Ditto.
4927
4928 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4929
4930 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
4931 (log<mode>2): Change operand 1 predicate to general_operand.
4932 Extend operand 1 to XFmode and generate logxf3 insn.
4933 (log10<mode>2): Change operand 1 predicate to general_operand.
4934 Extend operand 1 to XFmode and generate log10xf3 insn.
4935 (log2<mode>2): Change operand 1 predicate to general_operand.
4936 Extend operand 1 to XFmode and generate log2xf3 insn.
4937 (fyl2xp1_extend<mode>xf3_i387): Remove.
4938 (log1p<mode>2): Change operand 1 predicate to general_operand.
4939 Extend operand 1 to XFmode and generate log1pxf3 insn.
4940 (fxtract_extend<mode>xf3_i387): Remove.
4941 (logb<mode>2): Change operand 1 predicate to general_operand.
4942 Extend operand 1 to XFmode and generate logbxf3 insn.
4943 (ilogb<mode>2): Change operand 1 predicate to general_operand.
4944 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
4945 (significand<mode>2): Change operand 1 predicate to general_operand.
4946 Extend operand 1 to XFmode and generate significandxf3 insn.
4947
4948 2018-09-11 Nathan Sidwell <nathan@acm.org>
4949
4950 * gcc.c (perror_with_name, pfatal_with_name): Delete.
4951 (load_specs): Use fatal_error.
4952 (DELETE_IF_ORDINARY, process_command): Use error.
4953 (execute, run_attempt): Use fatal_error.
4954
4955 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
4956
4957 * diagnostic-core.h (sorry_at): New prototype.
4958 * diagnostic.c (sorry_at): New function.
4959
4960 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
4961
4962 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
4963 by zero as VR_UNDEFINED.
4964
4965 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4966
4967 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
4968 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
4969 (<sincos>mode2): New expander.
4970 (sincos_extend<mode>xf3_i387): Remove insn pattern.
4971 (sincos -> sin, cos splitters): Remove splitter patterns.
4972 (sincos<mode>3): Change operand 2 predicate to general_operand.
4973 Extend operand 2 to XFmode and generate sincosxf3 insn.
4974 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
4975 Change operand 3 predicate to const1_operand.
4976 (fptan_extend<mode>xf4_i387): Remove insn pattern.
4977 (tanxf2): Update operands in the call to fptanxf4_i387.
4978 (tan<mode>2): Change operand 1 predicate to general_operand.
4979 Extend operand 1 to XFmode and generate tanxf3 insn.
4980 (atan2xf3): Rename from *fpatanxf3_i387.
4981 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
4982 (atan2xf3): Remove expander.
4983 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
4984 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
4985 (atan<mode>2): Change operand 1 predicate to general_operand.
4986 Extend operand 1 to XFmode and generate atanxf3 insn.
4987
4988 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4989
4990 * config/i386/i386.md (x87/SSE constant load splitter): Use
4991 memory_operand instead of nonimmediate_operand for input operand
4992 predicate.
4993
4994 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
4995
4996 * config/i386/i386.md (float partial SSE register stall splitter): Move
4997 splitter near its instruction pattern.
4998 (float_extend partial SSE register stall splitter): Ditto.
4999 (float_truncate partial SSE register stall splitter): Ditto.
5000
5001 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
5002
5003 PR target/86794
5004 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
5005 to speculation_safe_value_not_needed.
5006
5007 PR target/85666
5008 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
5009 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
5010 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
5011 leaf_function_p, instead use has_hard_reg_initial_val.
5012
5013 2018-09-09 Nathan Sidwell <nathan@acm.org>
5014
5015 * gcc.h (pfatal_with_name): Don't declare here.
5016 * gcc.c (pfatal_with_name): Make static.
5017
5018 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
5019
5020 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
5021 earlyclobber.
5022
5023 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
5024
5025 PR rtl-optimization/85458
5026 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
5027 priority hook to reduce the priority of EXPR.
5028
5029 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
5030
5031 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
5032 DImode for x87 on 32bit targets. Conditionally disable x87 modes
5033 with X87_ENABLE_FLOAT. Remove preparation code.
5034 (*float<SWI48:mode><MODEF:mode>2): Rename from
5035 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
5036 math using "enabled" attribute.
5037 (*floatdi<MODEF:mode>2_i387): Rename from
5038 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
5039 enable for 32bit targets only.
5040 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
5041 splitter.
5042 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
5043 as operand 1 predicate. Rewrite as define_insn_and_split.
5044 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
5045
5046 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
5047
5048 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
5049 to fallthru to FLOAT case.
5050
5051 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
5052
5053 PR target/86731
5054 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
5055 around folding of vec_sl to handle out of range shift values.
5056
5057 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
5058
5059 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
5060 Update callers to gen_fix_trunc<mode>_i387_fisttp
5061 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
5062 nonimmediate_operand.
5063 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
5064 and corresponding splitters.
5065 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
5066 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
5067 (fix_truncdi_i387_with_temp): Remove insn pattern
5068 and corresponding splitters.
5069 (fix_trunc<mode>_i387): Change operand 0 predicate to
5070 nonimmediate_operand.
5071 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
5072 and corresponding splitters.
5073 (*fistdi2_1): Remove.
5074 (fistdi2): Ditto.
5075 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
5076 (lrintxfdi2): Remove expander. Reimplement as define_insn.
5077 (*fist<mode>2_1): Remove.
5078 (fist<mode>2): Ditto.
5079 (fist<mode>2_with_temp): Remove insn pattern and corresponding
5080 splitters.
5081 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
5082 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
5083 (fistdi2_<rounding>): Change operand 0 predicate to
5084 nonimmediate_operand.
5085 (fistdi2_<rounding>_with_temp): Remove insn pattern
5086 and corresponding splitters.
5087 (fist<mode>2_<rounding>): Change operand 0 predicate to
5088 nonimmediate_operand.
5089 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
5090 and corresponding splitters.
5091
5092 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
5093
5094 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
5095
5096 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
5097 the init value.
5098
5099 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
5100
5101 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
5102 early gimple folding of vec_splat().
5103 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
5104 * gimple-fold.h: Add an extern define for tree_vec_extract().
5105
5106 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
5107
5108 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
5109 wrappers around TREE_TYPE comparisons.
5110
5111 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5112
5113 PR target/80080
5114 * config/s390/predicates.md: Add nonsym_memory_operand.
5115 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
5116 contains a SYMBOL_REF, load it into an intermediate pseudo.
5117 (s390_emit_compare_and_swap): Legitimize operand.
5118 * config/s390/s390.md: Use the new nonsym_memory_operand
5119 with UNSPECV_CAS patterns.
5120
5121 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5122
5123 PR target/80080
5124 * config/s390/s390-passes.def: New file.
5125 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
5126 declaration.
5127 (make_pass_s390_early_mach): Add declaration.
5128 * config/s390/s390.c (make_pass_s390_early_mach):
5129 (s390_option_override): Remove dynamic registration.
5130 * config/s390/t-s390: Add s390-passes.def.
5131
5132 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5133
5134 * config/s390/s390.c (s390_decompose_constant_pool_ref):
5135 Remove UNSPEC_LTREL_BASE check.
5136 (annotate_constant_pool_refs): Likewise.
5137 (find_constant_pool_ref): Likewise.
5138 (find_ltrel_base): Removed.
5139 (replace_ltrel_base): Removed.
5140 (s390_mainpool_finish): Remove replace_ltrel_base call.
5141 (s390_chunkify_start): Remove pending LTREL_BASE logic.
5142 (s390_chunkify_finish): Remove replace_ltrel_base call.
5143 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
5144
5145 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
5146
5147 PR target/86779
5148 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
5149 to speculation_safe_value_not_needed.
5150
5151 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
5152 Bernd Schmidt <bernds_cb1@t-online.de>
5153
5154 * config/nvptx/nvptx-opts.h: New file.
5155 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
5156 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
5157 (ASM_SPEC): Define.
5158 (TARGET_SM35): New macro.
5159 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
5160 correct predicate.
5161 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
5162 values.
5163 (misa=): New option.
5164 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
5165
5166 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
5167
5168 * config/i386/i386.md (truncdfsf2): Remove expander.
5169 (truncdfsf2_with_temp): Ditto.
5170 (truncxf<mode>2): Ditto.
5171 (*truncdfsf_fast_mixed): Remove insn pattern.
5172 (*truncdfsf_fast_i387): Ditto.
5173 (*truncdfsf_mixed): Ditto.
5174 (*truncdfsf_i387): Ditto.
5175 (*truncdfsf2_i387_1): Ditto.
5176 (*truncxfsf2_mixed): Ditto.
5177 (*truncxfdf2_mixed): Ditto.
5178 (*truncxf<mode>2_i387_noop): Ditto. Update callers
5179 to call gen_truncxf<mode>2 instead.
5180 (*truncxf<mode>2_i387): Remove.
5181 (reg->reg splitters): Remove splitter pattern.
5182 (reg->mem splitters): Ditto.
5183
5184 (truncdfsf2): New insn pattern.
5185 (truncxf<mode>2): Ditto.
5186
5187 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5188
5189 * tree-ssa-math-opts.c (is_mult_by): New function.
5190 (is_square_of): Use the above.
5191 (optimize_recip_sqrt): New function.
5192 (pass_cse_reciprocals::execute): Use the above.
5193
5194 2018-09-05 Richard Biener <rguenther@suse.de>
5195
5196 PR bootstrap/87134
5197 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
5198 to zero-init the emplaced vec.
5199
5200 2018-09-05 Martin Liska <mliska@suse.cz>
5201
5202 PR tree-optimization/87205
5203 * tree-switch-conversion.c (pass_lower_switch::execute):
5204 Group cases for switch statements.
5205
5206 2018-09-05 Richard Biener <rguenther@suse.de>
5207
5208 PR tree-optimization/87217
5209 * tree-ssa-sccvn.c (vuse_valueize): New.
5210 (vn_reference_lookup_pieces): Use it.
5211 (vn_reference_lookup): Likewise.
5212
5213 2018-09-05 Nathan Sidwell <nathan@acm.org>
5214
5215 PR c++/87137
5216 * stor-layout.c (place_field): Scan forwards to check last
5217 bitfield when ms_bitfield_placement is in effect.
5218
5219 2018-09-05 Richard Biener <rguenther@suse.de>
5220
5221 PR bootstrap/87225
5222 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
5223 return.
5224
5225 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
5226 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
5227
5228 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
5229 * config.gcc (extra_objs): Build it.
5230 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
5231 Likewise.
5232 * config/aarch64/aarch64-passes.def
5233 (pass_tag_collision_avoidance): New pass.
5234 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
5235 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
5236 (aarch64_classify_address): Remove static qualifier.
5237 (aarch64_address_info, aarch64_address_type): Move to...
5238 * config/aarch64/aarch64-protos.h: ... here.
5239 (make_pass_tag_collision_avoidance): New function.
5240 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
5241 New tuning flag.
5242
5243 2018-09-05 Martin Liska <mliska@suse.cz>
5244
5245 * doc/gcov.texi: Update documentation of humar
5246 readable mode.
5247 * gcov.c (format_count): Print one decimal place, it provides
5248 more fine number of situations like '1G' vs. '1.4G'.
5249
5250 2018-09-05 Martin Liska <mliska@suse.cz>
5251
5252 PR target/87164
5253 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
5254 * optc-gen.awk: Allow 'Var' for Deprecated options in order
5255 to generate a MASK value.
5256
5257 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
5258
5259 PR debug/86593
5260 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
5261 if frame pointer isn't used.
5262 (compute_frame_pointer_to_fb_displacement): Likewise.
5263
5264 2018-09-04 Jakub Jelinek <jakub@redhat.com>
5265
5266 PR target/87198
5267 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
5268 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
5269 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
5270 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
5271 and OPTION_MASK_ISA_XSAVEC_UNSET.
5272
5273 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
5274
5275 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
5276 XOR operations in NAND case.
5277
5278 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5279
5280 * wide-int-range.cc (wide_int_range_convert): New.
5281 * wide-int-range.h (wide_int_range_convert): New.
5282 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
5283 code into wide_int_range_convert.
5284 (extract_range_into_wide_ints): Do not munge anti range constants
5285 into the entire domain. Just return the range back.
5286
5287 2018-09-04 Martin Liska <mliska@suse.cz>
5288
5289 * genmatch.c (output_line_directive): Add new argument
5290 fnargs.
5291 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
5292
5293 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5294
5295 * doc/invoke.texi (Option Summary): Add whitespace.
5296
5297 * doc/invoke.texi (Option Summary): Add -Waligned-new.
5298
5299 2018-09-04 Richard Biener <rguenther@suse.de>
5300
5301 PR tree-optimization/87211
5302 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
5303 backedge value we're supposed to treat as VARYING also number
5304 the PHI to VARYING in case it got a different value-number already.
5305
5306 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5307
5308 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
5309 (extract_range_from_binary_expr_1): Do not call
5310 vrp_can_optimize_bit_op.
5311 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
5312 static.
5313 (wide_int_range_get_mask_and_bounds): New.
5314 (wide_int_range_optimize_bit_op): New.
5315 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
5316 (wide_int_range_bit_and): Same.
5317 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
5318 (wide_int_range_optimize_bit_op): New.
5319 (wide_int_range_get_mask_and_bounds): New.
5320
5321 2018-09-04 Richard Biener <rguenther@suse.de>
5322
5323 PR tree-optimization/87176
5324 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
5325 variable. When value-numbering a virtual PHI node make sure
5326 to not value-number to the backedge value.
5327
5328 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5329
5330 * doc/extend.texi (Long Long, Hex Floats): Document support for
5331 long long and hex floats in more recent versions of ISO C++.
5332
5333 2018-09-03 Richard Biener <rguenther@suse.de>
5334
5335 PR tree-optimization/87177
5336 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
5337 cleanup.
5338
5339 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5340
5341 * bb-reorder.c (edge_order): Convert to C-qsort-style
5342 tri-state comparator.
5343 (reorder_basic_blocks_simple): Change std::stable_sort to
5344 gcc_stablesort.
5345
5346 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5347
5348 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
5349 tri-state comparator.
5350 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
5351
5352 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5353
5354 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
5355 (mergesort): ... here as maximum count for using netsort.
5356 (gcc_qsort): Set nlim to 3 if stable sort is requested.
5357 (gcc_stablesort): New.
5358 * system.h (gcc_stablesort): Declare.
5359
5360 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5361
5362 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
5363 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
5364 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
5365
5366 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
5367
5368 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
5369 lxsdx and stxsdx alternatives.
5370 (*mov<mode>_hardfloat64): Ditto.
5371 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
5372
5373 2018-09-03 Richard Biener <rguenther@suse.de>
5374
5375 PR tree-optimization/87200
5376 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
5377 simplify result.
5378
5379 2018-09-03 Martin Liska <mliska@suse.cz>
5380
5381 PR tree-optimization/87201
5382 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5383 Fix parenthesis in an expression.
5384
5385 2018-09-03 Richard Biener <rguenther@suse.de>
5386
5387 PR tree-optimization/87197
5388 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
5389 visited. CSE the VN_INFO hashtable lookup.
5390
5391 PR tree-optimization/87169
5392 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
5393 iterating make sure there's no extra backedges from irreducible
5394 regions feeding the header. Mark the destination block
5395 executable.
5396
5397 2018-09-03 Martin Liska <mliska@suse.cz>
5398
5399 PR driver/83193
5400 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
5401 * common/common-targhooks.c (default_get_valid_option_values):
5402 New function.
5403 * common/common-targhooks.h (default_get_valid_option_values):
5404 Likewise.
5405 * common/config/i386/i386-common.c: Move processor_target_table
5406 from i386.c.
5407 (ix86_get_valid_option_values): New function.
5408 (TARGET_GET_VALID_OPTION_VALUES): New macro.
5409 * config/i386/i386.c (struct ptt): Move to i386-common.c.
5410 (PTA_*): Move all defined masks into i386-common.c.
5411 (ix86_function_specific_restore): Use new processor_cost_table.
5412 * config/i386/i386.h (struct ptt): Moved from i386.c.
5413 (struct pta): Likewise.
5414 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
5415 * doc/tm.texi.in: Likewise.
5416 * opt-suggestions.c (option_proposer::suggest_option):
5417 Pass prefix to build_option_suggestions.
5418 (option_proposer::get_completions): Likewise.
5419 (option_proposer::build_option_suggestions): Use the new target
5420 hook.
5421 * opts.c (struct option_help_tuple): New struct.
5422 (print_filtered_help): Use the new target hook.
5423
5424 2018-09-03 Martin Liska <mliska@suse.cz>
5425
5426 PR middle-end/59521
5427 * predict.c (set_even_probabilities): Add likely_edges
5428 argument and handle cases where we have precisely one
5429 likely edge.
5430 (combine_predictions_for_bb): Catch also likely_edges.
5431 (tree_predict_by_opcode): Handle gswitch statements.
5432 * tree-cfg.h (find_case_label_for_value): New declaration.
5433 (find_taken_edge_switch_expr): Likewise.
5434 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5435 Find pivot in decision tree based on probabily, not by number of
5436 nodes.
5437
5438 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
5439
5440 * doc/standards.texi (Standards): Update Objective-C reference.
5441
5442 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5443
5444 * doc/install.texi (Prerequisites): Update link for MPC.
5445
5446 2018-09-01 Michael Matz <matz@suse.de>
5447
5448 PR tree-optimization/87074
5449 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
5450 PHIs for outer-loop uses.
5451
5452 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5453
5454 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
5455 * doc/invoke.texi (C Dialect Options): Ditto.
5456
5457 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5458
5459 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
5460
5461 2018-08-31 Richard Biener <rguenther@suse.de>
5462
5463 PR tree-optimization/87168
5464 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
5465 (rpo_elim::eliminate_avail): When OP was not visited it must
5466 be available.
5467
5468 2018-08-31 David Malcolm <dmalcolm@redhat.com>
5469
5470 * tree-vrp.c (copy_value_range): Convert param "from" from
5471 "value_range *" to "const value_range *".
5472 (range_is_null): Likewise for param "vr".
5473 (range_int_cst_p): Likewise.
5474 (range_int_cst_singleton_p): Likewise.
5475 (symbolic_range_p): Likewise.
5476 (value_ranges_intersect_p): Likewise for both params.
5477 (value_range_nonnegative_p): Likewise for param "vr".
5478 (value_range_constant_singleton): Likewise.
5479 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
5480 (extract_range_into_wide_ints): Likewise for param "vr".
5481 (extract_range_from_multiplicative_op): Likewise for params "vr0"
5482 and "vr1".
5483 (vrp_can_optimize_bit_op): Likewise.
5484 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
5485 "vr1_".
5486 (extract_range_from_unary_expr): Likewise.
5487 (debug_value_range): Likewise for param "vr".
5488 (value_range::dump): Add "const" qualifier.
5489 (vrp_prop::check_array_ref): Convert local "vr" from
5490 "value_range *" to "const value_range *".
5491 (vrp_prop::check_mem_ref): Likewise.
5492 (vrp_prop::visit_stmt): Likewise for local "old_vr".
5493 (vrp_intersect_ranges_1): Likewise for param "vr_1".
5494 (vrp_intersect_ranges): Likewise.
5495 (simplify_stmt_for_jump_threading): Likewise for local "vr".
5496 (vrp_prop::vrp_finalize): Likewise.
5497 * tree-vrp.h (value_range::dump): Add "const" qualifier.
5498 (vrp_intersect_ranges): Add "const" qualifier to params as above.
5499 (extract_range_from_unary_expr): Likewise.
5500 (value_range_constant_singleton): Likewise.
5501 (symbolic_range_p): Likewise.
5502 (copy_value_range): Likewise.
5503 (extract_range_from_binary_expr_1): Likewise.
5504 (range_int_cst_p): Likewise.
5505 (vrp_set_zero_nonzero_bits): Likewise.
5506 (range_int_cst_singleton_p): Likewise.
5507
5508 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
5509
5510 * config/aarch64/arm_neon.h (vabsd_s64): New.
5511 (vnegd_s64): Likewise.
5512
5513 2018-08-31 Martin Jambor <mjambor@suse.cz>
5514
5515 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
5516
5517 2018-08-31 Martin Liska <mliska@suse.cz>
5518
5519 * ipa-icf.c (sem_item::add_type): Use
5520 sem_item::m_type_hash_cache.
5521 * ipa-icf.h: Move the cache from sem_item_optimizer
5522 to sem_item.
5523
5524 2018-08-31 Nathan Sidwell <nathan@acm.org>
5525
5526 * doc/extend.texi (Backwards Compatibility): Remove implicit
5527 extern C leeway of () being (...).
5528
5529 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5530
5531 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
5532
5533 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
5534
5535 PR target/86684
5536 PR target/87149
5537 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
5538
5539 2018-08-31 Jakub Jelinek <jakub@redhat.com>
5540
5541 PR middle-end/87138
5542 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
5543 gen_int_mode. Formatting fixes.
5544
5545 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
5546
5547 * target.def (custom_function_descriptors): Improve documentation.
5548 * doc/tm.texi.in (Trampolines): Expand discussion of function
5549 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
5550 beginning of the section.
5551 * doc/tm.texi: Regenerated.
5552
5553 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
5554
5555 * cfg.h (class auto_edge_flag): Spell out the template-id of the
5556 base class in the initializer list. This is a workaround for
5557 building with older GCC.
5558 (class auto_bb_flag): Likewise.
5559
5560 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
5561
5562 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
5563 (altivec_vcmpequ<VI_char>_p): Remove star.
5564 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
5565 vector load modes.
5566 (expand_strncmp_vec_sequence): New function.
5567 (emit_final_str_compare_vec): New function.
5568 (expand_strn_compare): Add support for vector strncmp.
5569 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
5570 length specification to bytes.
5571 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
5572 (vcmpnezb_p): New pattern.
5573 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
5574 for option -mstring-compare-inline-limit.
5575
5576 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
5577
5578 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
5579 (PTA_SKYLAKE): Add PTA_AES.
5580 (PTA_GOLDMONT): Likewise.
5581
5582 2018-08-29 Jan Hubicka <jh@suse.cz>
5583
5584 PR lto/86517
5585 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
5586 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
5587
5588 2018-08-29 Jan Hubicka <jh@suse.cz>
5589
5590 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
5591 TYPE_STUB_DECL.
5592 (hash_tree): Do not visit TYPE_STUB_DECL.
5593 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
5594 stream TYPE_STUB_DECL.
5595 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
5596 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
5597 after free_lang_data.
5598 (type_in_anonymous_namespace_p): Likewise.
5599
5600 2018-08-29 Jan Hubicka <jh@suse.cz>
5601
5602 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5603 comment that it has to be even number.
5604 (class sreal): Change m_sig type to int32_t.
5605 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5606 int64_t for temporary calculations.
5607 (sreal_verify_basics): Drop one bit from minimum and maximum.
5608
5609 2018-08-30 Richard Biener <rguenther@suse.de>
5610
5611 PR tree-optimization/87147
5612 * tree-ssa-sccvn.c (SSA_VISITED): New function.
5613 (visit_phi): When the degenerate result is from the backedge and
5614 we didn't visit its definition yet drop to VARYING.
5615 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
5616
5617 2018-08-29 Jan Hubicka <jh@suse.cz>
5618
5619 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
5620 DECL_VINDEX.
5621 (hash_tree): Likewise.
5622
5623 2018-08-29 Jan Hubicka <jh@suse.cz>
5624
5625 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
5626 and TYPE_NEXT_REF_TO.
5627
5628 2018-08-29 Jan Hubicka <jh@suse.cz>
5629
5630 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5631 comment that it has to be even number.
5632 (class sreal): Change m_sig type to int32_t.
5633 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5634 int64_t for temporary calculations.
5635 (sreal_verify_basics): Drop one bit from minimum and maximum.
5636
5637 2018-08-30 Tamar Christina <tamar.christina@arm.com>
5638
5639 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
5640
5641 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
5642
5643 PR middle-end/86995
5644 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
5645 if to_add is negative.
5646
5647 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
5648
5649 PR middle-end/87053
5650 * builtins.c (c_strlen): Improve range checks.
5651
5652 2018-08-29 Martin Sebor <msebor@redhat.com>
5653 Jeff Law <law@redhat.com>
5654
5655 PR tree-optimization/86714
5656 PR tree-optimization/86711
5657 * builtins.c (c_strlen): Add arguments to call to string_constant.
5658 * expr.c (string_constant): Add argument. Detect missing nul
5659 terminator and outermost declaration it's missing in.
5660 * expr.h (string_constant): Add argument.
5661 * fold-const.c (read_from_constant_string): Add arguments to call to
5662 string_constant.
5663 (c_getstr): Likewise.
5664 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5665 to string_constant.
5666 * tree-ssa-strlen.c (get_stridx): Likewise.
5667
5668 2018-08-29 Jan Hubicka <jh@suse.cz>
5669
5670 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
5671 Do not stream DECL_VINDEX.
5672 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
5673 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
5674 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
5675
5676 2018-08-29 Richard Biener <rguenther@suse.de>
5677
5678 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
5679 virtual operands that are not default defs to honor region
5680 boundaries.
5681 (rpo_vn_valueize): Remove ineffective code here.
5682
5683 2018-08-29 Richard Biener <rguenther@suse.de>
5684
5685 PR tree-optimization/87132
5686 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
5687 when skipping defs reachable over backedges.
5688
5689 2018-08-29 Richard Biener <rguenther@suse.de>
5690
5691 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
5692 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
5693 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
5694 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
5695 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
5696 (vn_reference_lookup_3): Remove use of const_parms.
5697 (free_rpo_vn): Do not free const_parms.
5698 (do_rpo_vn): Do not call init_const_parms.
5699 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
5700 SSA_NAME_POINTS_TO_READONLY_MEMORY.
5701 (call_may_clobber_ref_p_1): Likewise.
5702
5703 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
5704
5705 PR other/86726
5706 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
5707 (-O): Ditto.
5708 (-ftree-scev-cprop): Document.
5709
5710 2018-08-29 Jan Hubicka <jh@suse.cz>
5711
5712 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
5713 parameters.
5714 (sreal constructor): Update.
5715 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
5716 sreal:operator/): Update.
5717
5718 2018-08-29 Martin Liska <mliska@suse.cz>
5719
5720 * tree-switch-conversion.c (switch_conversion::expand):
5721 Strenghten assumption about gswitch statements.
5722
5723 2018-08-29 Richard Biener <rguenther@suse.de>
5724
5725 PR tree-optimization/87117
5726 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
5727 re-value-number released SSA VDEFs.
5728
5729 2018-08-29 Richard Biener <rguenther@suse.de>
5730
5731 PR tree-optimization/87126
5732 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
5733
5734 2018-08-28 Jim Wilson <jimw@sifive.com>
5735
5736 * config/riscv/pic.md: Rewrite.
5737 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
5738 invalid address.
5739 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
5740 (SOFTF, default_load, softload, softstore): New.
5741
5742 2018-08-28 Jeff Law <law@redhat.com>
5743
5744 * fold-const.c (fold_binary_loc): Remove recently added assert.
5745
5746 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
5747
5748 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
5749 to OP parmeter of generated function.
5750
5751 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
5752
5753 PR tree-optimization/87009
5754 * match.pd: Add boolean optimizations.
5755
5756 2018-08-28 Martin Sebor <msebor@redhat.com>
5757
5758 PR middle-end/86631
5759 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
5760 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
5761 (pass_walloca::gate): Use it.
5762 (alloca_call_type): Same.
5763 (pass_walloca::execute): Same.
5764 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
5765
5766 2018-08-28 David Malcolm <dmalcolm@redhat.com>
5767
5768 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
5769 GCC_VERSION for usage of "__gcc_dump_printf__" format from
5770 >= 3005 to >= 9000.
5771
5772 2018-08-28 Richard Biener <rguenther@suse.de>
5773
5774 PR tree-optimization/87124
5775 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
5776 constants before looking up avail.
5777
5778 2018-08-28 Jakub Jelinek <jakub@redhat.com>
5779
5780 PR middle-end/87099
5781 * calls.c (maybe_warn_nonstring_arg): Punt early if
5782 warn_stringop_overflow is zero. Don't call get_range_strlen
5783 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
5784 Swap comparison operands to have constants on rhs. Only use
5785 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
5786 increment lenrng[0].
5787
5788 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
5789
5790 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
5791 use of tree_to_shwi. Remove duplicated test for the size being
5792 a whole number of bytes.
5793
5794 2018-08-28 Richard Biener <rguenther@suse.de>
5795
5796 PR tree-optimization/87117
5797 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
5798 Handle removed stmt without LHS (GIMPLE_NOP).
5799
5800 2018-08-28 Richard Biener <rguenther@suse.de>
5801
5802 PR tree-optimization/87117
5803 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
5804 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
5805
5806 2018-08-28 Richard Biener <rguenther@suse.de>
5807
5808 PR tree-optimization/87117
5809 * tree-ssa-pre.c (compute_avail): Do not make expressions
5810 with predicated values available.
5811 (get_expr_value_id): Assert we do not run into predicated value
5812 expressions.
5813
5814 2018-08-28 Richard Biener <rguenther@suse.de>
5815
5816 PR tree-optimization/87117
5817 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
5818 get virtual operands.
5819 (get_expr_operands): Handle STRING_CST like other decls.
5820
5821 2018-08-28 Martin Liska <mliska@suse.cz>
5822
5823 * tree.h: Update documentation of fndecl_built_in_p
5824 functions.
5825
5826
5827 2018-08-27 Jeff Law <law@redhat.com>
5828 PR tree-optimization/87110
5829 * tree-ssa-dse.c (compute_trims): Handle non-constant
5830 TYPE_SIZE_UNIT.
5831
5832 2018-08-27 Martin Sebor <msebor@redhat.com>
5833
5834 PR tree-optimization/86914
5835 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
5836
5837 2018-08-27 Martin Sebor <msebor@redhat.com>
5838
5839 PR tree-optimization/87112
5840 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
5841 the type of the bound argument.
5842
5843 2018-08-27 Jeff Law <law@redhat.com>
5844
5845 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
5846 type does not have a TYPE_SIZE_UNIT.
5847
5848 2018-08-27 Steve Ellcey <sellcey@cavium.com>
5849
5850 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
5851 with include of backend.h.
5852
5853 2018-08-27 Richard Biener <rguenther@suse.de>
5854
5855 PR tree-optimization/86927
5856 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
5857 use const cond reduction code.
5858
5859 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
5860
5861 PR tree-optimization/85758
5862 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
5863
5864 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5865
5866 PR c++/87091
5867 * diagnostic-show-locus.c (class layout_range): Update for
5868 conversion of show_caret_p to a tri-state.
5869 (layout_range::layout_range): Likewise.
5870 (make_range): Likewise.
5871 (layout::maybe_add_location_range): Likewise.
5872 (layout::should_print_annotation_line_p): Don't show annotation
5873 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
5874 (layout::get_state_at_point): Update for conversion of
5875 show_caret_p to a tri-state. Bail out early for
5876 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
5877 underlining or source colorization.
5878 (gcc_rich_location::add_location_if_nearby): Update for conversion
5879 of show_caret_p to a tri-state.
5880 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
5881 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
5882 Likewise.
5883 (selftest::test_one_liner_labels): Likewise.
5884 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
5885 conversion of show_caret_p to a tri-state.
5886 * pretty-print.c (text_info::set_location): Likewise.
5887 * pretty-print.h (text_info::set_location): Likewise.
5888 * substring-locations.c (format_warning_n_va): Likewise.
5889 * tree-diagnostic.c (default_tree_printer): Likewise.
5890 * tree-pretty-print.c (newline_and_indent): Likewise.
5891
5892 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5893
5894 PR c++/87091
5895 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
5896 line above for line-insertion fix-it hints.
5897 (selftest::test_fixit_insert_containing_newline): Update the
5898 expected results, and add a test with line-numbering enabled.
5899
5900 2018-08-27 Martin Liska <mliska@suse.cz>
5901
5902 PR sanitizer/86962
5903 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
5904 params with DECL_HAS_VALUE_EXPR_P.
5905
5906 2018-08-27 Martin Liska <mliska@suse.cz>
5907
5908 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
5909 selected expansion strategy.
5910
5911 2018-08-27 Martin Liska <mliska@suse.cz>
5912
5913 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
5914 * builtins.c (is_builtin_fn): Likewise.
5915 * attribs.c (diag_attr_exclusions): Use new function
5916 fndecl_built_in_p and remove check for FUNCTION_DECL if
5917 possible.
5918 (builtin_mathfn_code): Likewise.
5919 (fold_builtin_expect): Likewise.
5920 (fold_call_expr): Likewise.
5921 (fold_builtin_call_array): Likewise.
5922 (fold_call_stmt): Likewise.
5923 (set_builtin_user_assembler_name): Likewise.
5924 (is_simple_builtin): Likewise.
5925 * calls.c (gimple_alloca_call_p): Likewise.
5926 (maybe_warn_nonstring_arg): Likewise.
5927 * cfgexpand.c (expand_call_stmt): Likewise.
5928 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
5929 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
5930 (cgraph_node::verify_node): Likewise.
5931 * cgraphclones.c (build_function_decl_skip_args): Likewise.
5932 (cgraph_node::create_clone): Likewise.
5933 * config/arm/arm.c (arm_insert_attributes): Likewise.
5934 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
5935 * dse.c (scan_insn): Likewise.
5936 * expr.c (expand_expr_real_1): Likewise.
5937 * fold-const.c (operand_equal_p): Likewise.
5938 (fold_binary_loc): Likewise.
5939 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
5940 * gimple-low.c (lower_stmt): Likewise.
5941 * gimple-pretty-print.c (dump_gimple_call): Likewise.
5942 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
5943 Likewise.
5944 * gimple.c (gimple_build_call_from_tree): Likewise.
5945 (gimple_call_builtin_p): Likewise.
5946 (gimple_call_combined_fn): Likewise.
5947 * gimplify.c (gimplify_call_expr): Likewise.
5948 (gimple_boolify): Likewise.
5949 (gimplify_modify_expr): Likewise.
5950 (gimplify_addr_expr): Likewise.
5951 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
5952 * ipa-cp.c (determine_versionability): Likewise.
5953 * ipa-fnsummary.c (compute_fn_summary): Likewise.
5954 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
5955 * ipa-split.c (visit_bb): Likewise.
5956 (split_function): Likewise.
5957 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
5958 * lto-cgraph.c (input_node): Likewise.
5959 * lto-streamer-out.c (write_symbol): Likewise.
5960 * omp-low.c (setjmp_or_longjmp_p): Likewise.
5961 (lower_omp_1): Likewise.
5962 * predict.c (strip_predict_hints): Likewise.
5963 * print-tree.c (print_node): Likewise.
5964 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
5965 * trans-mem.c (is_tm_irrevocable): Likewise.
5966 (is_tm_load): Likewise.
5967 (is_tm_simple_load): Likewise.
5968 (is_tm_store): Likewise.
5969 (is_tm_simple_store): Likewise.
5970 (is_tm_abort): Likewise.
5971 (tm_region_init_1): Likewise.
5972 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
5973 * tree-cfg.c (verify_gimple_call): Likewise.
5974 (move_stmt_r): Likewise.
5975 (stmt_can_terminate_bb_p): Likewise.
5976 * tree-eh.c (lower_eh_constructs_2): Likewise.
5977 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
5978 * tree-inline.c (remap_gimple_stmt): Likewise.
5979 (copy_bb): Likewise.
5980 (estimate_num_insns): Likewise.
5981 (fold_marked_statements): Likewise.
5982 * tree-sra.c (scan_function): Likewise.
5983 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
5984 (optimize_stack_restore): Likewise.
5985 (pass_fold_builtins::execute): Likewise.
5986 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
5987 (mark_all_reaching_defs_necessary_1): Likewise.
5988 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
5989 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5990 (pass_forwprop::execute): Likewise.
5991 * tree-ssa-loop-im.c (stmt_cost): Likewise.
5992 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
5993 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
5994 * tree-ssa-strlen.c (get_string_length): Likewise.
5995 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
5996 (find_func_aliases_for_call): Likewise.
5997 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
5998 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
5999 * tree-tailcall.c (find_tail_calls): Likewise.
6000 * tree.c (need_assembler_name_p): Likewise.
6001 (free_lang_data_in_decl): Likewise.
6002 (get_call_combined_fn): Likewise.
6003 * ubsan.c (is_ubsan_builtin_p): Likewise.
6004 * varasm.c (incorporeal_function_p): Likewise.
6005 * tree.h (DECL_BUILT_IN): Remove and replace with
6006 fndecl_built_in_p.
6007 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
6008 (fndecl_built_in_p): New.
6009
6010 2018-08-27 Martin Liska <mliska@suse.cz>
6011
6012 PR tree-optimization/86847
6013 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
6014 Dump also subtree probability.
6015 (switch_decision_tree::do_jump_if_equal): New function.
6016 (switch_decision_tree::emit_case_nodes): Handle special
6017 situations in balanced tree that can be emitted much simpler.
6018 Fix calculation of probabilities that happen in tree expansion.
6019 * tree-switch-conversion.h (struct cluster): Add
6020 is_single_value_p.
6021 (struct simple_cluster): Likewise.
6022 (struct case_tree_node): Add new function has_child.
6023 (do_jump_if_equal): New.
6024
6025 2018-08-27 Martin Liska <mliska@suse.cz>
6026
6027 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
6028 Add new argument to bit_test_cluster constructor.
6029 (bit_test_cluster::emit): Set bits really number of values
6030 handlel by a test.
6031 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
6032 probability argument.
6033 * tree-switch-conversion.h (struct bit_test_cluster):
6034 Add m_handles_entire_switch.
6035
6036 2018-08-27 Martin Liska <mliska@suse.cz>
6037
6038 PR tree-optimization/86702
6039 * tree-switch-conversion.c (jump_table_cluster::emit):
6040 Make probabilities even for values in jump table
6041 according to number of cases handled.
6042 (switch_decision_tree::compute_cases_per_edge): Pass
6043 argument to reset_out_edges_aux function.
6044 (switch_decision_tree::analyze_switch_statement): Likewise.
6045 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
6046 Make it static.
6047
6048 2018-08-27 Martin Liska <mliska@suse.cz>
6049
6050 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
6051 cfun argument explicitly.
6052 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
6053 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
6054 function gimple_switch_default_bb.
6055 (convert_switch_statements):
6056 (expand_builtins):
6057 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
6058 * stmt.c (label_to_block_fn): Use label_to_block and pass
6059 cfun argument explicitly and use gimple_switch_label_bb.
6060 (expand_case): Likewise.
6061 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
6062 cfun argument explicitly. Likewise.
6063 (make_edges_bb): Likewise.
6064 (make_cond_expr_edges): Likewise.
6065 (get_cases_for_edge): Likewise.
6066 (make_gimple_switch_edges): Likewise.
6067 (label_to_block_fn): Likewise.
6068 (label_to_block): Likewise.
6069 (make_goto_expr_edges): Likewise.
6070 (make_gimple_asm_edges): Likewise.
6071 (main_block_label): Likewise.
6072 (group_case_labels_stmt): Likewise.
6073 (find_taken_edge_computed_goto): Likewise.
6074 (find_taken_edge_switch_expr): Likewise.
6075 (gimple_verify_flow_info): Likewise.
6076 (gimple_redirect_edge_and_branch): Likewise.
6077 (gimple_switch_label_bb): New function.
6078 (gimple_switch_default_bb): Likewise.
6079 (gimple_switch_edge): Likewise.
6080 (gimple_switch_default_edge): Likewise.
6081 * tree-cfg.h (label_to_block_fn): Remove and replace ...
6082 (label_to_block): ... with this.
6083 (gimple_switch_label_bb): New.
6084 (gimple_switch_default_bb): Likewise.
6085 (gimple_switch_edge): Likewise.
6086 (gimple_switch_default_edge): Likewise.
6087 * tree-cfgcleanup.c (convert_single_case_switch): Use
6088 new gimple functions and pass new argument to label_to_block.
6089 (cleanup_control_flow_bb):
6090 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
6091 cfun argument explicitly.
6092 (make_eh_edges): Likewise.
6093 (redirect_eh_dispatch_edge): Likewise.
6094 (lower_resx): Likewise.
6095 (lower_eh_dispatch): Likewise.
6096 (maybe_remove_unreachable_handlers): Likewise.
6097 (unsplit_eh): Likewise.
6098 (cleanup_empty_eh): Likewise.
6099 (verify_eh_edges): Likewise.
6100 (verify_eh_dispatch_edge): Likewise.
6101 * tree-ssa-dom.c (record_edge_info): Likewise.
6102 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
6103 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
6104 (thread_through_normal_block): Likewise.
6105 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
6106 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
6107 * tree-switch-conversion.c (switch_conversion::collect): Use new
6108 gimple functions.
6109 (switch_conversion::check_final_bb): Likewise.
6110 (switch_conversion::gather_default_values): Pass new argument
6111 to label_to_block.
6112 (switch_conversion::build_constructors): Likewise.
6113 (switch_decision_tree::compute_cases_per_edge): Use new
6114 gimple_switch_edge function.
6115 (switch_decision_tree::analyze_switch_statement): Pass new argument
6116 to label_to_block.
6117 (switch_decision_tree::try_switch_expansion): Use
6118 gimple_switch_default_edge.
6119 * tree-vrp.c (find_switch_asserts): Pass new argument
6120 to label_to_block.
6121 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
6122 (vr_values::simplify_switch_using_ranges): Likewise.
6123
6124 2018-08-27 Richard Biener <rguenther@suse.de>
6125
6126 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
6127 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
6128
6129 * tree-ssa-sccvn.h (struct vn_pval): New structure.
6130 (struct vn_nary_op_s): Add unwind_to member. Add
6131 predicated_values flag and put result into a union together
6132 with a linked list of vn_pval.
6133 (struct vn_ssa_aux): Add name member to make maintaining
6134 a map of SSA name to vn_ssa_aux possible. Remove no longer
6135 needed info, dfsnum, low, visited, on_sccstack, use_processed
6136 and range_info_anti_range_p members.
6137 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
6138 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
6139 New functions.
6140 (vn_valueize): New global.
6141 (vn_context_bb): Likewise.
6142 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
6143 VN_INFO_PTR_INFO): Remove.
6144 * tree-ssa-sccvn.c: ... (rewrite)
6145 (pass_fre::execute): For -O2+ initialize loops and run
6146 RPO VN in optimistic mode (iterating). For -O1 and -Og
6147 run RPO VN in non-optimistic mode.
6148 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
6149 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
6150 * doc/invoke.texi (sccvn-max-scc-size): Remove.
6151 (rpo-vn-max-loop-depth): Document.
6152 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
6153 when valuezing the VUSE signals we walked out of the region.
6154 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
6155 (phi_translate): Set VN context block to use for availability
6156 lookup.
6157 (compute_avail): Likewise.
6158 (pre_valueize): New function.
6159 (pass_pre::execute): Adjust to the RPO VN API.
6160
6161 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
6162 (propagate_constants_for_unrolling): Remove.
6163 (tree_unroll_loops_completely): Perform value-numbering
6164 on the unrolled bodies loop parent.
6165
6166 2018-08-27 Richard Biener <rguenther@suse.de>
6167
6168 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
6169 for partial antic compute.
6170
6171 2018-08-27 Jakub Jelinek <jakub@redhat.com>
6172
6173 PR rtl-optimization/87065
6174 * combine.c (simplify_if_then_else): Formatting fix.
6175 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
6176 check.
6177 (known_cond): Don't return const_true_rtx for vector modes. Use
6178 CONST0_RTX instead of const0_rtx. Formatting fixes.
6179
6180 2018-08-27 Martin Liska <mliska@suse.cz>
6181
6182 PR gcov-profile/87069
6183 * gcov.c (process_file): Record files already processed
6184 and warn about a file being processed multiple times.
6185
6186 2018-08-27 Martin Liska <mliska@suse.cz>
6187
6188 PR driver/83193
6189 * config/aarch64/aarch64.c (aarch64_override_options_internal):
6190 Set default values for x_aarch64_*_string strings.
6191 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
6192 prefix. For -mabi do not print '=ABI' in help and use
6193 <option_value> format for -msve-vector-bits and -moverride
6194 options.
6195
6196 2018-08-26 Jeff Law <law@redhat.com>
6197
6198 * config/mips/frame-header-opt.c: Include "backend.h" rather than
6199 "cfg.h"
6200
6201 2018-08-26 Marek Polacek <polacek@redhat.com>
6202
6203 PR c++/87029, Implement -Wredundant-move.
6204 * doc/invoke.texi: Document -Wredundant-move.
6205
6206 2018-08-25 Martin Sebor <msebor@redhat.com>
6207
6208 PR tree-optimization/87059
6209 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
6210 to the same type as the other.
6211 * fold-const.c (fold_binary_loc): Assert expectation.
6212
6213 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
6214
6215 * config/darwin.c (machopic_legitimize_pic_address): Clean up
6216 extraneous parentheses, dead code section and formatting.
6217
6218 2018-08-24 David Malcolm <dmalcolm@redhat.com>
6219
6220 PR c++/87091
6221 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
6222 wide enough for jumps in the line-numbering to be visible.
6223 (layout::print_gap_in_line_numbering): New member function.
6224 (layout::calculate_line_spans): When using line numbering, merge
6225 line spans that are only 1 line apart.
6226 (diagnostic_show_locus): When printing line numbers, show gaps in
6227 line numbering directly, rather than printing headers.
6228 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
6229 line-numbering with multiple line spans.
6230 (selftest::test_fixit_insert_containing_newline_2): Add test of
6231 line-numbering, in which the spans are close enough to be merged.
6232
6233 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6234
6235 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
6236 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
6237 * tree-vrp.c (range_is_nonnull): Remove.
6238 (range_includes_zero_p): Accept value_range instead of min/max.
6239 (extract_range_from_binary_expr_1): Do not early bail on
6240 POINTER_PLUS_EXPR.
6241 Use range_includes_zero_p instead of range_is_nonnull.
6242 (extract_range_from_unary_expr): Use range_includes_zero_p instead
6243 of range_is_nonnull.
6244 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
6245 special case VR_ANTI_RANGE.
6246 (vrp_finalize): Same.
6247 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
6248 instead of min/max.
6249 (range_is_nonnull): Remove.
6250 * vr-values.c (vrp_stmt_computes_nonzero): Use
6251 range_includes_zero_p instead of range_is_nonnull.
6252 (extract_range_basic): Pass value_range to range_includes_zero_p
6253 instead of range_is_nonnull.
6254
6255 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
6256
6257 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
6258 * emit-rtl.h (rtl_data): Remove return_bnd.
6259 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
6260 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
6261 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
6262 (POINTER_BOUNDS_MODE): Remove definition.
6263 (make_pointer_bounds_mode): Remove.
6264 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
6265 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
6266 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
6267 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
6268 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
6269 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
6270 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
6271
6272 * config/i386/i386-modes.def (BND32, BND64): Remove.
6273 * config/i386/i386.c (dbx_register_map): Remove bound registers.
6274 (dbx64_register_map): Ditto.
6275 (svr4_dbx_register_map): Ditto.
6276 (indirect_thunk_bnd_needed): Remove.
6277 (indirect_thunks_bnd_used): Ditto.
6278 (indirect_return_bnd_needed): Ditto.
6279 (indirect_return_via_cx_bnd): Ditto.
6280 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
6281 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
6282 (output_indirect_thunk): Ditto. Remove need_prefix argument.
6283 (output_indirect_thunk_function): Remove handling of
6284 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
6285 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
6286 (ix86_save_reg): Remove handling of crtl->return_bnd.
6287 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
6288 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
6289 and UNSPEC_BNDLX_ADDR.
6290 (ix86_output_indirect_branch_via_reg): Remove handling of
6291 indirect_thunk_prefix_bnd.
6292 (ix86_output_indirect_branch_via_push): Ditto.
6293 (ix86_output_function_return): Ditto.
6294 (ix86_output_indirect_function_return): Ditto.
6295 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
6296 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
6297 (CALL_USED_REGISTERS): Ditto.
6298 (REG_ALLOC_ORDER): Update for removal of bound registers.
6299 (HI_REGISTER_NAMES): Ditto.
6300 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
6301 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
6302 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
6303 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
6304 (FIRST_PSEUDO_REG): Update.
6305 (BND): Remove mode iterator.
6306 * config/i386/predicates.md (bnd_mem_operator): Remove.
6307
6308 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6309
6310 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
6311 vectors.
6312
6313 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6314
6315 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
6316 the case in which the permute needs only a single element and
6317 repeats for every vector of the result. Extend that case to
6318 handle variable-length vectors.
6319 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
6320
6321 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
6322
6323 PR debug/79342
6324 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
6325 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
6326
6327 2018-08-24 Richard Biener <rguenther@suse.de>
6328
6329 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
6330 bb_flags_allocated members.
6331 (auto_flag): New RAII class for allocating flags.
6332 (auto_edge_flag): New RAII class for allocating edge flags.
6333 (auto_bb_flag): New RAII class for allocating bb flags.
6334 * cfgloop.c (verify_loop_structure): Allocate temporary edge
6335 flag dynamically.
6336 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
6337 in favor of temporarily allocated BB flag.
6338 * hsa-brig.c: Re-order includes.
6339 * hsa-dump.c: Likewise.
6340 * hsa-regalloc.c: Likewise.
6341 * print-rtl.c: Likewise.
6342 * profile-count.c: Likewise.
6343
6344 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
6345
6346 PR target/86989
6347 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
6348 the TOC register.
6349
6350 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6351
6352 PR 87073/bootstrap
6353 * wide-int-range.cc (wide_int_range_div): Do not ignore result
6354 from wide_int_range_multiplicative_op.
6355
6356 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6357
6358 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
6359 "permutaion".
6360
6361 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
6362
6363 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
6364 to 'expanded'.
6365
6366 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
6367
6368 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
6369 full GENERIC expression used for replacement.
6370
6371 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
6372
6373 * tree-vrp.c (abs_extent_range): Remove.
6374 (extract_range_into_wide_ints): Pass wide ints by reference.
6375 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
6376 Pass wide ints by reference in all calls to
6377 extract_range_into_wide_ints.
6378 * wide-int-range.cc (wide_int_range_div): New.
6379 * wide-int-range.h (wide_int_range_div): New.
6380 (wide_int_range_includes_zero_p): New.
6381 (wide_int_range_zero_p): New.
6382
6383 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
6384
6385 * config/aarch64/aarch64.md (arches): New enum.
6386 (arch): New enum attr.
6387 (arch_enabled): New attr.
6388 (enabled): Now uses arch_enabled only.
6389 (simd, sve, fp16): Removed attribute.
6390 (fp): Attr now defined in terms of 'arch'.
6391 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
6392 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
6393 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
6394 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
6395 attributes into 'arch'.
6396 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
6397 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
6398 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
6399 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
6400 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
6401 'simd' attribute into 'arch'.
6402 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
6403 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
6404 Convert use of 'fp' attribute to 'arch'.
6405 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
6406 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
6407 into 'arch'.
6408 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
6409 (different modes) Merge 'fp' and 'simd' into 'arch'.
6410 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
6411 'simd' into 'arch'.
6412
6413 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
6414
6415 PR rtl-optimization/87026
6416 * expmed.c (canonicalize_comparison): If we can no longer create
6417 pseudoregisters, don't.
6418
6419 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
6420
6421 PR target/86951
6422 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
6423 prototype.
6424 * config/arm/arm.c (speculation_barrier_libfunc): New static
6425 variable.
6426 (arm_init_libfuncs): Initialize it.
6427 (arm_emit_speculation_barrier): New function.
6428 * config/arm/arm.md (speculation_barrier): Call
6429 arm_emit_speculation_barrier for architectures that do not have
6430 DSB or ISB.
6431 (speculation_barrier_insn): Only match on Armv7 or later.
6432
6433 2018-08-23 Richard Biener <rguenther@suse.de>
6434
6435 PR middle-end/87024
6436 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
6437 calls.
6438
6439 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6440
6441 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
6442 of single-vector TBLs.
6443 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
6444 one input is given.
6445
6446 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6447
6448 PR target/85910
6449 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
6450 aarch64_evpc_tbl guard.
6451
6452 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
6453
6454 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
6455 behaviour.
6456
6457 2018-08-22 Martin Sebor <msebor@redhat.com>
6458
6459 PR middle-end/87052
6460 * tree-pretty-print.c (pretty_print_string): Add argument.
6461 (dump_generic_node): Call to pretty_print_string with string size.
6462
6463 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
6464
6465 PR rtl-optimization/86771
6466 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
6467 of two SETs into those two SETs, one to be placed at i2, if that SETs
6468 destination is modified between i2 and i3.
6469
6470 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6471
6472 PR tree-optimization/86725
6473 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
6474 function.
6475 (vect_analyze_scalar_cycles_1): Check it.
6476
6477 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6478
6479 PR tree-optimization/86725
6480 * tree-vect-loop.c (vect_is_simple_reduction): When treating
6481 an outer loop phi as a double reduction, make sure that the
6482 single user of the phi result is an inner loop phi.
6483
6484 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6485
6486 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
6487 grouped stores with gaps to a strided group.
6488
6489 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6490
6491 * tree-vect-stmts.c (get_group_load_store_type)
6492 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
6493 first statement in a group.
6494
6495 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6496
6497 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
6498 the sequence used in gcc/gcc.c.
6499
6500 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6501
6502 PR other/704
6503 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
6504 building it.
6505
6506 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6507
6508 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
6509 Darwin10-specific unwinder-shim.
6510 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
6511 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
6512 New to cater for Darwin10 Rosetta.
6513
6514 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6515
6516 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
6517 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
6518
6519 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6520
6521 PR bootstrap/81033
6522 PR target/81733
6523 PR target/52795
6524 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
6525 (dwarf2out_switch_text_section): Generate a local label for the
6526 second function sub-section and apply it as the second FDE start
6527 label.
6528 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
6529 second sub-section start.
6530
6531 2018-08-22 Richard Biener <rguenther@suse.de>
6532
6533 PR tree-optimization/86988
6534 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
6535
6536 2018-08-22 Richard Biener <rguenther@suse.de>
6537
6538 PR tree-optimization/86945
6539 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
6540
6541 2018-08-22 Alexandre Oliva <oliva@adacore.com>
6542
6543 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
6544 a comment about how uses of r2 for .sdata2 come about.
6545
6546 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
6547
6548 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
6549
6550 2018-08-21 Marek Polacek <polacek@redhat.com>
6551
6552 PR c++/86981, Implement -Wpessimizing-move.
6553 * doc/invoke.texi: Document -Wpessimizing-move.
6554
6555 2018-08-21 Jan Hubicka <jh@suse.cz>
6556
6557 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
6558 * tree.h (is_redundant_typedef): Remove.
6559 * dwarf2out.c (is_redundant_typedef): Turn into static function.
6560
6561 2018-08-21 Jan Hubicka <jh@suse.cz>
6562
6563 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
6564 when possible.
6565
6566 2018-08-21 Tamar Christina <tamar.christina@arm.com>
6567
6568 * expmed.c (extract_low_bits): Reject invalid subregs early.
6569
6570 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6571
6572 PR middle-end/86121
6573 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
6574 behaviour.
6575
6576 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6577
6578 * config/vxworks.h: Guard vxworks_asm_out_constructor and
6579 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
6580 * config/vxworks.c: Likewise.
6581
6582 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6583
6584 * config/vxworks.c: Set targetm.have_ctors_dtors
6585 if HAVE_INITFINI_ARRAY_SUPPORT.
6586 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
6587 if HAVE_INITFINI_ARRAY_SUPPORT.
6588
6589 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6590
6591 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
6592 default search path for VxWorks < 7.
6593
6594 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6595
6596 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
6597 (get_format_string): Refer to c_getstr.
6598
6599 2018-08-21 Tom de Vries <tdevries@suse.de>
6600
6601 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6602 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6603 (debuginfo_early_stop): Declare.
6604 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6605 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6606 (debuginfo_early_stop): New function.
6607 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
6608 and debuginfo_early_stop.
6609 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
6610 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
6611 (general_init): Call debuginfo_early_init.
6612 (finalize): Call debuginfo_fini.
6613 (do_compile): Call debuginfo_init.
6614 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
6615 -fdump-early-debug.
6616 (@item -fdump-debug, @item -fdump-earlydebug): Add.
6617
6618 2018-08-21 Tom de Vries <tdevries@suse.de>
6619
6620 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
6621 flag_dump_noaddr and flag_dump_unnumbered.
6622
6623 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
6624
6625 * wide-int-range.cc (wide_int_range_abs): New.
6626 (wide_int_range_order_set): Rename from wide_int_range_min_max.
6627 * wide-int-range.h (wide_int_range_abs): New.
6628 (wide_int_range_min_max): New.
6629 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
6630 case to call wide_int_range_abs.
6631 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
6632 (extract_range_from_abs_expr): Delete.
6633
6634 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
6635
6636 PR target/87033
6637 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
6638 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
6639 for indexed loads.
6640
6641 2018-08-20 Nathan Sidwell <nathan@acm.org>
6642 Jeff Law <law@redhat.com>
6643
6644 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
6645 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
6646
6647 2018-08-20 David Malcolm <dmalcolm@redhat.com>
6648
6649 PR other/84889
6650 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
6651 (decl_attributes): Likewise.
6652 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
6653 instance.
6654 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
6655 * diagnostic-core.h (class auto_diagnostic_group): New class.
6656 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
6657 (diagnostic_report_diagnostic): Handle the first diagnostics within
6658 a group.
6659 (emit_diagnostic): Add auto_diagnostic_group instance.
6660 (inform): Likewise.
6661 (inform_n): Likewise.
6662 (warning): Likewise.
6663 (warning_at): Likewise.
6664 (warning_n): Likewise.
6665 (pedwarn): Likewise.
6666 (permerror): Likewise.
6667 (error): Likewise.
6668 (error_n): Likewise.
6669 (error_at): Likewise.
6670 (sorry): Likewise.
6671 (fatal_error): Likewise.
6672 (internal_error): Likewise.
6673 (internal_error_no_backtrace): Likewise.
6674 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
6675 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
6676 * diagnostic.h (struct diagnostic_context): Add fields
6677 "diagnostic_group_nesting_depth",
6678 "diagnostic_group_emission_count", "begin_group_cb",
6679 "end_group_cb".
6680 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
6681 Add auto_diagnostic_group instance(s).
6682 (find_explicit_erroneous_behavior): Likewise.
6683 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
6684 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
6685 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
6686 (gimplify_va_arg_expr): Likewise.
6687 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
6688 (HSA_SORRY_AT): Likewise.
6689 * ipa-devirt.c (compare_virtual_tables): Likewise.
6690 (warn_odr): Likewise.
6691 * multiple_target.c (expand_target_clones): Likewise.
6692 * opts-common.c (cmdline_handle_error): Likewise.
6693 * reginfo.c (globalize_reg): Likewise.
6694 * substring-locations.c (format_warning_n_va): Likewise.
6695 * tree-inline.c (expand_call_inline): Likewise.
6696 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
6697 * tree-ssa-loop-niter.c
6698 (do_warn_aggressive_loop_optimizations): Likewise.
6699 * tree-ssa-uninit.c (warn_uninit): Likewise.
6700 * tree.c (warn_deprecated_use): Likewise.
6701
6702 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
6703
6704 PR target/87014
6705 * config/i386/i386.md (eh_return): Always update EH return
6706 address in word_mode.
6707
6708 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
6709
6710 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
6711 TARGET_SPLIT_COMPLEX_ARG is defined.
6712
6713 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6714
6715 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
6716
6717 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6718
6719 PR target/86984
6720 * expr.c (expand_assignment): Assert that bitpos is positive.
6721 (store_field): Likewise
6722 (expand_expr_real_1): Make sure that bitpos is positive.
6723 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
6724 integer overflow.
6725
6726 2018-08-20 Nathan Sidwell <nathan@acm.org>
6727
6728 * Makefile.in (CPP_ID_DATA_H): Delete.
6729 (CPP_INTERNAL_H): Don't add it.
6730 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
6731 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
6732
6733 2018-08-20 Richard Biener <rguenther@suse.de>
6734
6735 PR tree-optimization/78655
6736 * tree-vrp.c (extract_range_from_binary_expr_1): Make
6737 pointer + offset nonnull if either operand is nonnull work.
6738
6739 2018-08-20 Tom de Vries <tdevries@suse.de>
6740
6741 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
6742 unless the referenced die describes the added property using
6743 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
6744 Otherwise, add a DW_AT_location to the referenced die.
6745
6746 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
6747
6748 PR target/86994
6749 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
6750 register_operand when calling ix86_set_reg_reg_cost.
6751 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
6752 Set *total to 0 for operands that satisfy x86_64_immediate_operand
6753 predicate and to 1 otherwise.
6754
6755 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
6756
6757 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
6758 emit a diagnostic that it is not supported and reset the option.
6759 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
6760 supported and consume the option. (ASM_FINAL_SPEC): New.
6761
6762 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6763
6764 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
6765 a sentence.
6766
6767 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
6768
6769 C-SKY port: Documentation
6770
6771 * doc/extend.texi (C-SKY Function Attributes): New section.
6772 * doc/invoke.texi (Option Summary): Add C-SKY options.
6773 (C-SKY Options): New section.
6774 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
6775
6776 2018-08-17 Jojo <jijie_rong@c-sky.com>
6777 Huibin Wang <huibin_wang@c-sky.com>
6778 Sandra Loosemore <sandra@codesourcery.com>
6779 Chung-Lin Tang <cltang@codesourcery.com>
6780
6781 C-SKY port: Backend implementation
6782
6783 * config/csky/*: New.
6784 * common/config/csky/*: New.
6785
6786 2018-08-17 Jojo <jijie_rong@c-sky.com>
6787 Huibin Wang <huibin_wang@c-sky.com>
6788 Sandra Loosemore <sandra@codesourcery.com>
6789 Chung-Lin Tang <cltang@codesourcery.com>
6790 Andrew Jenner <andrew@codesourcery.com>
6791
6792 C-SKY port: Configury
6793
6794 * config.gcc (csky-*-*): New.
6795 * configure.ac: Add csky to targets for dwarf2 debug_line support.
6796 * configure: Regenerated.
6797
6798 2018-08-17 David Malcolm <dmalcolm@redhat.com>
6799
6800 * dump-context.h: Include "dumpfile.h".
6801 (dump_context::dump_printf_va): Convert final param from va_list
6802 to va_list *. Convert from ATTRIBUTE_PRINTF to
6803 ATTRIBUTE_GCC_DUMP_PRINTF.
6804 (dump_context::dump_printf_loc_va): Likewise.
6805 * dumpfile.c: Include "stringpool.h".
6806 (make_item_for_dump_printf_va): Delete.
6807 (make_item_for_dump_printf): Delete.
6808 (class dump_pretty_printer): New class.
6809 (dump_pretty_printer::dump_pretty_printer): New ctor.
6810 (dump_pretty_printer::emit_items): New member function.
6811 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
6812 function.
6813 (dump_pretty_printer::emit_item): New member function.
6814 (dump_pretty_printer::stash_item): New member function.
6815 (dump_pretty_printer::format_decoder_cb): New member function.
6816 (dump_pretty_printer::decode_format): New member function.
6817 (dump_context::dump_printf_va): Reimplement in terms of
6818 dump_pretty_printer.
6819 (dump_context::dump_printf_loc_va): Convert final param from va_list
6820 to va_list *.
6821 (dump_context::begin_scope): Reimplement call to
6822 make_item_for_dump_printf.
6823 (dump_printf): Update for change to dump_printf_va.
6824 (dump_printf_loc): Likewise.
6825 (selftest::test_capture_of_dump_calls): Convert "stmt" from
6826 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
6827 with %T, %E, and %G.
6828 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
6829 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
6830 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
6831 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
6832 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
6833 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
6834 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
6835 within a dump_printf_loc call to "%wu".
6836 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
6837 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
6838 missing space after "=".
6839 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
6840 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
6841 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
6842 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
6843 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
6844 duplicate "vectorized" from message.
6845
6846 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
6847
6848 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
6849 polyNxK_t element's TYPE_STRING_FLAG.
6850
6851 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6852
6853 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
6854 (they were unnamed before). Fix comments.
6855
6856 2018-08-17 Nathan Sidwell <nathan@acm.org>
6857
6858 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
6859
6860 2018-08-17 Richard Biener <rguenther@suse.de>
6861
6862 PR tree-optimization/86841
6863 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
6864
6865 2018-08-17 Martin Liska <mliska@suse.cz>
6866
6867 * common.opt: Remove Warn, Init and Report for options with
6868 Ignore/Deprecated flag. Warning is done automatically for
6869 Deprecated flags.
6870 * config/i386/i386.opt: Likewise.
6871 * config/ia64/ia64.opt: Likewise.
6872 * config/rs6000/rs6000.opt: Likewise.
6873 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
6874 Remove usage of flag_check_pointer_bounds.
6875 * lto-wrapper.c (merge_and_complain): Do not handle
6876 OPT_fcheck_pointer_bounds.
6877 (append_compiler_options): Likewise.
6878 * opt-functions.awk: Do not handle Deprecated.
6879 * optc-gen.awk: Check that Var, Report and Init are not
6880 used for an option with Ignore/Deprecated flag.
6881 * opts-common.c (decode_cmdline_option): Do not report
6882 CL_ERR_DEPRECATED.
6883 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
6884 options.
6885 * opts.h (struct cl_option): Remove cl_deprecated flag.
6886 (CL_ERR_DEPRECATED): Remove error enum value.
6887
6888 2018-08-17 Richard Biener <rguenther@suse.de>
6889
6890 PR middle-end/86505
6891 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
6892 across a va-arg-pack using call adjust its return value accordingly.
6893
6894 2018-08-16 Martin Sebor <msebor@redhat.com>
6895
6896 PR tree-optimization/86853
6897 * gimple-ssa-sprintf.c (struct format_result): Rename member.
6898 (struct fmtresult): Add member and initialize it in ctors.
6899 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
6900 (format_string): Handle %S the same as %ls. Set MAYFAIL.
6901 (format_directive): Set POSUNDER4K when MAYFAIL is set.
6902 (parse_directive): Handle %C same as %c.
6903 (sprintf_dom_walker::compute_format_length): Adjust.
6904 (is_call_safe): Adjust.
6905
6906 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
6907
6908 * builtins.c (c_strlen): Add new parameter eltsize. Use it
6909 for determining how to count the elements.
6910 * builtins.h (c_strlen): Adjust prototype.
6911 * expr.c (string_constant): Add new parameter mem_size.
6912 Set *mem_size appropriately.
6913 * expr.h (string_constant): Adjust protoype.
6914 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
6915 * gimple-fold.h (get_range_strlen): Adjust prototype.
6916 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
6917 (format_string): Call get_string_length with eltsize.
6918
6919 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6920
6921 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
6922 to emit the span, rather than setting it as the prefix.
6923
6924 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6925
6926 * diagnostic-show-locus.c (layout::start_annotation_line): Add
6927 "margin_char" parameter, defaulting to space. Use it in place
6928 of pp_space for the initial part of the margin.
6929 (layout::print_leading_fixits): Use '+' when filling the margin
6930 of line-insertion fix-it hints.
6931
6932 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6933
6934 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
6935 Delete.
6936
6937 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6938
6939 * config/rs6000/altivec.md: Don't set length attribute to the default
6940 value.
6941 * config/rs6000/darwin.md: Ditto.
6942 * config/rs6000/dfp.md: Ditto.
6943 * config/rs6000/htm.md: Ditto.
6944 * config/rs6000/rs6000.md: Ditto.
6945 * config/rs6000/sync.md: Ditto.
6946 * config/rs6000/vsx.md: Ditto.
6947
6948 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6949
6950 * config/rs6000/altivec.md: Don't set length attribute to the default
6951 value, for branch instructions.
6952 * config/rs6000/darwin.md: Ditto.
6953 * config/rs6000/rs6000.md: Ditto.
6954
6955 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6956
6957 * config/rs6000/rs6000.md (length): Always define as const_int 4.
6958 (unnamed conditional branch define_insn): Set length to 4 or 8
6959 depending on offset.
6960 (<bd>_<mode>): Similar, for alternative 0.
6961 (<bd>tf_<mode>): Ditto.
6962
6963 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6964
6965 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
6966
6967 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
6968
6969 * doc/rtl.texi: Replace old RTX class names with new names.
6970
6971
6972 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
6973
6974 * expmed.h (canonicalize_comparison): New declaration.
6975 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
6976 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
6977 * optabs.c (prepare_cmp_insn): Likewise.
6978 * rtl.h (unsigned_condition_p): New function which checks if a
6979 comparison operator is unsigned.
6980
6981 2018-08-16 Nathan Sidwell <nathan@acm.org>
6982
6983 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
6984 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
6985
6986 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6987
6988 PR target/84711
6989 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
6990 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
6991 (mov<mov>): ..this and enable unconditionally.
6992
6993 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6994
6995 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
6996
6997 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
6998
6999 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
7000 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
7001 "Common" with "Target".
7002
7003 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
7004
7005 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
7006 * doc/invoke.texi (mmitigate-rop): Remove.
7007 * config/i386/i386.c: Do not include "regrename.h".
7008 (ix86_rop_should_change_byte_p, reg_encoded_number)
7009 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
7010 Remove.
7011 (ix86_reorg): Remove call to ix86_mitigate_rop.
7012 * config/i386/i386.md (attr "modrm_class"): Remove.
7013 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
7014 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
7015 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
7016
7017 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
7018
7019 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
7020 allow folding of mergeh() and mergel() for the float and double types.
7021 (fold_mergehl_helper): Rework to handle building a permute tree
7022 for float vectors.
7023
7024 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
7025
7026 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
7027 for TARGET_SSE.
7028
7029 2018-08-15 David Malcolm <dmalcolm@redhat.com>
7030
7031 * common.opt (fdiagnostics-show-labels): New option.
7032 * diagnostic-show-locus.c (class layout_range): Add field
7033 "m_label".
7034 (class layout): Add field "m_show_labels_p".
7035 (layout_range::layout_range): Add param "label" and use it to
7036 initialize m_label.
7037 (make_range): Pass in NULL for new "label" param of layout_range's
7038 ctor.
7039 (layout::layout): Initialize m_show_labels_p.
7040 (layout::maybe_add_location_range): Pass in loc_range->m_label
7041 when constructing layout_range instances.
7042 (struct line_label): New struct.
7043 (layout::print_any_labels): New member function.
7044 (layout::print_line): Call it if label-printing is enabled.
7045 (selftest::test_one_liner_labels): New test.
7046 (selftest::test_diagnostic_show_locus_one_liner): Call it.
7047 * diagnostic.c (diagnostic_initialize): Initialize
7048 context->show_labels_p.
7049 * diagnostic.h (struct diagnostic_context): Add field
7050 "show_labels_p".
7051 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
7052 -fno-diagnostics-show-labels.
7053 * dwarf2out.c (gen_producer_string): Add
7054 OPT_fdiagnostics_show_labels to the ignored options.
7055 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
7056 param.
7057 (gcc_rich_location::maybe_add_expr): Likewise.
7058 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
7059 label" param, defaulting to NULL.
7060 (gcc_rich_location::add_expr): Add "label" param.
7061 (gcc_rich_location::maybe_add_expr): Likewise.
7062 (class text_range_label): New class.
7063 (class range_label_for_type_mismatch): New class.
7064 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
7065 of format_warning_va.
7066 (fmtwarn_n): Likewise for new params of format_warning_n_va.
7067 * lto-wrapper.c (merge_and_complain): Add
7068 OPT_fdiagnostics_show_labels to the "pick one setting" options.
7069 (append_compiler_options): Likewise to the dropped options.
7070 (append_diag_options): Likewise to the passed-on options.
7071 * opts.c (common_handle_option): Handle the new option.
7072 * selftest-diagnostic.c
7073 (test_diagnostic_context::test_diagnostic_context): Enable
7074 show_labels_p.
7075 * substring-locations.c: Include "gcc-rich-location.h".
7076 (format_warning_n_va): Add "fmt_label" and "param_label" params
7077 and use them as appropriate.
7078 (format_warning_va): Add "fmt_label" and "param_label" params,
7079 passing them on to format_warning_n_va.
7080 (format_warning_at_substring): Likewise.
7081 (format_warning_at_substring_n): Likewise.
7082 * substring-locations.h (format_warning_va): Add "fmt_label" and
7083 "param_label" params.
7084 (format_warning_n_va): Likewise.
7085 (format_warning_at_substring): Likewise.
7086 (format_warning_at_substring_n): Likewise.
7087 * toplev.c (general_init): Initialize global_dc->show_labels_p.
7088
7089 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
7090
7091 PR testsuite/86519
7092 * builtins.c (expand_builtin_memcmp): Do not expand the call
7093 when overflow is detected.
7094
7095 2018-08-15 Martin Sebor <msebor@redhat.com>
7096
7097 PR tree-optimization/71625
7098 * config/aarch64/aarch64-builtins.c
7099 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
7100
7101 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
7102
7103 * config/s390/s390.c (s390_reorg): Remove loop.
7104
7105 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
7106
7107 * config/darwin.c
7108 (darwin_function_switched_text_sections): Delete.
7109 * gcc/config/darwin.h
7110 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
7111
7112 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
7113
7114 PR target/81685
7115 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
7116 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
7117 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
7118
7119 2018-08-15 Martin Liska <mliska@suse.cz>
7120
7121 PR tree-optimization/86925
7122 * predict.c (expr_expected_value_1): When taking
7123 later predictor, assign also probability.
7124 Use fold_build2_initializer_loc in order to fold
7125 the expression in -frounding-math.
7126
7127 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
7128
7129 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
7130 patterns.
7131 (expand_vec_perm_1): Try the new method.
7132
7133 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
7134
7135 PR target/86547
7136 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
7137 Check whether lra_live_max_point is 0 before dividing.
7138
7139 2018-08-14 Martin Sebor <msebor@redhat.com>
7140
7141 PR tree-optimization/86650
7142 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
7143 (vrp_prop::check_mem_ref): Same.
7144
7145 2018-08-13 Liu Hao <lh_mouse@126.com>
7146
7147 * pretty-print.c (eat_esc_sequence): Swap the foreground and
7148 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
7149 and clear it thereafter, as it only works for DBCS.
7150
7151 2018-08-13 Liu Hao <lh_mouse@126.com>
7152
7153 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
7154 handle returned by _get_osf_handle().
7155
7156 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7157
7158 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
7159 for folding vec_perm.
7160
7161 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7162
7163 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
7164 Add support for gimple-folding of vec_pack() and vec_unpack()
7165 intrinsics.
7166
7167 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7168
7169 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
7170 vec_xst variants to the list.
7171 (rs6000_gimple_fold_builtin): Add support for folding unaligned
7172 vector loads and stores.
7173
7174 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
7175
7176 * config.gcc (rs6000-ibm-aix4.x): Delete.
7177 (rs6000-ibm-aix5.1): Delete.
7178 (rs6000-ibm-aix5.2): Delete.
7179 (rs6000-ibm-aix5.3): Delete.
7180 * config/rs6000/aix43.h: Delete.
7181 * config/rs6000/aix51.h: Delete.
7182 * config/rs6000/aix52.h: Delete.
7183 * config/rs6000/t-aix43: Delete.
7184
7185 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
7186
7187 * config/s390/s390.c (s390_decompose_constant_pool_ref):
7188 New function.
7189 (s390_decompose_address): Factor out constant pool ref
7190 decomposition.
7191
7192 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7193
7194 * config/nds32/nds32-predicates.c
7195 (nds32_can_use_bclr_p): Change return type as bool.
7196 (nds32_can_use_bset_p): Ditto.
7197 (nds32_can_use_btgl_p): Ditto.
7198 (nds32_can_use_bitci_p): Ditto.
7199 * config/nds32/nds32-protos.h
7200 (nds32_can_use_bclr_p): Change declaration.
7201 (nds32_can_use_bset_p): Ditto.
7202 (nds32_can_use_btgl_p): Ditto.
7203 (nds32_can_use_bitci_p): Ditto.
7204
7205 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7206
7207 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
7208 Support -msched-prolog-epilog option.
7209 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
7210
7211 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7212
7213 * common/config/nds32/nds32-common.c
7214 (nds32_option_optimization_table): Enalbe -malways-align.
7215
7216 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7217
7218 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
7219 extra_headers.
7220 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
7221 OPT_misr_secure_ case.
7222 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
7223 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
7224 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
7225 secure attribute.
7226 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
7227 (nds32_isr_info): New field security_level.
7228 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
7229 * config/nds32/nds32.md (return_internal): Consider critical attribute.
7230 * config/nds32/nds32.opt (misr-secure): New option.
7231 * config/nds32/nds32_init.inc: New file.
7232 * config/nds32/nds32_isr.h: New file.
7233
7234 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
7235
7236 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
7237 Update comment for atomic instructions.
7238 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
7239 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
7240 Remove.
7241 (atomic_loaddi): Revise fence expansion to only emit fence prior to
7242 load for __ATOMIC_SEQ_CST model.
7243 (atomic_loaddi_1): Remove float register target.
7244 (atomic_storedi): Handle CONST_INT values.
7245 (atomic_storedi_1): Remove float register source. Add special case
7246 for zero value.
7247 (memory_barrier): New expander and insn.
7248
7249 2018-08-11 Jakub Jelinek <jakub@redhat.com>
7250
7251 PR tree-optimization/86835
7252 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
7253 new_stmt after def_gsi, make sure to insert new_square_stmt after
7254 that stmt, not 2 stmts before it.
7255
7256 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
7257
7258 PR target/82418
7259 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
7260 instead of SWI48.
7261
7262 2018-08-10 Martin Liska <mliska@suse.cz>
7263
7264 PR target/83610
7265 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
7266 function type.
7267 * builtins.c (expand_builtin_expect_with_probability):
7268 New function.
7269 (expand_builtin_expect_with_probability): New function.
7270 (build_builtin_expect_predicate): Add new argumnet probability
7271 for BUILT_IN_EXPECT_WITH_PROBABILITY.
7272 (fold_builtin_expect):
7273 (fold_builtin_2):
7274 (fold_builtin_3):
7275 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
7276 * builtins.h (fold_builtin_expect): Set new argument.
7277 * doc/extend.texi: Document __builtin_expect_with_probability.
7278 * doc/invoke.texi: Likewise.
7279 * gimple-fold.c (gimple_fold_call): Pass new argument.
7280 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
7281 also BUILT_IN_EXPECT_WITH_PROBABILITY.
7282 * predict.c (get_predictor_value): New function.
7283 (expr_expected_value): Add new argument probability. Assume
7284 that predictor and probability are always non-null.
7285 (expr_expected_value_1): Likewise. For __builtin_expect and
7286 __builtin_expect_with_probability set probability. Handle
7287 combination in binary expressions.
7288 (tree_predict_by_opcode): Simplify code by simply calling
7289 get_predictor_value.
7290 (pass_strip_predict_hints::execute): Add handling of
7291 BUILT_IN_EXPECT_WITH_PROBABILITY.
7292 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
7293 new predictor.
7294 * tree.h (DECL_BUILT_IN_P): New function.
7295
7296 2018-08-10 Martin Liska <mliska@suse.cz>
7297
7298 PR tree-optimization/85799
7299 * passes.def: Add argument for pass_strip_predict_hints.
7300 * predict.c (class pass_strip_predict_hints): Add new argument
7301 early_p.
7302 (strip_predictor_early): New function.
7303 (pass_strip_predict_hints::execute): Call the function to
7304 strip predictors.
7305 (strip_predict_hints): New function.
7306 * predict.def: Fix comment.
7307
7308 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
7309
7310 * Makefile.in: Clarify which tm.texi to copy over to assert the
7311 right to grant a GFDL license for all.
7312
7313 2018-08-09 Jeff Law <law@redhat.com>
7314
7315 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
7316 unused variable.
7317
7318 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
7319
7320 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
7321 prototype.
7322
7323 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7324
7325 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
7326 reductions for variable-length vectors.
7327
7328 2018-08-09 David Malcolm <dmalcolm@redhat.com>
7329
7330 PR other/84889
7331 * common.opt (fdiagnostics-show-line-numbers): New option.
7332 * diagnostic-show-locus.c (class layout): Add fields
7333 "m_show_line_numbers_p" and "m_linenum_width";
7334 (num_digits): New function.
7335 (test_num_digits): New function.
7336 (layout::layout): Initialize new fields. Update m_x_offset
7337 logic to handle any left margin.
7338 (layout::print_source_line): Print line number when requested.
7339 (layout::start_annotation_line): New member function.
7340 (layout::print_annotation_line): Call it.
7341 (layout::print_leading_fixits): Likewise.
7342 (layout::print_trailing_fixits): Likewise. Update calls to
7343 move_to_column for new parameter.
7344 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
7345 it to potentially call start_annotation_line.
7346 (layout::show_ruler): Call start_annotation_line.
7347 (selftest::test_line_numbers_multiline_range): New selftest.
7348 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
7349 and selftest::test_line_numbers_multiline_range.
7350 * diagnostic.c (diagnostic_initialize): Initialize
7351 show_line_numbers_p.
7352 * diagnostic.h (struct diagnostic_context): Add field
7353 "show_line_numbers_p".
7354 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
7355 -fno-diagnostics-show-line-numbers.
7356 * dwarf2out.c (gen_producer_string): Add
7357 OPT_fdiagnostics_show_line_numbers to the ignored options.
7358 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
7359 one setting" options.
7360 (append_compiler_options): Likewise to the dropped options.
7361 (append_diag_options): Likewise to the passed-on options.
7362 * opts.c (common_handle_option): Handle the new option.
7363 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
7364
7365 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
7366
7367 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
7368 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
7369 third argument of type "const signed char" to descriptions of
7370 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
7371 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
7372 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
7373 __builtin_bcdsub_ov functions.
7374
7375 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7376
7377 PR tree-optimization/86858
7378 * tree-vect-loop.c (vect_is_simple_reduction): Restore
7379 flow_bb_inside_loop_p calls.
7380
7381 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7382
7383 PR tree-optimization/86871
7384 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
7385 instead of gimple_assign_lhs.
7386
7387 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
7388
7389 PR target/86887
7390 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
7391 register constraint to operand 0.
7392 (add<mode>3_carryinC): Likewise.
7393 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
7394
7395 2018-08-09 Martin Liska <mliska@suse.cz>
7396
7397 PR c/86895
7398 * common.opt: Remove extra line.
7399
7400 2018-08-09 Martin Liska <mliska@suse.cz>
7401
7402 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
7403 at the end of a line, make first letter capital and end up
7404 a sentence with a dot.
7405 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
7406 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
7407 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
7408 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
7409 (PARAM_MAX_ISL_OPERATIONS): Likewise.
7410 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
7411 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
7412 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
7413 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
7414 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
7415 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
7416 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
7417 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
7418 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
7419 (PARAM_TREE_REASSOC_WIDTH): Likewise.
7420 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
7421 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
7422 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
7423
7424 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
7425
7426 PR target/84332
7427 * config/s390/s390.c (s390_option_override_internal): Reduce the
7428 stack-clash-protection-probe-interval param if it would be too big
7429 for z900.
7430
7431 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
7432
7433 PR target/46179
7434 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
7435 * config/m68k/m68k.c (handle_move_double): Don't call
7436 m68k_final_prescan_insn.
7437 (m68k_adjust_decorated_operand): Renamed from
7438 m68k_final_prescan_insn, remove first and third operand and
7439 simplify.
7440 (print_operand): Call it.
7441 (print_operand_address): Call it.
7442
7443 2018-08-08 Nathan Sidwell <nathan@acm.org>
7444
7445 * diagnostic.c (diagnostic_report_current_module): Use
7446 linemap_included_from & linemap_included_from_linemap.
7447
7448 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
7449
7450 * config/aarch64/aarch64-cores.def: Add phecda core.
7451 * config/aarch64/aarch64-tune.md: Regenerate.
7452 * doc/invoke.texi: Add phecda core.
7453
7454 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7455
7456 PR target/85295
7457 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
7458 definitions.
7459 * config/s390/s390.md ("movti"): Add more alternatives for
7460 constant to GPR copies.
7461
7462 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7463
7464 * config/s390/s390.c: Fix whitespace damage throughout the file.
7465 * config/s390/s390.h: Likewise.
7466 * config/s390/tpf.h: Likewise.
7467
7468 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7469
7470 * config/s390/s390.c (s390_loadrelative_operand_p):
7471 Remove TARGET_CPU_ZARCH usages.
7472 (s390_rtx_costs): Likewise.
7473 (s390_legitimate_constant_p): Likewise.
7474 (s390_cannot_force_const_mem): Likewise.
7475 (legitimate_reload_constant_p): Likewise.
7476 (s390_preferred_reload_class): Likewise.
7477 (legitimize_pic_address): Likewise.
7478 (legitimize_tls_address): Likewise.
7479 (s390_split_branches): Removed.
7480 (s390_add_execute): Removed.
7481 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
7482 (s390_mainpool_start): Likewise.
7483 (s390_mainpool_finish): Likewise.
7484 (s390_mainpool_cancel): Removed.
7485 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
7486 (s390_chunkify_cancel): Likewise.
7487 (s390_return_addr_rtx): Likewise.
7488 (s390_register_info): Remove split_branches_pending_p uages.
7489 (s390_optimize_register_info): Likewise.
7490 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
7491 split_branches_pending_p usages.
7492 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
7493 (s390_load_got): Likewise.
7494 (s390_expand_split_stack_prologue): Likewise.
7495 (output_asm_nops): Likewise.
7496 (s390_function_profiler): Likewise.
7497 (s390_emit_call): Likewise.
7498 (s390_conditional_register_usage): Likewise.
7499 (s390_optimize_prologue): Likewise.
7500 (s390_reorg): Remove TARGET_CPU_ZARCH and
7501 split_branches_pending_p usages.
7502 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
7503 usages.
7504 (s390_output_indirect_thunk_function): Likewise.
7505 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
7506 (TARGET_CPU_ZARCH_P): Removed.
7507 (struct machine_function): Remove split_branches_pending_p.
7508 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
7509
7510 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7511
7512 * common/config/s390/s390-common.c (processor_flags_table):
7513 Remove flags.
7514 * config.gcc: Remove with_arch/with_tune support.
7515 * config/s390/2064.md: Remove cpu attribute comparisons.
7516 * config/s390/driver-native.c (s390_host_detect_local_cpu):
7517 Remove MTN.
7518 * config/s390/linux.h (ASM_SPEC):
7519 Remove -march support.
7520 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
7521 Use a table to get an arch level.
7522 * config/s390/s390-opts.h (enum processor_type):
7523 Remove enum values.
7524 * config/s390/s390.c
7525 (processor_table): Remove entries, add arch_level values.
7526 (s390_issue_rate): Remove cases.
7527 (s390_option_override): Adjust
7528 s390_option_override_internal() call.
7529 (s390_option_override_internal): Remove deprecation warning.
7530 (s390_valid_target_attribute_tree): Adjust
7531 s390_option_override_internal() call.
7532 * config/s390/s390.h (struct s390_processor):
7533 Share with s390-c.c, add arch_level field.
7534 * config/s390/s390.md:
7535 Remove occurrences in cpu attribute.
7536 * config/s390/s390.opt: Remove -march/-mtune support.
7537 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
7538 * doc/invoke.texi: Remove deprecation warning.
7539
7540 2018-08-08 Luis Machado <luis.machado@linaro.org>
7541
7542 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
7543 global.
7544 (qdf24xx_tunings): Set vector cost structure to
7545 qdf24xx_vector_cost.
7546
7547 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
7548 <register_sextend>: Set to 3.
7549
7550 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
7551
7552 PR target/86838
7553 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
7554 * config/aarch64/aarch64-simd.md
7555 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
7556 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
7557 (aarch64_frecpx<mode>): ...this new pattern.
7558 * config/aarch64/aarch64-simd-builtins.def: Remove comment
7559 about aarch64_frecp<FRECP:frecp_suffix><mode>.
7560
7561 2018-08-07 Martin Liska <mliska@suse.cz>
7562
7563 PR middle-end/83023
7564 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
7565 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
7566 * predict.def (PRED_MALLOC_NONNULL): New predictor.
7567 * doc/extend.texi: Document that malloc attribute adds
7568 hit to compiler.
7569
7570 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
7571
7572 PR target/86785
7573 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7574 Define to speculation_safe_value_not_needed.
7575
7576 2018-08-06 Jeff Law <law@redhat.com>
7577
7578 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
7579 the vr_values instance to cprop_into_stmt.
7580 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
7581 (cprop_operand): Also query EVRP to determine if OP is a constant.
7582
7583 2018-08-06 Nathan Sidwell <nathan@acm.org>
7584
7585 * diagnostic.c (diagnostic_report_current_module): Reroll
7586 included-at loop. Translate text.
7587
7588 2018-08-06 David Malcolm <dmalcolm@redhat.com>
7589
7590 * function-tests.c (selftest::test_expansion_to_rtl): Call
7591 free_after_compilation.
7592
7593 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7594
7595 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
7596
7597 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
7598
7599 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
7600 loops with memory block operations from getting unrolled.
7601
7602 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
7603
7604 PR target/86807
7605 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7606 Define to speculation_safe_value_not_needed.
7607
7608 2018-08-06 Jeff Law <law@redhat.com>
7609
7610 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
7611 assert.
7612
7613 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
7614
7615 PR target/86662
7616 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
7617 with all enabled __intN types.
7618
7619 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
7620
7621 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7622
7623 * alias.c (record_set): Check for clobber high.
7624 * cfgexpand.c (expand_gimple_stmt): Likewise.
7625 * combine-stack-adj.c (single_set_for_csa): Likewise.
7626 * combine.c (find_single_use_1): Likewise.
7627 (set_nonzero_bits_and_sign_copies): Likewise.
7628 (get_combine_src_dest): Likewise.
7629 (is_parallel_of_n_reg_sets): Likewise.
7630 (try_combine): Likewise.
7631 (record_dead_and_set_regs_1): Likewise.
7632 (reg_dead_at_p_1): Likewise.
7633 (reg_dead_at_p): Likewise.
7634 * dce.c (deletable_insn_p): Likewise.
7635 (mark_nonreg_stores_1): Likewise.
7636 (mark_nonreg_stores_2): Likewise.
7637 * df-scan.c (df_find_hard_reg_defs): Likewise.
7638 (df_uses_record): Likewise.
7639 (df_get_call_refs): Likewise.
7640 * dwarf2out.c (mem_loc_descriptor): Likewise.
7641 * haifa-sched.c (haifa_classify_rtx): Likewise.
7642 * ira-build.c (create_insn_allocnos): Likewise.
7643 * ira-costs.c (scan_one_insn): Likewise.
7644 * ira.c (equiv_init_movable_p): Likewise.
7645 (rtx_moveable_p): Likewise.
7646 (interesting_dest_for_shprep): Likewise.
7647 * jump.c (mark_jump_label_1): Likewise.
7648 * postreload-gcse.c (record_opr_changes): Likewise.
7649 * postreload.c (reload_cse_simplify): Likewise.
7650 (struct reg_use): Add source expr.
7651 (reload_combine): Check for clobber high.
7652 (reload_combine_note_use): Likewise.
7653 (reload_cse_move2add): Likewise.
7654 (move2add_note_store): Likewise.
7655 * print-rtl.c (print_pattern): Likewise.
7656 * recog.c (decode_asm_operands): Likewise.
7657 (store_data_bypass_p): Likewise.
7658 (if_test_bypass_p): Likewise.
7659 * regcprop.c (kill_clobbered_value): Likewise.
7660 (kill_set_value): Likewise.
7661 * reginfo.c (reg_scan_mark_refs): Likewise.
7662 * reload1.c (maybe_fix_stack_asms): Likewise.
7663 (eliminate_regs_1): Likewise.
7664 (elimination_effects): Likewise.
7665 (mark_not_eliminable): Likewise.
7666 (scan_paradoxical_subregs): Likewise.
7667 (forget_old_reloads_1): Likewise.
7668 * reorg.c (find_end_label): Likewise.
7669 (try_merge_delay_insns): Likewise.
7670 (redundant_insn): Likewise.
7671 (own_thread_p): Likewise.
7672 (fill_simple_delay_slots): Likewise.
7673 (fill_slots_from_thread): Likewise.
7674 (dbr_schedule): Likewise.
7675 * resource.c (update_live_status): Likewise.
7676 (mark_referenced_resources): Likewise.
7677 (mark_set_resources): Likewise.
7678 * rtl.c (copy_rtx): Likewise.
7679 * rtlanal.c (reg_referenced_p): Likewise.
7680 (single_set_2): Likewise.
7681 (noop_move_p): Likewise.
7682 (note_stores): Likewise.
7683 * sched-deps.c (sched_analyze_reg): Likewise.
7684 (sched_analyze_insn): Likewise.
7685
7686 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7687
7688 * cse.c (invalidate_reg): New function extracted from...
7689 (invalidate): ...here.
7690 (canonicalize_insn): Check for clobber high.
7691 (invalidate_from_clobbers): invalidate clobber highs.
7692 (invalidate_from_sets_and_clobbers): Likewise.
7693 (count_reg_usage): Check for clobber high.
7694 (insn_live_p): Likewise.
7695 * cselib.c (cselib_expand_value_rtx_1):Likewise.
7696 (cselib_invalidate_regno): Check for clobber in setter.
7697 (cselib_invalidate_rtx): Pass through setter.
7698 (cselib_invalidate_rtx_note_stores):
7699 (cselib_process_insn): Check for clobber high.
7700 * cselib.h (cselib_invalidate_rtx): Add operand.
7701
7702 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7703
7704 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
7705 (mark_not_eliminable): Likewise.
7706 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
7707 * lra-lives.c (process_bb_lives): Check for clobber high.
7708 * lra.c (new_insn_reg): Remember clobber highs.
7709 (collect_non_operand_hard_regs): Check for clobber high.
7710 (lra_set_insn_recog_data): Likewise.
7711 (add_regs_to_insn_regno_info): Likewise.
7712 (lra_update_insn_regno_info): Likewise.
7713
7714 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7715
7716 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
7717 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
7718
7719 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7720
7721 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
7722 (copy_insn_1): Likewise.
7723 (gen_hard_reg_clobber_high): New gen function.
7724 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
7725 * genemit.c (gen_exp): Likewise.
7726 (gen_emit_seq): Pass through info.
7727 (gen_insn): Check for CLOBBER_HIGH.
7728 (gen_expand): Pass through info.
7729 (gen_split): Likewise.
7730 (output_add_clobbers): Likewise.
7731 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
7732 (remove_clobbers): Likewise.
7733 * rtl.h (gen_hard_reg_clobber_high): New declaration.
7734
7735 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7736
7737 * doc/rtl.texi (clobber_high): Add.
7738 (parallel): Add in clobber high
7739 * rtl.c (rtl_check_failed_code3): Add function.
7740 * rtl.def (CLOBBER_HIGH): Add expression.
7741 * rtl.h (RTL_CHECKC3): Add macro.
7742 (rtl_check_failed_code3): Add declaration.
7743 (XC3EXP): Add macro.
7744
7745 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
7746
7747 PR target/86386
7748 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
7749 cfun->machine->max_used_stack_alignment if needed.
7750
7751 2018-08-04 Martin Sebor <msebor@redhat.com>
7752
7753 PR tree-optimization/86571
7754 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
7755 NaN output to 4.
7756
7757 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
7758
7759 PR target/86799
7760 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7761 Define.
7762
7763 2018-08-03 Jeff Law <law@redhat.com>
7764
7765 PR target/86795
7766 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7767 Define to speculation_safe_value_not_needed.
7768
7769 2018-08-03 David Malcolm <dmalcolm@redhat.com>
7770
7771 * doc/gcov.texi (-x): Remove duplicate "to".
7772 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
7773 (-Wif-not-aligned): Remove duplicate "is".
7774 (-flto): Remove duplicate "the".
7775 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
7776 duplicate "v5.00.b".
7777 (MSP430 Options): Remove duplicate "and" from the description
7778 of "-mgprel-sec=regexp".
7779 (x86 Options): Remove duplicate copies of "vmldLog102" and
7780 vmlsLog104 from description of "-mveclibabi=type".
7781
7782 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
7783
7784 * internal-fn.h (first_commutative_argument): Declare.
7785 * internal-fn.c (first_commutative_argument): New function.
7786 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
7787 restrictions for pattern statements. Use first_commutative_argument
7788 to look for commutative operands in calls to internal functions.
7789
7790 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
7791
7792 * Makefile.in (wide-int-range.o): New.
7793 * tree-vrp.c: Move all the wide_int_* functions to...
7794 * wide-int-range.cc: ...here.
7795 * tree-vrp.h: Move all the wide_int_* prototypes to...
7796 * wide-int-range.h: ...here.
7797
7798 2018-08-03 Tom de Vries <tdevries@suse.de>
7799
7800 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
7801 UI_NONE.
7802 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
7803 * except.c (output_function_exception_table): Do early exit if
7804 targetm_common.except_unwind_info (&global_options) == UI_NONE.
7805
7806 2018-08-03 Martin Liska <mliska@suse.cz>
7807
7808 * predict.c (dump_prediction): Change to 2 digits
7809 in fraction part.
7810
7811 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
7812
7813 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
7814 neon_dup_q to...
7815 (falkor_am_1_gtov_gtov): ... a new insn reservation.
7816
7817 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
7818
7819 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
7820 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
7821 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
7822 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
7823 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
7824
7825 2018-08-02 David Malcolm <dmalcolm@redhat.com>
7826
7827 * diagnostic-show-locus.c (diagnostic_show_locus): Use
7828 pp_take_prefix when saving the existing prefix.
7829 * diagnostic.c (diagnostic_append_note): Likewise.
7830 * langhooks.c (lhd_print_error_function): Likewise.
7831 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
7832 param's type. Free the existing prefix.
7833 (pp_take_prefix): New function.
7834 (pretty_printer::pretty_printer): Drop the prefix parameter.
7835 Rename the length parameter to match the comment.
7836 (pretty_printer::~pretty_printer): Free the prefix.
7837 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
7838 parameter.
7839 (struct pretty_printer): Drop the "const" from "prefix" field's
7840 type and clarify memory management.
7841 (pp_set_prefix): Drop the "const" from the 2nd param.
7842 (pp_take_prefix): New decl.
7843
7844 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
7845
7846 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
7847 for word_mode_ok here instead of passing as argument.
7848 (expand_block_compare): Change select_block_compare_mode() call.
7849 (expand_strncmp_gpr_sequence): New function.
7850 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
7851
7852 2018-08-02 Jeff Law <law@redhat.com>
7853
7854 PR target/86790
7855 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7856 Define to speculation_safe_value_not_needed.
7857
7858 PR target/86784
7859 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7860 Define to speculation_safe_value_not_needed.
7861
7862 2018-08-02 Tom de Vries <tdevries@suse.de>
7863
7864 PR target/86660
7865 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
7866 function. Return UI_TARGET unconditionally.
7867 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
7868 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
7869
7870 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7871
7872 * genemit.c (print_overload_test): Fix typo.
7873
7874 2018-08-02 Richard Biener <rguenther@suse.de>
7875
7876 PR tree-optimization/86816
7877 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
7878 which checks for value availability before querying it.
7879 (gvn_uses_equal): Use it.
7880 (same_succ_hash): Likewise.
7881 (gimple_equal_p): Likewise.
7882
7883 2018-08-02 Nick Clifton <nickc@redhat.com>
7884
7885 PR target/86813
7886 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7887 Define to speculation_safe_value_not_needed.
7888
7889 PR target/86810
7890 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7891 Define to speculation_safe_value_not_needed.
7892
7893 PR target/86810
7894 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7895 Define to speculation_safe_value_not_needed.
7896
7897 PR target/86803
7898 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7899 Define to speculation_safe_value_not_needed.
7900
7901 PR target/86797
7902 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7903 Define to speculation_safe_value_not_needed.
7904
7905 PR target/86791
7906 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7907 Define to speculation_safe_value_not_needed.
7908
7909 PR target/86789
7910 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7911 Define to speculation_safe_value_not_needed.
7912
7913 PR target/86787
7914 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7915 Define to speculation_safe_value_not_needed.
7916
7917 PR target/86782
7918 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
7919 speculation_safe_value_not_needed.
7920
7921 PR target/86781
7922 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
7923 to speculation_safe_value_not_needed.
7924
7925 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7926
7927 * doc/md.texi: Expand the documentation of instruction names
7928 to mention port-local uses. Document '@' in pattern names.
7929 * read-md.h (overloaded_instance, overloaded_name): New structs.
7930 (mapping): Declare.
7931 (md_reader::handle_overloaded_name): New member function.
7932 (md_reader::get_overloads): Likewise.
7933 (md_reader::m_first_overload): New member variable.
7934 (md_reader::m_next_overload_ptr): Likewise.
7935 (md_reader::m_overloads_htab): Likewise.
7936 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
7937 m_next_overload_ptr and m_overloads_htab.
7938 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
7939 (get_mode_token, get_code_token, get_int_token): New functions.
7940 (map_attr_string): Add an optional argument that passes back
7941 the associated iterator.
7942 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
7943 (md_reader::handle_overloaded_name, add_overload_instance): New
7944 functions.
7945 (apply_iterators): Handle '@' names. Report an error if '@'
7946 is used without iterators.
7947 (initialize_iterators): Initialize the new iterator_group fields.
7948 * genopinit.c (handle_overloaded_code_for)
7949 (handle_overloaded_gen): New functions.
7950 (main): Use them to print declarations of maybe_code_for_* and
7951 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
7952 * genemit.c (print_overload_arguments, print_overload_test)
7953 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
7954 (main): Use it to print definitions of maybe_code_for_* and
7955 maybe_gen_* functions.
7956 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
7957 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
7958 instead of explicit mode checks.
7959 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
7960 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
7961 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
7962 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
7963 (aarch64_expand_compare_and_swap): Likewise
7964 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
7965 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
7966 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
7967 (aarch64_constant_pool_reload_icode): Delete.
7968 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
7969 instead of aarch64_constant_pool_reload_icode. Use
7970 code_for_aarch64_reload_mov instead of explicit mode checks.
7971 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
7972 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
7973 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
7974 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
7975 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
7976 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
7977 (aarch64_atomic_load_op_code): Delete.
7978 (aarch64_emit_atomic_load_op): Likewise.
7979 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
7980 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
7981 instead of aarch64_emit_atomic_load_op.
7982 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
7983 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
7984 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
7985 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
7986 character before the pattern name.
7987 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
7988 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
7989 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
7990 (aarch64_frecps<mode>): Likewise.
7991 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
7992 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
7993 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
7994 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
7995 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
7996
7997 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7998
7999 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
8000 Allow HFmode constants if TARGET_FP_F16INST.
8001
8002 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
8003
8004 PR target/86014
8005 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
8006 No longer check last store for clobber of address register.
8007
8008 2018-08-02 Martin Liska <mliska@suse.cz>
8009
8010 PR gcov-profile/86817
8011 * gcov.c (process_all_functions): New function.
8012 (main): Call it.
8013 (process_file): Move functions processing to
8014 process_all_functions.
8015
8016 2018-08-02 David Malcolm <dmalcolm@redhat.com>
8017
8018 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
8019 "const" to the "gimple *" and "rtx_insn *" parameters.
8020 * dumpfile.h (dump_user_location_t::dump_user_location_t):
8021 Likewise.
8022 (dump_location_t::dump_location_t): Likewise.
8023
8024 2018-08-01 Martin Sebor <msebor@redhat.com>
8025
8026 PR tree-optimization/86650
8027 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
8028 rather than a "gcall *". Directly pass the data of interest
8029 to percent_K_format, rather than building a temporary CALL_EXPR
8030 to hold it.
8031 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
8032 (gimple_fold_builtin_strncat): Adjust.
8033 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
8034 gcall* argument with gimple*.
8035 * gimple-ssa-warn-restrict.c (check_call): Same.
8036 (wrestrict_dom_walker::before_dom_children): Same.
8037 (builtin_access::builtin_access): Same.
8038 (check_bounds_or_overlap): Same
8039 (maybe_diag_overlap): Same.
8040 (maybe_diag_offset_bounds): Same.
8041 * tree-diagnostic.c (default_tree_printer): Move usage of
8042 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
8043 to this callsite.
8044 * tree-pretty-print.c (percent_K_format): Add argument.
8045 * tree-pretty-print.h: Add argument.
8046 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
8047 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
8048 (maybe_diag_stxncpy_trunc): Same.
8049 (handle_builtin_stxncpy): Same.
8050 (handle_builtin_strcat): Same.
8051
8052 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8053
8054 * match.pd: Optimise pointer range checks.
8055
8056 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8057
8058 PR tree-optimization/86758
8059 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
8060 to remove pattern statements.
8061
8062 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8063
8064 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
8065 result of dfs_enumerate_from when constructing stmt_vec_infos,
8066 instead of additionally calling get_loop_body.
8067
8068 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8069
8070 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
8071 parameter.
8072 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
8073 When creating an iv, assert that the step is not known to be zero.
8074 (vect_setup_realignment): Update call accordingly.
8075 * tree-vect-stmts.c (vectorizable_store): Likewise.
8076 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
8077
8078 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8079
8080 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
8081 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
8082 (vectorizable_reduction): Likewise.
8083 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8084 (vect_detect_hybrid_slp_stmts): Likewise.
8085 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
8086
8087 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
8088
8089 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
8090 (wide_int_set_zero_nonzero_bits): ...this.
8091 (zero_nonzero_bits_from_vr): Rename to...
8092 (vrp_set_zero_nonzero_bits): ...this.
8093 (extract_range_from_multiplicative_op_1): Abstract wide int
8094 code...
8095 (wide_int_range_multiplicative_op): ...here.
8096 (extract_range_from_binary_expr_1): Extract wide int binary
8097 operations into their own functions.
8098 (wide_int_range_lshift): New.
8099 (wide_int_range_can_optimize_bit_op): New.
8100 (wide_int_range_shift_undefined_p): New.
8101 (wide_int_range_bit_xor): New.
8102 (wide_int_range_bit_ior): New.
8103 (wide_int_range_bit_and): New.
8104 (wide_int_range_trunc_mod): New.
8105 (extract_range_into_wide_ints): New.
8106 (vrp_shift_undefined_p): New.
8107 (extract_range_from_multiplicative_op): New.
8108 (vrp_can_optimize_bit_op): New.
8109 * tree-vrp.h (value_range::dump): New.
8110 (wide_int_range_multiplicative_op): New.
8111 (wide_int_range_lshift):New.
8112 (wide_int_range_shift_undefined_p): New.
8113 (wide_int_range_bit_xor): New.
8114 (wide_int_range_bit_ior): New.
8115 (wide_int_range_bit_and): New.
8116 (wide_int_range_trunc_mod): New.
8117 (zero_nonzero_bits_from_bounds): Rename to...
8118 (wide_int_set_zero_nonzero_bits): ...this.
8119 (zero_nonzero_bits_from_vr): Rename to...
8120 (vrp_set_zero_nonzero_bits): ...this.
8121 (range_easy_mask_min_max): Rename to...
8122 (wide_int_range_can_optimize_bit_op): this.
8123 * vr-values.c (simplify_bit_ops_using_ranges): Rename
8124 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
8125
8126 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8127
8128 * tree-vectorizer.h (vect_orig_stmt): New function.
8129 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
8130 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
8131 (vect_create_epilog_for_reduction): Likewise.
8132 (vectorizable_live_operation): Likewise.
8133 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8134 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
8135 * tree-vect-stmts.c (vectorizable_call): Likewise.
8136 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
8137
8138 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8139
8140 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
8141 argument.
8142 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
8143 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
8144 (vect_transform_loop): Likewise.
8145 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8146
8147 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8148
8149 * tree-vectorizer.h (vect_schedule_slp): Return void.
8150 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8151 (vect_schedule_slp): Likewise.
8152
8153 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8154
8155 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
8156 argument.
8157 (vect_transform_loop): Update calls accordingly. Schedule SLP
8158 instances before the main loop, if any exist.
8159
8160 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8161
8162 PR tree-optimization/86749
8163 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
8164 If the lhs is used in a COND_EXPR, check that it is being used
8165 as the "then" or "else" value.
8166
8167 2018-08-01 Tom de Vries <tdevries@suse.de>
8168
8169 PR target/86800
8170 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
8171 speculation_safe_value_not_needed.
8172
8173 2018-08-01 Richard Biener <rguenther@suse.de>
8174
8175 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
8176 as base and offset.
8177
8178 2018-08-01 Martin Liska <mliska@suse.cz>
8179
8180 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
8181 format how successful transformation is dumped.
8182 (gimple_mod_pow2_value_transform): Likewise.
8183 (gimple_mod_subtract_transform): Likewise.
8184 (gimple_stringops_transform): Likewise.
8185
8186 2018-08-01 Martin Liska <mliska@suse.cz>
8187
8188 PR value-prof/35543
8189 * value-prof.c (interesting_stringop_to_profile_p):
8190 Simplify the code and add BUILT_IN_MEMMOVE.
8191 (gimple_stringops_transform): Likewise.
8192
8193 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
8194
8195 * config/aarch64/aarch64-simd.md
8196 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
8197 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
8198 use GPI iterator instead of SI mode.
8199
8200 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8201
8202 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
8203 rs6000_speculation_barrier.
8204 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
8205 new barrier pattern name.
8206
8207 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8208
8209 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
8210 (speculation_barrier): New insn.
8211
8212 2018-08-01 Richard Biener <rguenther@suse.de>
8213
8214 PR bootstrap/86724
8215 * graphite.h: Include isl/id.h and isl/space.h to allow build
8216 with ISL 0.20.
8217
8218 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
8219
8220 PR target/86651
8221 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
8222 mode for COFF targets.
8223 * defaults.h (TARGET_COFF): Define.
8224 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
8225 TARGET_COFF): Define.
8226 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
8227 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
8228 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
8229
8230 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8231
8232 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
8233 * gimple-streamer-out.c (output_bb): Save it.
8234 * lto-streamer-in.c (input_struct_function_base): Restore
8235 instance discriminator if available. Create map on demand.
8236 * lto-streamer-out.c (output_struct_function_base): Save it if
8237 available.
8238 * final.c (decl_to_instance_map): Document LTO strategy.
8239
8240 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8241 Olivier Hainque <hainque@adacore.com>
8242
8243 * debug.h (decl_to_instance_map_t): New type.
8244 (decl_to_instance_map): Declare.
8245 (maybe_create_decl_to_instance_map): New inline function.
8246 * final.c (bb_discriminator, last_bb_discriminator): New statics,
8247 to track basic block discriminators.
8248 (final_start_function_1): Initialize them.
8249 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
8250 bb_discriminator.
8251 (decl_to_instance_map): New variable.
8252 (map_decl_to_instance, maybe_set_discriminator): New functions.
8253 (notice_source_line): Set discriminator.
8254
8255 2018-07-31 Ian Lance Taylor <iant@golang.org>
8256
8257 * targhooks.c (default_have_speculation_safe_value): Add
8258 ATTRIBUTE_UNUSED.
8259
8260 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8261
8262 * dump-context.h: Include "pretty-print.h".
8263 (dump_context::refresh_dumps_are_enabled): New decl.
8264 (dump_context::emit_item): New decl.
8265 (class dump_context): Add fields "m_test_pp" and
8266 "m_test_pp_flags".
8267 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8268 (temp_dump_context::get_dumped_text): New decl.
8269 (class temp_dump_context): Add field "m_pp".
8270 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
8271 (dump_context::refresh_dumps_are_enabled): ...and add a test for
8272 m_test_pp.
8273 (set_dump_file): Update for above change.
8274 (set_alt_dump_file): Likewise.
8275 (dump_loc): New overload, taking a pretty_printer *.
8276 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
8277 to any test pretty-printer.
8278 (make_item_for_dump_gimple_stmt): New function, adapted from
8279 optinfo::add_gimple_stmt.
8280 (dump_context::dump_gimple_stmt): Call it, and use the result,
8281 eliminating the direct usage of dump_file and alt_dump_file in
8282 favor of indirectly using them via emit_item.
8283 (make_item_for_dump_gimple_expr): New function, adapted from
8284 optinfo::add_gimple_expr.
8285 (dump_context::dump_gimple_expr): Call it, and use the result,
8286 eliminating the direct usage of dump_file and alt_dump_file in
8287 favor of indirectly using them via emit_item.
8288 (make_item_for_dump_generic_expr): New function, adapted from
8289 optinfo::add_tree.
8290 (dump_context::dump_generic_expr): Call it, and use the result,
8291 eliminating the direct usage of dump_file and alt_dump_file in
8292 favor of indirectly using them via emit_item.
8293 (make_item_for_dump_printf_va): New function, adapted from
8294 optinfo::add_printf_va.
8295 (make_item_for_dump_printf): New function.
8296 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
8297 and use the result, eliminating the direct usage of dump_file and
8298 alt_dump_file in favor of indirectly using them via emit_item.
8299 (make_item_for_dump_dec): New function.
8300 (dump_context::dump_dec): Call it, and use the result,
8301 eliminating the direct usage of dump_file and alt_dump_file in
8302 favor of indirectly using them via emit_item.
8303 (make_item_for_dump_symtab_node): New function, adapted from
8304 optinfo::add_symtab_node.
8305 (dump_context::dump_symtab_node): Call it, and use the result,
8306 eliminating the direct usage of dump_file and alt_dump_file in
8307 favor of indirectly using them via emit_item.
8308 (dump_context::begin_scope): Reimplement, avoiding direct usage
8309 of dump_file and alt_dump_file in favor of indirectly using them
8310 via emit_item.
8311 (dump_context::emit_item): New member function.
8312 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8313 Set up test pretty-printer on the underlying context. Call
8314 refresh_dumps_are_enabled.
8315 (temp_dump_context::~temp_dump_context): Call
8316 refresh_dumps_are_enabled.
8317 (temp_dump_context::get_dumped_text): New member function.
8318 (selftest::verify_dumped_text): New function.
8319 (ASSERT_DUMPED_TEXT_EQ): New macro.
8320 (selftest::test_capture_of_dump_calls): Run all tests twice, with
8321 and then without optinfo enabled. Add uses of
8322 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
8323 * dumpfile.h: Update comment for the dump_* API.
8324 * optinfo-emit-json.cc
8325 (selftest::test_building_json_from_dump_calls): Update for new
8326 param for temp_dump_context ctor.
8327 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
8328 and "m_owned" field.
8329 (optinfo_item::~optinfo_item): Likewise.
8330 (optinfo::add_item): New member function.
8331 (optinfo::emit): Update comment.
8332 (optinfo::add_string): Delete.
8333 (optinfo::add_printf): Delete.
8334 (optinfo::add_printf_va): Delete.
8335 (optinfo::add_gimple_stmt): Delete.
8336 (optinfo::add_gimple_expr): Delete.
8337 (optinfo::add_tree): Delete.
8338 (optinfo::add_symtab_node): Delete.
8339 (optinfo::add_dec): Delete.
8340 * optinfo.h (class dump_context): New forward decl.
8341 (optinfo::add_item): New decl.
8342 (optinfo::add_string): Delete.
8343 (optinfo::add_printf): Delete.
8344 (optinfo::add_printf_va): Delete.
8345 (optinfo::add_gimple_stmt): Delete.
8346 (optinfo::add_gimple_expr): Delete.
8347 (optinfo::add_tree): Delete.
8348 (optinfo::add_symtab_node): Delete.
8349 (optinfo::add_dec): Delete.
8350 (optinfo::add_poly_int): Delete.
8351 (optinfo_item::optinfo_item): Remove "owned" param.
8352 (class optinfo_item): Remove field "m_owned".
8353
8354 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
8355
8356 PR middle-end/86705
8357 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
8358 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
8359 requested variable alignment.
8360 (expand_one_ssa_partition): Likewise.
8361 (expand_one_var): Likewise.
8362
8363 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8364
8365 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
8366 to speculation_safe_value_not_needed.
8367
8368 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8369
8370 * targhooks.h (speculation_safe_value_not_needed): New prototype.
8371 * targhooks.c (speculation_safe_value_not_needed): New function.
8372 * target.def (have_speculation_safe_value): Update documentation.
8373 * doc/tm.texi: Regenerated.
8374
8375 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8376
8377 * config/aarch64/iterators.md (ALLI_TI): New iterator.
8378 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
8379 expand.
8380 (despeculate_copy<ALLI:mode>_insn): New insn.
8381 (despeculate_copyti_insn): New insn.
8382 (despeculate_simple<ALLI:mode>): New insn
8383 (despeculate_simpleti): New insn.
8384 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
8385 function.
8386 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
8387 aarch64_speculation_safe_value.
8388 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
8389
8390 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8391
8392 * config/aarch64/aarch64-speculation.cc: New file.
8393 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
8394 before pass_reorder_blocks.
8395 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
8396 prototype.
8397 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
8398 X14 and X15 when tracking speculation.
8399 * config/aarch64/aarch64.md (register name constants): Add
8400 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
8401 (unspec): Add UNSPEC_SPECULATION_TRACKER.
8402 (speculation_barrier): New insn attribute.
8403 (cmp<mode>): Allow SP in comparisons.
8404 (speculation_tracker): New insn.
8405 (speculation_barrier): Add speculation_barrier attribute.
8406 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
8407 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
8408 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
8409
8410 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8411
8412 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
8413 aarch64_track_speculation is true.
8414 (tb<optab><mode>1): Likewise.
8415 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
8416 generate CB[N]Z when tracking speculation.
8417 (aarch64_split_compare_and_swap): Likewise.
8418 (aarch64_split_atomic_op): Likewise.
8419
8420 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8421
8422 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
8423
8424 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8425
8426 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
8427 (speculation_barrier): New insn.
8428
8429 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8430
8431 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
8432 * config/arm/arm.md (speculation_barrier): New expand.
8433 (speculation_barrier_insn): New pattern.
8434
8435 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8436
8437 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
8438 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
8439 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
8440 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
8441 list.
8442 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
8443 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
8444 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
8445 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
8446 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
8447 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
8448 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
8449 * builtins.c (expand_speculation_safe_value): New function.
8450 (expand_builtin): Call it.
8451 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
8452 * doc/extend.texi: Document __builtin_speculation_safe_value.
8453 * doc/md.texi: Document "speculation_barrier" pattern.
8454 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
8455 TARGET_HAVE_SPECULATION_SAFE_VALUE.
8456 * doc/tm.texi: Regenerated.
8457 * target.def (have_speculation_safe_value, speculation_safe_value): New
8458 hooks.
8459 * targhooks.c (default_have_speculation_safe_value): New function.
8460 (default_speculation_safe_value): New function.
8461 * targhooks.h (default_have_speculation_safe_value): Add prototype.
8462 (default_speculation_safe_value): Add prototype.
8463
8464 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8465
8466 * dump-context.h (dump_context::dump_loc): New decl.
8467 * dumpfile.c (dump_context::dump_loc): New member function.
8468 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
8469 and dump_gimple_stmt.
8470 (dump_context::dump_gimple_expr_loc): Likewise, using
8471 dump_gimple_expr.
8472 (dump_context::dump_generic_expr_loc): Likewise, using
8473 dump_generic_expr.
8474 (dump_context::dump_printf_loc_va): Likewise, using
8475 dump_printf_va.
8476 (dump_context::begin_scope): Explicitly using the global function
8477 "dump_loc", rather than the member function.
8478
8479 2018-07-31 Martin Sebor <msebor@redhat.com>
8480
8481 PR tree-optimization/86741
8482 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
8483
8484 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
8485
8486 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
8487 depend on whether prefetch instructions will be emitted or not.
8488 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
8489 will be emitted or not.
8490 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
8491 (TARGET_SETMEM_PFD): New macros.
8492
8493 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8494
8495 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
8496 (NULL_STMT_VEC_INFO): Delete.
8497 (stmt_vec_info::operator*): Likewise.
8498 (stmt_vec_info::operator gimple *): Likewise.
8499 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
8500 of NULL_STMT_VEC_INFO.
8501 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
8502 (vect_reassociating_reduction_p): Likewise.
8503 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
8504 (vectorizable_store): Likewise.
8505 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
8506 (vec_info::free_stmt_vec_infos): Likewise.
8507
8508 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8509
8510 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
8511 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
8512
8513 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8514
8515 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
8516 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8517 (vec_info::free_stmt_vec_info): New private member functions.
8518 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
8519 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
8520 * tree-parloops.c (gather_scalar_reductions): Remove calls to
8521 set_stmt_vec_info_vec and free_stmt_vec_infos.
8522 * tree-vect-loop.c (_loop_vec_info): Remove call to
8523 set_stmt_vec_info_vec.
8524 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
8525 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
8526 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
8527 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8528 (vec_info::free_stmt_vec_info): ...these new functions. Remove
8529 assignments in {vec_info::,}new_stmt_vec_info that are redundant
8530 with the clearing in the xcalloc.
8531 (stmt_vec_info_vec): Delete.
8532 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
8533 (vectorize_loops): Likewise.
8534 (vec_info::~vec_info): Remove argument from call to
8535 free_stmt_vec_infos.
8536 (vec_info::add_stmt): Remove vinfo argument from call to
8537 new_stmt_vec_info.
8538
8539 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8540
8541 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
8542 rather than a gimple stmt.
8543 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
8544 information for pattern statements when passed the original
8545 statement; instead wait to be passed the pattern statement itself.
8546 Don't call set_vinfo_for_stmt here.
8547 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
8548 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
8549 stmt_vec_infos here.
8550 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
8551 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
8552 stmt_vec_infos entry.
8553
8554 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8555
8556 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
8557 * tree-vectorizer.c (vec_info::replace_stmt): New function.
8558 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
8559 * tree-vect-stmts.c (vectorizable_call): Likewise.
8560 (vectorizable_simd_clone_call): Likewise.
8561
8562 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8563
8564 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
8565 * tree-vectorizer.c (vec_info::remove_stmt): New function.
8566 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
8567 * tree-vect-loop.c (vect_transform_loop): Likewise.
8568 * tree-vect-slp.c (vect_schedule_slp): Likewise.
8569 * tree-vect-stmts.c (vect_remove_stores): Likewise.
8570
8571 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8572
8573 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
8574 (vect_dr_stmt): Delete.
8575 * tree-vectorizer.c (vec_info::lookup_dr): New function.
8576 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
8577 of DR_VECT_AUX.
8578 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
8579 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
8580 (vect_verify_datarefs_alignment, vect_peeling_supportable)
8581 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8582 (vect_analyze_data_refs): Likewise.
8583 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
8584 argument.
8585 (vect_find_same_alignment_drs): Likewise.
8586 (vect_slp_analyze_node_dependences): Update calls accordingly.
8587 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8588 instead of DR_VECT_AUX.
8589 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
8590 of a vector data references. Use vec_info::lookup_dr instead of
8591 DR_VECT_AUX.
8592 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
8593 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8594 instead of DR_VECT_AUX.
8595
8596 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8597
8598 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
8599 dr_vec_info.
8600 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8601 accordingly.
8602 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8603 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
8604 (vect_gen_prolog_loop_niters): Likewise.
8605
8606 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8607
8608 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
8609 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
8610 (vect_known_alignment_in_bytes, vect_dr_behavior)
8611 (vect_get_scalar_dr_size): Take references as dr_vec_infos
8612 instead of data_references. Update calls to other routines for
8613 which the same change has been made.
8614 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
8615 dr_vec_infos instead of stmt_vec_infos.
8616 (vect_analyze_data_ref_dependence): Update call accordingly.
8617 (vect_slp_analyze_data_ref_dependence)
8618 (vect_record_base_alignments): Use DR_VECT_AUX.
8619 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
8620 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
8621 (vector_alignment_reachable_p, vect_get_data_access_cost)
8622 (vect_peeling_supportable, vect_analyze_group_access_1)
8623 (vect_analyze_group_access, vect_analyze_data_ref_access)
8624 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
8625 (vect_compile_time_alias, vect_small_gap_p)
8626 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
8627 (vect_supportable_dr_alignment): Take references as dr_vec_infos
8628 instead of data_references. Update calls to other routines for
8629 which the same change has been made.
8630 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
8631 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8632 (vect_slp_analyze_and_verify_node_alignment)
8633 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8634 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8635 (vect_setup_realignment): Use dr_vec_infos. Update calls after
8636 above changes.
8637 (_vect_peel_info::dr): Replace with...
8638 (_vect_peel_info::dr_info): ...this new field.
8639 (vect_peeling_hash_get_most_frequent)
8640 (vect_peeling_hash_choose_best_peeling): Update accordingly.
8641 (vect_peeling_hash_get_lowest_cost):
8642 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
8643 routines for which the same change has been made.
8644 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
8645 data_reference.
8646 * tree-vect-loop-manip.c (get_misalign_in_elems)
8647 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
8648 above changes.
8649 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8650 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
8651 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
8652 (get_group_load_store_type, get_negative_load_store_type)
8653 (vect_get_data_ptr_increment, vectorizable_store)
8654 (vectorizable_load): Likewise.
8655 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
8656 Update calls to other routines for which the same change has been made.
8657
8658 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8659
8660 * tree-vectorizer.h (vec_info::move_dr): New member function.
8661 (dataref_aux): Rename to...
8662 (dr_vec_info): ...this and add "dr" and "stmt" fields.
8663 (_stmt_vec_info::dr_aux): Update accordingly.
8664 (_stmt_vec_info::data_ref_info): Delete.
8665 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
8666 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
8667 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
8668 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
8669 of data_ref.
8670 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
8671 (STMT_VINFO_DR_INFO): New macro.
8672 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
8673 (set_dr_misalignment): Update after rename of dataref_aux.
8674 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
8675 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
8676 initialization of STMT_VINFO_DATA_REF.
8677 * tree-vectorizer.c (vec_info::move_dr): New function.
8678 * tree-vect-patterns.c (vect_recog_bool_pattern)
8679 (vect_recog_mask_conversion_pattern)
8680 (vect_recog_gather_scatter_pattern): Use it.
8681 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
8682 the "dr" and "stmt" fields of dr_vec_info instead of
8683 STMT_VINFO_DATA_REF.
8684
8685 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8686
8687 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
8688 (is_pattern_stmt_p): Use it.
8689 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
8690 on pattern statements.
8691
8692 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8693
8694 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
8695 original stmt as a stmt_vec_info rather than a gimple stmt.
8696 (vect_pattern_recog_1): Take the statement directly as a
8697 stmt_vec_info, rather than via a gimple_stmt_iterator.
8698 Update call to vect_mark_pattern_stmts.
8699 (vect_pattern_recog): Update calls accordingly.
8700
8701 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8702
8703 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
8704 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
8705 a vect_def_type for the first argument.
8706 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
8707 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
8708 operand if it isn't defined by a vectorized statement.
8709 (vect_build_gather_load_calls): Remove the mask_dt argument and
8710 update calls to vect_get_vec_def_for_stmt_copy.
8711 (vectorizable_bswap): Likewise the dt argument.
8712 (vectorizable_call): Update calls to vectorizable_bswap and
8713 vect_get_vec_def_for_stmt_copy.
8714 (vectorizable_simd_clone_call, vectorizable_assignment)
8715 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
8716 (vectorizable_comparison): Update calls to
8717 vect_get_vec_def_for_stmt_copy.
8718 (vectorizable_store): Likewise. Remove now-unnecessary calls to
8719 vect_is_simple_use.
8720 (vect_get_loop_based_defs): Remove dt argument and update call
8721 to vect_get_vec_def_for_stmt_copy.
8722 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
8723 and vect_get_vec_def_for_stmt_copy.
8724 (vectorizable_load): Update calls to vect_build_gather_load_calls
8725 and vect_get_vec_def_for_stmt_copy.
8726 * tree-vect-loop.c (vect_create_epilog_for_reduction)
8727 (vectorizable_reduction, vectorizable_live_operation): Update calls
8728 to vect_get_vec_def_for_stmt_copy.
8729
8730 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8731
8732 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
8733 and gimple stmt arguments with a stmt_vec_info.
8734 (vect_record_base_alignments): Update calls accordingly.
8735 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
8736 and gimple stmt arguments with a stmt_vec_info.
8737 (vect_build_slp_tree_1): Remove vinfo argument and update call
8738 to vect_record_max_nunits.
8739 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
8740 and vect_record_max_nunits.
8741
8742 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8743
8744 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
8745 file and take a stmt_vec_info instead of a gimple stmt.
8746 (supportable_widening_operation, vect_finish_replace_stmt)
8747 (vect_finish_stmt_generation, vect_get_store_rhs)
8748 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
8749 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
8750 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
8751 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
8752 (vect_create_data_ref_ptr, bump_vector_ptr)
8753 (vect_permute_store_chain, vect_setup_realignment)
8754 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
8755 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
8756 (vectorizable_reduction, vectorizable_induction)
8757 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
8758 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
8759 than gimple stmts as arguments.
8760 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
8761 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
8762 (can_group_stmts_p, vect_check_gather_scatter)
8763 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8764 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
8765 (vect_permute_load_chain, vect_shift_permute_load_chain)
8766 (vect_transform_grouped_load)
8767 (vect_record_grouped_load_vectors): Likewise.
8768 * tree-vect-loop.c (vect_fixup_reduc_chain)
8769 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
8770 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
8771 (vectorizable_reduction, vectorizable_induction)
8772 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
8773 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
8774 (vect_get_load_store_mask): Likewise.
8775 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
8776 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
8777 * tree-vect-stmts.c (vect_mark_relevant)
8778 (is_simple_and_all_uses_invariant)
8779 (exist_non_indexing_operands_for_use_p, process_use)
8780 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
8781 (vect_get_vec_def_for_operand, vect_get_vec_defs)
8782 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
8783 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
8784 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
8785 (get_negative_load_store_type, get_load_store_type)
8786 (vect_check_load_store_mask, vect_check_store_rhs)
8787 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
8788 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8789 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8790 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8791 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
8792 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
8793 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
8794 (supportable_widening_operation): Likewise.
8795
8796 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8797
8798 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
8799 a stmt_vec_info instead of a gcall.
8800 (vect_check_gather_scatter): Update call accordingly.
8801 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
8802 of a gphi.
8803 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
8804 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
8805 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
8806 instead of a gimple stmt.
8807 (vect_transform_loop): Update calls accordingly.
8808 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
8809 stmt_vec_infos instead of gimple stmts.
8810 (vect_analyze_slp_instance): Update use accordingly.
8811 * tree-vect-stmts.c (read_vector_array, write_vector_array)
8812 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
8813 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
8814 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
8815 (vect_gen_widened_results_half, vect_get_loop_based_defs)
8816 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
8817 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
8818 down to subroutines.
8819
8820 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8821
8822 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
8823 of the worklist from a vector of gimple stmts to a vector of
8824 stmt_vec_infos.
8825 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8826 (vect_mark_stmts_to_be_vectorized): Likewise
8827
8828 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8829
8830 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
8831 statement before passing it to vect_analyze_stmt.
8832 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
8833 the chain of phi vector definitions. Track the exit phi via its
8834 stmt_vec_info.
8835 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
8836 STMT_VINFO_REDUC_DEF.
8837 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
8838 stmt_vec_infos to handle the statement chains.
8839 (vect_get_slp_defs): Record the first statement in the node
8840 using a stmt_vec_info.
8841 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
8842 statements here and pass their stmt_vec_info down to subroutines.
8843 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
8844 down to vect_finish_stmt_generation.
8845 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
8846 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
8847 stmt_vec_infos to subroutines.
8848 (vect_remove_stores): Use stmt_vec_infos to handle the statement
8849 chains.
8850
8851 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8852
8853 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
8854 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
8855 (vect_permute_store_chain, vect_setup_realignment)
8856 (vect_permute_load_chain, vect_shift_permute_load_chain)
8857 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
8858 stmts internally, and when passing values to other vectorizer routines.
8859 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8860 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
8861 (vect_analyze_loop_operations, get_initial_def_for_reduction)
8862 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
8863 (vectorizable_reduction, vectorizable_induction)
8864 (vectorizable_live_operation, vect_transform_loop_stmt)
8865 (vect_transform_loop): Likewise.
8866 * tree-vect-patterns.c (vect_reassociating_reduction_p)
8867 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
8868 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
8869 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8870 (vect_slp_analyze_node_operations_1): Likewise.
8871 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8872 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
8873 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
8874 (vect_finish_stmt_generation_1, get_group_load_store_type)
8875 (get_load_store_type, vect_build_gather_load_calls)
8876 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8877 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8878 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8879 (vectorizable_store, vectorizable_load, vectorizable_condition)
8880 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
8881 (supportable_widening_operation): Likewise.
8882 (vect_get_vector_types_for_stmt): Likewise.
8883 * tree-vectorizer.h (vect_dr_behavior): Likewise.
8884
8885 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8886
8887 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8888 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
8889 (vect_permute_store_chain, vect_permute_load_chain)
8890 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
8891 repeated stmt_vec_info lookups.
8892 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8893 (vect_update_ivs_after_vectorizer): Likewise.
8894 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
8895 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
8896 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
8897 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8898 (vect_bb_slp_scalar_cost): Likewise.
8899 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
8900
8901 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8902
8903 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
8904 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
8905 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
8906 to get gassigns and gcalls, rather than operating on generc gimple
8907 stmts.
8908 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
8909 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
8910 (vectorizable_load, vect_analyze_stmt): Likewise.
8911 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
8912
8913 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8914
8915 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
8916 return stmt_vec_infos rather than gimple stmts. Do not accept
8917 null arguments.
8918 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
8919 of a gimple stmt.
8920 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8921 Update use of get_later_stmt.
8922 (vect_get_constant_vectors): Update call accordingly.
8923 (vect_schedule_slp_instance): Likewise
8924 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
8925 (vect_slp_analyze_instance_dependence): Likewise.
8926 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
8927
8928 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8929
8930 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
8931 (stmt_info_for_cost::stmt_info): ...this new field.
8932 (add_stmt_costs): Update accordingly.
8933 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
8934 (vect_get_known_peeling_cost): Likewise.
8935 (vect_estimate_min_profitable_iters): Likewise.
8936 * tree-vect-stmts.c (record_stmt_cost): Likewise.
8937
8938 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8939
8940 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
8941 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8942 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8943 accordingly.
8944 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
8945
8946 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8947
8948 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
8949 a gimple stmt to a stmt_vec_info.
8950 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
8951
8952 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8953
8954 * tree-vectorizer.h (vec_info::grouped_stores): Change from
8955 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8956 (_loop_vec_info::reduction_chains): Likewise.
8957 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
8958 accordingly.
8959 * tree-vect-slp.c (vect_analyze_slp): Likewise.
8960
8961 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8962
8963 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
8964 a gimple stmt to a stmt_vec_info.
8965 (_stmt_vec_info::next_element): Likewise.
8966 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
8967 (vect_slp_analyze_and_verify_node_alignment)
8968 (vect_analyze_group_access_1, vect_analyze_group_access)
8969 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
8970 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
8971 (vect_supportable_dr_alignment): Update accordingly.
8972 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
8973 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
8974 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
8975 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
8976 * tree-vect-slp.c (vect_build_slp_tree_1)
8977 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
8978 (vect_split_slp_store_group, vect_analyze_slp_instance)
8979 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
8980 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
8981 (get_group_load_store_type, get_load_store_type)
8982 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
8983 (vect_transform_stmt, vect_remove_stores): Likewise.
8984
8985 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8986
8987 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
8988 than a gimple stmt.
8989 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8990 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
8991 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
8992 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
8993 (vector_alignment_reachable_p, vect_get_data_access_cost)
8994 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
8995 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
8996 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8997 (vect_analyze_group_access_1, vect_analyze_group_access)
8998 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
8999 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
9000 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
9001 result of vect_dr_stmt and use the stmt_vec_info instead of
9002 the associated gimple stmt.
9003 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
9004 (vect_gen_prolog_loop_niters): Likewise.
9005 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
9006
9007 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9008
9009 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
9010 to a vec<stmt_vec_info>.
9011 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
9012 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
9013 vec<stmt_vec_info>.
9014 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
9015 to a vec<stmt_vec_info>.
9016 (bst_traits::value_type, bst_traits::value_type): Likewise.
9017 (bst_traits::hash): Update accordingly.
9018 (vect_get_and_check_slp_defs): Change the stmts parameter from
9019 a vec<gimple *> to a vec<stmt_vec_info>.
9020 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
9021 (vect_build_slp_tree): Likewise.
9022 (vect_build_slp_tree_2): Likewise. Update uses of
9023 SLP_TREE_SCALAR_STMTS.
9024 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
9025 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
9026 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
9027 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
9028 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
9029 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
9030 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
9031 (vect_get_constant_vectors, vect_get_slp_defs)
9032 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
9033 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
9034 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
9035 instead of gimple stmts.
9036 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
9037 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
9038 (vect_slp_analyze_instance_dependence): Update uses of
9039 SLP_TREE_SCALAR_STMTS.
9040 (vect_slp_analyze_and_verify_node_alignment): Likewise.
9041 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
9042 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
9043 (get_initial_defs_for_reduction): Likewise.
9044 (vect_create_epilog_for_reduction): Likewise.
9045 (vectorize_fold_left_reduction): Likewise.
9046 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
9047 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
9048 (can_vectorize_live_stmts): Likewise.
9049
9050 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9051
9052 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
9053 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
9054 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
9055 than gimple stmts.
9056 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
9057 of a gimple stmt.
9058 (gather_scalar_reductions): Update after above interface changes.
9059 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
9060 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
9061 than gimple stmts.
9062 (vect_force_simple_reduction): Likewise.
9063 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
9064 LOOP_VINFO_REDUCTIONS.
9065 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
9066
9067 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9068
9069 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
9070 a gimple stmt to a stmt_vec_info.
9071 * tree-vect-loop.c (vect_active_double_reduction_p)
9072 (vect_force_simple_reduction, vectorizable_reduction): Update
9073 accordingly.
9074
9075 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9076
9077 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
9078 vec<gimple *> to a vec<stmt_vec_info>.
9079 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
9080 the reduction_phis argument from a vec<gimple *> to a
9081 vec<stmt_vec_info>.
9082 (vectorizable_reduction): Likewise the phis local variable that
9083 is passed to vect_create_epilog_for_reduction. Update for new type
9084 of SLP_TREE_VEC_STMTS.
9085 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
9086 (vectorizable_live_operation): Likewise.
9087 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
9088 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
9089
9090 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9091
9092 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
9093 a gimple stmt to a stmt_vec_info.
9094 (vectorizable_condition, vectorizable_live_operation)
9095 (vectorizable_reduction, vectorizable_induction): Pass back the
9096 vectorized statement as a stmt_vec_info.
9097 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
9098 use of STMT_VINFO_VEC_STMT.
9099 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
9100 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
9101 as stmt_vec_infos rather than gimple stmts.
9102 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
9103 to a stmt_vec_info.
9104 (vectorizable_live_operation): Likewise.
9105 (vectorizable_reduction, vectorizable_induction): Likewise,
9106 updating use of STMT_VINFO_VEC_STMT.
9107 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
9108 of STMT_VINFO_VEC_STMT.
9109 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
9110 (vectorizable_simd_clone_call, vectorizable_conversion)
9111 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
9112 (vectorizable_store, vectorizable_load, vectorizable_condition)
9113 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
9114 from a gimple stmt to a stmt_vec_info.
9115 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
9116 pointer to a stmt_vec_info to the vectorizable_* routines.
9117
9118 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9119
9120 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
9121 a gimple stmt to a stmt_vec_info.
9122 (is_pattern_stmt_p): Update accordingly.
9123 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
9124 (vect_record_grouped_load_vectors): Likewise.
9125 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
9126 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
9127 (vect_model_reduction_cost): Likewise.
9128 (vect_create_epilog_for_reduction): Likewise.
9129 (vectorizable_reduction, vectorizable_induction): Likewise.
9130 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9131 Return the stmt_vec_info for the pattern statement.
9132 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
9133 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
9134 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9135 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
9136 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
9137 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
9138 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
9139 (free_stmt_vec_info, vect_is_simple_use): Likewise.
9140
9141 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9142
9143 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
9144 (vect_finish_stmt_generation): Likewise.
9145 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9146 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
9147 (vect_build_gather_load_calls): Use the return value of the above
9148 functions instead of a separate call to vinfo_for_stmt. Use narrow
9149 scopes for the input gimple stmt and wider scopes for the associated
9150 stmt_vec_info. Use vec_info::lookup_def when setting these
9151 stmt_vec_infos from an SSA_NAME definition.
9152 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
9153 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
9154 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
9155 (vectorizable_store, vectorizable_load, vectorizable_condition)
9156 (vectorizable_comparison): Likewise.
9157 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
9158 (vectorizable_reduction): Likewise.
9159
9160 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9161
9162 * tree-vectorizer.h (vect_is_simple_use): Add an optional
9163 stmt_vec_info * parameter before the optional gimple **.
9164 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9165 (process_use, vect_get_vec_def_for_operand_1): Update callers.
9166 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
9167 * tree-vect-loop.c (vectorizable_reduction): Likewise.
9168 (vectorizable_live_operation): Likewise.
9169 * tree-vect-patterns.c (type_conversion_p): Likewise.
9170 (vect_look_through_possible_promotion): Likewise.
9171 (vect_recog_rotate_pattern): Likewise.
9172 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
9173
9174 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9175
9176 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
9177 a typedef to a wrapper class.
9178 (NULL_STMT_VEC_INFO): New macro.
9179 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
9180 (stmt_vec_info::operator*): New function.
9181 (stmt_vec_info::operator gimple *): Likewise.
9182 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
9183 (add_stmt_costs): Likewise.
9184 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
9185 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
9186 (vect_get_known_peeling_cost): Likewise.
9187 (vect_estimate_min_profitable_iters): Likewise.
9188 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9189 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
9190 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
9191 (vectorizable_store, free_stmt_vec_infos): Likewise.
9192 (new_stmt_vec_info): Change return type of xcalloc to
9193 _stmt_vec_info *.
9194
9195 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9196
9197 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
9198 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
9199 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
9200 a single_imm_use-based sequence.
9201 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
9202
9203 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9204
9205 * tree-vectorizer.h (vec_info::lookup_def): Declare.
9206 * tree-vectorizer.c (vec_info::lookup_def): New function.
9207 * tree-vect-patterns.c (vect_get_internal_def): Use it.
9208 (vect_widened_op_tree): Likewise.
9209 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9210 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
9211 (vectorizable_reduction): Likewise.
9212 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
9213 of a gimple *.
9214 (vect_is_slp_reduction): Update calls accordingly. Use
9215 vec_info::lookup_def.
9216 (vect_is_simple_reduction): Likewise
9217 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
9218
9219 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9220
9221 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
9222 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
9223 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
9224 of vinfo_for_stmt.
9225 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
9226 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
9227 (vect_update_vf_for_slp, vect_analyze_loop_operations)
9228 (vect_is_slp_reduction, vectorizable_induction)
9229 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
9230 * tree-vect-patterns.c (vect_init_pattern_stmt):
9231 (vect_determine_min_output_precision_1, vect_determine_precisions)
9232 (vect_pattern_recog): Likewise.
9233 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
9234 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
9235 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
9236 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9237 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
9238 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
9239 info field from a loop to a loop_vec_info.
9240
9241 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9242
9243 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
9244 (vec_info::add_stmt): Declare.
9245 * tree-vectorizer.c (vec_info::add_stmt): New function.
9246 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
9247 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
9248 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
9249 (vectorizable_induction): Likewise.
9250 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
9251 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9252 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
9253 (vectorizable_load): Likewise.
9254 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9255 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
9256 (vect_recog_gather_scatter_pattern): Likewise.
9257 (append_pattern_def_seq): Likewise. Remove a check that is
9258 performed by add_stmt itself.
9259
9260 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9261
9262 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
9263 which make_ssa_name was called with new_stmt before new_stmt
9264 had been created.
9265
9266 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9267
9268 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
9269 split out from...
9270 (vect_is_slp_reduction): ...here...
9271 (vect_is_simple_reduction): ...and here. Remove repetition of tests
9272 that are already known to be false.
9273
9274 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9275
9276 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
9277 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
9278 STMT_VINFO_NUM_SLP_USES when it's true.
9279 (vect_free_slp_instance): Add a final_p parameter and pass it to
9280 vect_free_slp_tree.
9281 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
9282 (vect_analyze_slp_instance): Likewise.
9283 (vect_slp_analyze_operations): Likewise.
9284 (vect_slp_analyze_bb_1): Likewise.
9285 * tree-vectorizer.c (vec_info): Likewise.
9286 * tree-vect-loop.c (vect_transform_loop): Likewise.
9287
9288 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9289
9290 * tree-vect-loop.c (vectorizable_reduction): Assert that the
9291 function is not called for second and subsequent members of
9292 a reduction group.
9293
9294 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9295
9296 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
9297 cases for nested loops from here to ...
9298 (vect_create_epilog_for_reduction): ...here. Only call
9299 vect_is_simple_use for inner-loop reductions.
9300
9301 2018-07-31 Martin Liska <mliska@suse.cz>
9302
9303 PR gcov-profile/85338
9304 PR gcov-profile/85350
9305 PR gcov-profile/85372
9306 * profile.c (struct location_triplet): New.
9307 (struct location_triplet_hash): Likewise.
9308 (output_location): Do not output a BB that
9309 is already recorded for a line.
9310 (branch_prob): Use streamed_locations.
9311
9312 2018-07-31 Martin Liska <mliska@suse.cz>
9313
9314 PR gcov-profile/85370
9315 * coverage.c (coverage_begin_function): Do not mark target
9316 clones as artificial functions.
9317
9318 2018-07-31 Martin Liska <mliska@suse.cz>
9319
9320 PR gcov-profile/83813
9321 PR gcov-profile/84758
9322 PR gcov-profile/85217
9323 PR gcov-profile/85332
9324 * profile.c (branch_prob): Do not record GOTO expressions
9325 for GIMPLE statements which locations are already streamed.
9326
9327 2018-07-31 Olivier Hainque <hainque@adacore.com>
9328
9329 * gcc.c (handle_spec_function): Accept a soft_matched_part
9330 argument, as do_spec_1. Pass it down to ...
9331 (eval_spec_function): Accept a soft_matched_part argument,
9332 and pass it down to ...
9333 (do_spec_2): Accept a soft_matched_part argument, and pass
9334 it down to do_spec_1.
9335 (do_spec_1): Pass soft_matched_part to handle_spec_function.
9336 (handle_braces): Update call to handle_spec_function.
9337 (driver::set_up_specs): Update calls to do_spec_2.
9338 (compare_debug_dump_opt_spec_function): Likewise.
9339 (compare_debug_self_opt_spec_function): Likewise.
9340
9341 2018-07-31 Olivier Hainque <hainque@adacore.com>
9342
9343 * common.opt (nolibc): New option.
9344 * doc/invoke.texi (Link Options): Document it.
9345 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
9346 * config/alpha/linux.h: Likewise.
9347 * config/arc/elf.h: Likewise.
9348 * config/arm/uclinux-elf.h: Likewise.
9349 * config/arm/unknown-elf.h: Likewise.
9350 * config/avr/avrlibc.h: Likewise.
9351 * config/bfin/bfin.h: Likewise.
9352 * config/bfin/linux.h: Likewise.
9353 * config/bfin/uclinux.h: Likewise.
9354 * config/darwin.h: Likewise.
9355 * config/darwin10.h: Likewise.
9356 * config/darwin12.h: Likewise.
9357 * config/gnu-user.h: Likewise.
9358 * config/lm32/uclinux-elf.h: Likewise.
9359 * config/pa/pa-hpux11.h: Likewise.
9360 * config/pa/pa64-hpux.h: Likewise.
9361 * config/sparc/sparc.h: Likewise.
9362
9363 2018-07-31 Olivier Hainque <hainque@adacore.com>
9364
9365 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
9366 undefined variables.
9367
9368 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9369
9370 PR target/86640
9371 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
9372 instead of GEN_INT.
9373
9374 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
9375
9376 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
9377 terminated string literal.
9378
9379 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9380
9381 PR rtl-optimization/85160
9382 * combine.c (is_just_move): New function.
9383 (try_combine): Allow combining two instructions into two if neither of
9384 the original instructions was a move.
9385
9386 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
9387
9388 PR target/86673
9389 * doc/extend.texi (Global Register Variables): Discourage use of type
9390 qualifiers.
9391 (Local Register Variables): Likewise.
9392
9393 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
9394
9395 PR tree-optimization/86506
9396 * hwint.h (ceil_log2): Resync with hwint.c implementation.
9397
9398 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
9399
9400 PR target/86547
9401 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
9402 hard_regno, make sure no insn between `from` and `to` clobbers it.
9403
9404 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
9405 Tom de Vries <tdevries@suse.de>
9406
9407 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
9408 (PTX_DEFAULT_RUNTIME_DIM): ... this.
9409 (nvptx_goacc_validate_dims): Set default worker and gang dims to
9410 PTX_DEFAULT_RUNTIME_DIM.
9411 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
9412
9413 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
9414
9415 * config/pa/pa.c (pa_output_addr_vec): Align address table.
9416 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
9417 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
9418
9419 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
9420
9421 * config/rs6000/constraints.md (wG constraint): Delete, no longer
9422 used.
9423 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
9424 predicate to reflect toc fusion has been deleted.
9425 (toc_fusion_mem_raw): Delete, no longer used.
9426 (toc_fusion_mem_wrapped): Likewise.
9427 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
9428 fusion mask bit.
9429 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
9430 Delete, no longer used.
9431 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
9432 meant to be used for toc fusion.
9433 (rs6000_debug_print_mode): Delete toc fusion debugging.
9434 (rs6000_debug_reg_global): Likewise.
9435 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
9436 fusion and secondary reload support that were never used.
9437 (rs6000_option_override_internal): Delete TOC fusion, that was only
9438 partially defined, and it did not work unless you also used the
9439 -mcmodel= switch.
9440 (rs6000_legitimate_address_p): Delete TOC fusion support.
9441 (rs6000_opt_masks): Likewise.
9442 (fusion_wrap_memory_address): Delete function, no longer used.
9443 (fusion_split_address); Delete TOC fusion support.
9444 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
9445 longer used with toc fusion being deleted.
9446 (TARGET_TOC_FUSION_FP): Likewise.
9447 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
9448 UNSPEC.
9449 (toc fusion spliter): Delete TOC fusion support.
9450 (toc_fusionload_<mode>): Likewise.
9451 (toc_fusionload_di): Likewise.
9452 (fusion_gpr_load_<mode>): Delete generator function, this insn no
9453 longer needs to be named. Rename predicate to delete TOC fusion.
9454 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9455 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9456 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9457 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9458 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
9459
9460 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
9461
9462 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
9463 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
9464 __int128 in built-in function prototypes.
9465 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
9466 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
9467
9468 2018-07-27 Martin Sebor <msebor@redhat.com>
9469
9470 PR tree-optimization/86696
9471 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
9472 types, including enums.
9473 (handle_char_store): Be prepared for the above function to fail.
9474
9475 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
9476
9477 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
9478 when optimization level is lower than 2 or optimize for size.
9479
9480 2018-07-26 Martin Sebor <msebor@redhat.com>
9481
9482 PR tree-optimization/86043
9483 PR tree-optimization/86042
9484 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
9485 (get_string_cst_length): Rename...
9486 (get_min_string_length): ...to this. Add argument.
9487 (handle_char_store): Extend to handle multi-character stores by
9488 MEM_REF.
9489 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
9490 * tree.h (initializer_zerop): Add argument.
9491
9492 2018-07-26 Jakub Jelinek <jakub@redhat.com>
9493
9494 PR middle-end/86660
9495 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
9496 declare target to variables if they have always,{to,from,tofrom} map
9497 kinds.
9498
9499 2018-07-26 Martin Liska <mliska@suse.cz>
9500
9501 PR lto/86548
9502 * lto-wrapper.c: Add linker_output as prefix
9503 for ltrans_output_file.
9504
9505 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
9506
9507 PR rtl-optimization/85805
9508 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
9509 value for hard registers if that was written in the same mode.
9510
9511 2018-07-26 Martin Liska <mliska@suse.cz>
9512
9513 PR gcov-profile/86536
9514 * gcov.c (format_gcov): Use printf format %.*f directly
9515 and do not handle special values.
9516
9517 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9518
9519 * common/config/arc/arc-common.c (arc_option_optimization_table):
9520 Update default optimizations for size.
9521
9522 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9523
9524 * config/arc/arc.md (movsf_insn): Add short instruction selection.
9525 * config/arc/constraints.md (CfZ): New constraint.
9526 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
9527 (subsf3_fpu): Likewise.
9528 (cmpsf_fpu): Likewise.
9529 (cmpsf_fpu_uneq): Likewise.
9530
9531 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9532
9533 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
9534 accesses as well.
9535 (arc_is_uncached_mem_p): uncached applies to both the variable and
9536 the pointer.
9537
9538 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9539
9540 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
9541 register names.
9542
9543 2018-07-25 David Malcolm <dmalcolm@redhat.com>
9544
9545 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
9546 field "m_scopes" from vec to auto_vec.
9547
9548 2018-07-25 Martin Liska <mliska@suse.cz>
9549
9550 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
9551 return type.
9552
9553 2018-07-25 Richard Biener <rguenther@suse.de>
9554
9555 PR debug/86654
9556 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
9557 special wrt context_die late.
9558 (gen_subprogram_die): Re-use DIEs in local scope.
9559
9560 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
9561
9562 PR tree-optimization/86644
9563 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
9564
9565 2018-07-25 Martin Liska <mliska@suse.cz>
9566
9567 PR middle-end/86645
9568 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
9569 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
9570
9571 2018-07-25 Martin Liska <mliska@suse.cz>
9572
9573 PR sanitizer/79635
9574 * params.def: Explain ASan abbreviation and provide
9575 a documentation link.
9576
9577 2018-07-24 Martin Sebor <msebor@redhat.com>
9578
9579 PR tree-optimization/86622
9580 PR tree-optimization/86532
9581 * builtins.h (string_length): Declare.
9582 * builtins.c (c_strlen): Correct handling of non-constant offsets.
9583 (check_access): Be prepared for non-constant length ranges.
9584 (string_length): Make extern.
9585 * expr.c (string_constant): Only handle the minor non-constant
9586 array index. Use string_constant to compute the length of
9587 a generic string constant.
9588
9589 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
9590
9591 PR tree-optimization/86618
9592 * tree-vect-stmts.c (vectorizable_call): Don't take the address
9593 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
9594
9595 2018-07-24 David Malcolm <dmalcolm@redhat.com>
9596
9597 PR tree-optimization/86636
9598 * json.cc (json::object::set): Fix comment. Add assertions.
9599 (json::array::append): Move here from json.h. Add comment and an
9600 assertion.
9601 (json::string::string): Likewise.
9602 * json.h (json::array::append): Move to json.cc.
9603 (json::string::string): Likewise.
9604 * optinfo-emit-json.cc
9605 (optrecord_json_writer::impl_location_to_json): Assert that we
9606 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
9607 wrapper around it. Expand the location once, rather than three
9608 times.
9609 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
9610 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
9611 wrappers.
9612 (optrecord_json_writer::optinfo_to_json): Likewise, in four
9613 places. Fix some overlong lines.
9614
9615 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
9616
9617 * config/aarch64/aarch64-simd.md
9618 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
9619 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
9620 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
9621 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
9622 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
9623 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
9624 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
9625 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
9626 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
9627
9628 2018-07-24 Jakub Jelinek <jakub@redhat.com>
9629
9630 PR middle-end/86627
9631 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
9632 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
9633 and abs_d == d, do the power of two handling if profitable.
9634
9635 2018-07-24 Richard Biener <rguenther@suse.de>
9636
9637 * match.pd: Add BIT_FIELD_REF canonicalizations.
9638
9639 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9640
9641 PR c/86617
9642 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
9643
9644 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9645
9646 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
9647 terminated STRING_CST object.
9648
9649 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9650
9651 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
9652
9653 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9654
9655 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
9656 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
9657 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
9658 the elements into a register.
9659 (rs6000_split_v4si_init_di_reg): Delete.
9660 (rs6000_split_v4si_init): Delete.
9661 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
9662 (vsx_init_v4si): Rewrite as a define_expand.
9663
9664 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9665
9666 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
9667 zero_extend argument from memory): New.
9668
9669 2018-07-22 Martin Sebor <msebor@redhat.com>
9670
9671 PR bootstrap/86621
9672 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
9673 diagnosing calls with unknown arguments unless -Walloca-larger-than
9674 is restricted to less than PTRDIFF_MAX bytes.
9675
9676 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
9677
9678 * doc/gcov.texi (Invoking Gcov): Editorial changes.
9679
9680 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9681
9682 * pretty-print.c (text_info::set_location): Remove redundant
9683 "line_table" parameter from call to rich_location::set_range.
9684
9685 2018-07-20 Martin Sebor <msebor@redhat.com>
9686
9687 PR middle-end/82063
9688 * builtins.c (expand_builtin_alloca): Adjust.
9689 * calls.c (alloc_max_size): Simplify.
9690 * cgraphunit.c (cgraph_node::expand): Adjust.
9691 * common.opt (larger_than_size, warn_frame_larger_than): Remove
9692 variables.
9693 (frame_larger_than_size): Same.
9694 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
9695 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
9696 Initialize.
9697 * doc/invoke.texi (GCC Command Options): Document option arguments.
9698 Explain byte-size arguments and suffixes.
9699 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
9700 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
9701 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
9702 * doc/options.texi (UInteger): Expand.
9703 (Host_Wide_Int, ByteSize): Document new properties.
9704 * final.c (final_start_function_1): Include sizes in an error message.
9705 * function.c (frame_offset_overflow): Same.
9706 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
9707 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
9708 Diagnose unbounded alloca calls only for limits of less than
9709 PTRDIFF_MAX.
9710 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
9711 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
9712 for alloca(0).
9713 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
9714 only for limits of less than PTRDIFF_MAX.
9715 * langhooks-def.h (lhd_handle_option): Change function argument
9716 to HOST_WIDE_INT.
9717 * langhooks.c (lhd_handle_option): Same.
9718 * langhooks.h (handle_option): Same.
9719 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
9720 ByteSize flags.
9721 (var_type, var_type_struct): Same.
9722 (var_set): Handle ByteSize flag.
9723 * optc-gen.awk: Add comments to output to ease debugging. Make
9724 use of HOST_WIDE_INT where appropriate.
9725 * opts-gen-save.awk: Use %lx to format unsigned long.
9726 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
9727 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
9728 arguments. Parse bytes-size suffixes.
9729 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
9730 (enum_value_to_arg): Same.
9731 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
9732 (handle_option): Adjust.
9733 (generate_option): Change function argument to HOST_WIDE_INT.
9734 (cmdline_handle_error): Adjust.
9735 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
9736 (set_option): Change function argument to HOST_WIDE_INT.
9737 (option_enabled): Handle cl_host_wide_int.
9738 (get_option_state): Handle CLVC_SIZE.
9739 (control_warning_option): Same.
9740 * opts.c (common_handle_option): Change function argument to
9741 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
9742 OPT_Wvla_larger_than_.
9743 * opts.h (enum cl_var_type): Add an enumerator.
9744 * stor-layout.c (layout_decl): Print a more meaningful warning.
9745 * toplev.c (output_stack_usage): Adjust.
9746
9747 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
9748
9749 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
9750 call to inline_expand_builtin_string_cmp.
9751 (expand_builtin_strcmp): Likewise.
9752 (expand_builtin_strncmp): Likewise.
9753 (inline_string_cmp): Delete the last parameter, change char_type_node
9754 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
9755 two operands.
9756 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
9757 the inlining expansion on target where the type of the call has same or
9758 narrower precision than unsigned char.
9759
9760 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9761
9762 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
9763 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
9764 * common.opt (fsave-optimization-record): New option.
9765 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
9766 * doc/invoke.texi (-fsave-optimization-record): New option.
9767 * dumpfile.c: Include "optinfo-emit-json.h".
9768 (struct kv_pair): Move to coretypes.h.
9769 (optgroup_options): Make non-static.
9770 (dump_context::end_scope): Call
9771 optimization_records_maybe_pop_dump_scope.
9772 * dumpfile.h (optgroup_options): New decl.
9773 * json.cc: New file.
9774 * json.h: New file.
9775 * optinfo-emit-json.cc: New file.
9776 * optinfo-emit-json.h: New file.
9777 * optinfo.cc: Include "optinfo-emit-json.h".
9778 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
9779 (optinfo_enabled_p): Check optimization_records_enabled_p.
9780 (optinfo_wants_inlining_info_p): Likewise.
9781 * optinfo.h: Update comment.
9782 * profile-count.c (profile_quality_as_string): New function.
9783 * profile-count.h (profile_quality_as_string): New decl.
9784 (profile_count::quality): New accessor.
9785 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
9786 and optinfo_emit_json_cc_tests.
9787 * selftest.h (selftest::json_cc_tests): New decl.
9788 (selftest::optinfo_emit_json_cc_tests): New decl.
9789 * toplev.c: Include "optinfo-emit-json.h".
9790 (compile_file): Call optimization_records_finish.
9791 (do_compile): Call optimization_records_start.
9792 * tree-ssa-live.c: Include optinfo.h.
9793 (remove_unused_scope_block_p): Retain inlining information if
9794 optinfo_wants_inlining_info_p returns true.
9795
9796 2018-07-20 Richard Biener <rguenther@suse.de>
9797
9798 PR debug/86585
9799 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
9800 to cover -flto-partition=none.
9801
9802 2018-07-20 Martin Liska <mliska@suse.cz>
9803
9804 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
9805 (get_decl_source_range): Remove unused function.
9806
9807 2018-07-20 Richard Biener <rguenther@suse.de>
9808
9809 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
9810 (struct vn_phi_s): Likewise.
9811 (struct vn_reference_s): Likewise.
9812 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
9813 for searching the slot of an entry known to be in the hash itself.
9814 (vn_phi_hasher::equal): Likewise.
9815 (vn_reference_hasher::equal): Likewise.
9816 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
9817 globals.
9818 (optimistic_info, current_info): Remove, keeping only valid_info.
9819 (vn_reference_lookup_1): Remove fallback lookup.
9820 (vn_reference_lookup_2): Likewise.
9821 (vn_nary_op_lookup_1): Likewise.
9822 (vn_phi_lookup): Likewise.
9823 (vn_nary_build_or_lookup_1): Make sure to not chain the built
9824 hash element.
9825 (vn_reference_insert): Adjust, chain the inserted hash element
9826 at last_inserted_ref.
9827 (vn_reference_insert_pieces): Likewise.
9828 (visit_reference_op_call): Likewise.
9829 (vn_nary_op_insert_into): Chain the inserted hash element at
9830 last_inserted_nary.
9831 (vn_nary_op_insert_pieces): Adjust.
9832 (vn_nary_op_insert): Likewise.
9833 (vn_nary_op_insert_stmt): Likewise.
9834 (vn_phi_insert): Adjust, chain the inserted hash element at
9835 last_inserted_phi.
9836 (process_scc): Remove clearing and copying the optimistic
9837 table. Instead remove elements inserted during an optimistic
9838 iteration from the single table we maintain.
9839 (init_scc_vn): Adjust.
9840 (free_scc_vn): Likewise.
9841 (sccvn_dom_walker::record_cond): Likewise.
9842 (sccvn_dom_walker::after_dom_children): Likewise.
9843
9844 2018-07-19 Martin Sebor <msebor@redhat.com>
9845
9846 PR tree-optimization/84047
9847 PR tree-optimization/83776
9848 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
9849 (check_array_bounds): Call it.
9850
9851 2018-07-19 Martin Sebor <msebor@redhat.com>
9852
9853 * align.h (align_flags): Use member initialization.
9854
9855 2018-07-19 David Malcolm <dmalcolm@redhat.com>
9856
9857 * Makefile.in (OBJS): Add optinfo.o.
9858 * coretypes.h (class symtab_node): New forward decl.
9859 (struct cgraph_node): New forward decl.
9860 (class varpool_node): New forward decl.
9861 * dump-context.h: New file.
9862 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
9863 "tree-pass.h".
9864 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
9865 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
9866 (set_alt_dump_file): Likewise.
9867 (dump_context::~dump_context): New dtor.
9868 (dump_gimple_stmt): Move implementation to...
9869 (dump_context::dump_gimple_stmt): ...this new member function.
9870 Add the stmt to any pending optinfo, creating one if need be.
9871 (dump_gimple_stmt_loc): Move implementation to...
9872 (dump_context::dump_gimple_stmt_loc): ...this new member function.
9873 Start a new optinfo and add the stmt to it.
9874 (dump_gimple_expr): Move implementation to...
9875 (dump_context::dump_gimple_expr): ...this new member function.
9876 Add the stmt to any pending optinfo, creating one if need be.
9877 (dump_gimple_expr_loc): Move implementation to...
9878 (dump_context::dump_gimple_expr_loc): ...this new member function.
9879 Start a new optinfo and add the stmt to it.
9880 (dump_generic_expr): Move implementation to...
9881 (dump_context::dump_generic_expr): ...this new member function.
9882 Add the tree to any pending optinfo, creating one if need be.
9883 (dump_generic_expr_loc): Move implementation to...
9884 (dump_context::dump_generic_expr_loc): ...this new member
9885 function. Add the tree to any pending optinfo, creating one if
9886 need be.
9887 (dump_printf): Move implementation to...
9888 (dump_context::dump_printf_va): ...this new member function. Add
9889 the text to any pending optinfo, creating one if need be.
9890 (dump_printf_loc): Move implementation to...
9891 (dump_context::dump_printf_loc_va): ...this new member function.
9892 Start a new optinfo and add the stmt to it.
9893 (dump_dec): Move implementation to...
9894 (dump_context::dump_dec): ...this new member function. Add the
9895 value to any pending optinfo, creating one if need be.
9896 (dump_context::dump_symtab_node): New member function.
9897 (dump_context::get_scope_depth): New member function.
9898 (dump_context::begin_scope): New member function.
9899 (dump_context::end_scope): New member function.
9900 (dump_context::ensure_pending_optinfo): New member function.
9901 (dump_context::begin_next_optinfo): New member function.
9902 (dump_context::end_any_optinfo): New member function.
9903 (dump_context::s_current): New global.
9904 (dump_context::s_default): New global.
9905 (dump_scope_depth): Delete global.
9906 (dumpfile_ensure_any_optinfo_are_flushed): New function.
9907 (dump_symtab_node): New function.
9908 (get_dump_scope_depth): Reimplement in terms of dump_context.
9909 (dump_begin_scope): Likewise.
9910 (dump_end_scope): Likewise.
9911 (selftest::temp_dump_context::temp_dump_context): New ctor.
9912 (selftest::temp_dump_context::~temp_dump_context): New dtor.
9913 (selftest::verify_item): New function.
9914 (ASSERT_IS_TEXT): New macro.
9915 (ASSERT_IS_TREE): New macro.
9916 (ASSERT_IS_GIMPLE): New macro.
9917 (selftest::test_capture_of_dump_calls): New test.
9918 (selftest::dumpfile_c_tests): Call it.
9919 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
9920 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
9921 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
9922 descriptive comment.
9923 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
9924 (dump_node, dump_bb): Move these unrelated decls.
9925 (class dump_manager): Add leading comment.
9926 * optinfo.cc: New file.
9927 * optinfo.h: New file.
9928
9929 2018-07-19 Michael Collison <michael.collison@arm.com>
9930 Richard Henderson <rth@redhat.com>
9931
9932 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
9933 (subti): Handle op1 zero.
9934 (subvti4, usub4ti4): New.
9935 (*sub<GPI>3_compare1_imm): New.
9936 (sub<GPI>3_carryinCV): New.
9937 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
9938 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
9939
9940 2018-07-19 Michael Collison <michael.collison@arm.com>
9941 Richard Henderson <rth@redhat.com>
9942
9943 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
9944 (addti3): Create simpler code if low part is already known to be 0.
9945 (addvti4, uaddvti4): New.
9946 (*add<GPI>3_compareC_cconly_imm): New.
9947 (*add<GPI>3_compareC_cconly): New.
9948 (*add<GPI>3_compareC_imm): New.
9949 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
9950 handle constants within this pattern..
9951 (*add<GPI>3_compareV_cconly_imm): New.
9952 (*add<GPI>3_compareV_cconly): New.
9953 (*add<GPI>3_compareV_imm): New.
9954 (add<GPI>3_compareV): New.
9955 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
9956 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
9957 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
9958 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
9959 with 'comparison' operator.
9960 (*add<GPI>3_compareV_cconly_imm): Ditto.
9961 (*add<GPI>3_compareV_cconly): Ditto.
9962 (*add<GPI>3_compareV_imm): Ditto.
9963 (add<GPI>3_compareV): Ditto.
9964 (add<mode>3_carryinC): Ditto.
9965 (*add<mode>3_carryinC_zero): Ditto.
9966 (*add<mode>3_carryinC): Ditto.
9967 (add<mode>3_carryinV): Ditto.
9968 (*add<mode>3_carryinV_zero): Ditto.
9969 (*add<mode>3_carryinV): Ditto.
9970
9971 2018-07-19 Michael Collison <michael.collison@arm.com>
9972 Richard Henderson <rth@redhat.com>
9973
9974 * config/aarch64/aarch64-modes.def (CC_V): New.
9975 * config/aarch64/aarch64-protos.h
9976 (aarch64_addti_scratch_regs): Declare
9977 (aarch64_subvti_scratch_regs): Declare.
9978 (aarch64_expand_subvti): Declare.
9979 (aarch64_gen_unlikely_cbranch): Declare
9980 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
9981 for signed overflow using CC_Vmode.
9982 (aarch64_get_condition_code_1): Handle CC_Vmode.
9983 (aarch64_gen_unlikely_cbranch): New function.
9984 (aarch64_addti_scratch_regs): New function.
9985 (aarch64_subvti_scratch_regs): New function.
9986 (aarch64_expand_subvti): New function.
9987
9988 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9989
9990 * config/aarch64/aarch64-option-extensions.def: New entry for profile
9991 extension.
9992 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
9993 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
9994 extension.
9995
9996 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9997
9998 PR target/83009
9999 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
10000 address check not strict.
10001
10002 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
10003
10004 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
10005 Umq with Umn.
10006 (store_pair_lanes<mode>): Likewise.
10007 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
10008 enum value 'ADDR_QUERY_LDP_STP_N'.
10009 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
10010 (aarch64_print_address_internal): Add declaration.
10011 (aarch64_print_ldpstp_address): Remove.
10012 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
10013 (aarch64_print_operand): Change printing of 'y'.
10014 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
10015 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
10016 'true' rather than '1'.
10017 * config/aarch64/constraints.md (Uml): Likewise.
10018 (Uml): Rename to Umn.
10019 (Umq): Remove.
10020
10021 2018-07-19 Richard Biener <rguenther@suse.de>
10022
10023 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
10024 a trailing array.
10025 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
10026 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
10027 (vn_reference_hasher): Likewise.
10028 (struct vn_tables_s): Remove obstack and alloc-pool members.
10029 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
10030 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
10031 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
10032 (vn_reference_insert_pieces): Likewise.
10033 (alloc_vn_nary_op_noinit): Adjust.
10034 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
10035 (vn_phi_eq): Adjust.
10036 (shared_lookup_phiargs): Remove.
10037 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
10038 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
10039 (visit_reference_op_call): Likewise.
10040 (copy_nary, copy_phi, copy_reference): Remove.
10041 (process_scc): Rewind the obstack when iterating. Do not
10042 copy the elements to valid_info but just move them from one
10043 hashtable to the other.
10044 (allocate_vn_table): Adjust.
10045 (free_vn_table): Likewise.
10046 (init_scc_vn): Likewise.
10047 (free_scc_vn): Likewise.
10048
10049 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
10050
10051 PR target/86560
10052 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
10053 indirect_return as function type attribute.
10054 (ix86_attribute_table): Change indirect_return to function
10055 type attribute.
10056 * doc/extend.texi: Update indirect_return attribute.
10057
10058 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
10059
10060 * wide-int.h (widest2_int): New.
10061 * gimple-fold.c (arith_overflowed_p): Use it.
10062 * tree.h (widest2_int_cst): New.
10063 * tree-vrp.c (wide_int_binop_overflow): Rename from
10064 vrp_int_const_binop.
10065 Rewrite to work on trees.
10066 (extract_range_from_multiplicative_op_1): Abstract code to...
10067 (wide_int_range_min_max): ...here.
10068 (wide_int_range_cross_product): ...and here.
10069 (extract_range_from_binary_expr_1): Abstract overflow code to...
10070 (wide_int_range_mult_wrapping): ...here.
10071 * tree-vrp.h (wide_int_range_cross_product): New.
10072 (wide_int_range_mult_wrapping): New.
10073
10074 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
10075 Julia Koval <julia.koval@intel.com>
10076
10077 * config/i386/x86-tune-costs.h (skylake_memcpy,
10078 skylake_memset): Replace rep_prefix with unrolling for size 512.
10079
10080 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
10081
10082 PR middle-end/86544
10083 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
10084 comparision with EQ_EXPR in last stmt.
10085
10086 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
10087
10088 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
10089 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
10090 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
10091 previously known as "PowerPC AltiVec Built-in Functions". Move
10092 some material to new subsubsections "PowerPC AltiVec Built-in
10093 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
10094 ISA 2.07".
10095 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
10096 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
10097 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
10098 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
10099
10100 2018-07-18 Richard Biener <rguenther@suse.de>
10101
10102 PR tree-optimization/86557
10103 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
10104 EXACT_DIV_EXPR.
10105
10106 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
10107
10108 * config/s390/s390.c (s390_function_profiler): Generate CFI.
10109
10110 2018-07-17 Jeff Law <law@redhat.com>
10111
10112 * config/arm/arm.c (get_label_padding): Update for recent
10113 changes to label_to_alignment.
10114
10115 PR tree-optimization/86010
10116 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
10117
10118 * config/mips/mips.c (vr4130_align_insns): Update for recent
10119 changes to label_to_alignment.
10120
10121 * config/frv/frv.c (frv_label_align): Update for recent changes
10122 to label_to_alignment.
10123
10124 * config/nios2/nios2.c (nios2_label_align): Update for recent
10125 changes which dropped ALIGN_LABELS_LOG.
10126
10127 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
10128
10129 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
10130 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
10131
10132 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
10133
10134 * config/arc/arc.c (arc_label_align): Use align_labels instead of
10135 deprecated align_labels_log.
10136
10137 2018-07-17 Richard Biener <rguenther@suse.de>
10138
10139 PR lto/86456
10140 * dwarf2out.c (init_sections_and_labels): Always generate
10141 a debug_line_str_section for early LTO debug.
10142 (dwarf2out_finish): Reset debug_line_str_hash output early.
10143 Bump counter for extra dwarf5 .debug_loc labels to not conflict
10144 with fat LTO part.
10145 (dwarf2out_early_finish): Output debug_line_str.
10146
10147 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10148
10149 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
10150 index register on z196 or later.
10151
10152 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10153
10154 * config/s390/s390.c (s390_default_align): Set default function
10155 alignment to 16.
10156 (s390_override_options_after_change): Call s390_default align.
10157 (s390_option_override_internal): Call s390_default_align.
10158 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
10159
10160 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10161
10162 PR middle-end/86542
10163 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
10164 to _looptemp_ clauses, other than the first two.
10165
10166 2018-07-17 Martin Liska <mliska@suse.cz>
10167
10168 * opts.c: Do not enable OPT_falign_* for -Os.
10169
10170 2018-07-17 Martin Liska <mliska@suse.cz>
10171
10172 * align.h (MAX_CODE_ALIGN): New.
10173 (MAX_CODE_ALIGN_VALUE): New.
10174 * common/config/i386/i386-common.c (ix86_handle_option):
10175 (MAX_CODE_ALIGN): Moved to align.h.
10176 * final.c (MAX_CODE_ALIGN): Likewise.
10177 * opts.c (parse_and_check_align_values):
10178 (MAX_CODE_ALIGN): Likewise.
10179 (MAX_CODE_ALIGN_VALUE): Likewise.
10180
10181 2018-07-17 Martin Liska <mliska@suse.cz>
10182
10183 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
10184 in order to fulfil coding style.
10185 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
10186 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10187 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
10188 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
10189 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
10190 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
10191 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
10192 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
10193 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10194
10195 2018-07-17 Martin Liska <mliska@suse.cz>
10196
10197 * align.h: New file.
10198 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
10199 directly.
10200 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
10201 align_flags of label_to_alignment.
10202 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
10203 align_flags class.
10204 * config/m68k/m68k.c: Do not use removed align_labels_value and
10205 align_loops_value.
10206 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
10207 (LOOP_ALIGN): Likewise.
10208 (LABEL_ALIGN): Likewise.
10209 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10210 Remove not used macro.
10211 (rs6000_loop_align): Change return type to align_flags.
10212 (rs6000_loop_align_max_skip): Remove.
10213 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
10214 Change return type to align_flags.
10215 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10216 Remove not used macro.
10217 (rs6000_loop_align): Change return type to align_flags.
10218 (rs6000_loop_align_max_skip): Remove.
10219 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
10220 * config/rx/rx-protos.h (rx_align_for_label): Make it
10221 static function.
10222 * config/rx/rx.c (rx_align_for_label): Change return type
10223 to align_flags.
10224 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
10225 macro definitions.
10226 into align_flags class.
10227 (LABEL_ALIGN): Likewise.
10228 (LOOP_ALIGN): Likewise.
10229 * config/s390/s390.c (s390_label_align): Use align_flags
10230 class member.
10231 (s390_asm_output_function_label): Likewise.
10232 * config/sh/sh.c (sh_override_options_after_change):
10233 Use align_flags class directly without macros.
10234 (find_barrier): Likewise.
10235 (barrier_align): Likewise.
10236 (sh_loop_align): Likewise.
10237 * config/spu/spu.c (spu_option_override):
10238 Use align_flags_tuple::get_value instead of removed macros.
10239 (spu_sched_init): Likewise.
10240 * config/spu/spu.h (GTY): Likewise.
10241 * config/visium/visium.c (visium_option_override):
10242 Set "8" as default secondary alignment.
10243 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
10244 in order to guarantee secondary alignment of 8.
10245 * coretypes.h: Include align.h header file.
10246 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
10247 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
10248 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
10249 * doc/tm.texi.in: Likewise.
10250 * final.c (struct label_alignment): Remove not used structure.
10251 (LABEL_ALIGN): Change type to align_flags.
10252 (LOOP_ALIGN): Likewise.
10253 (JUMP_ALIGN): Likewise.
10254 (default_loop_align_max_skip): Remove.
10255 (default_label_align_max_skip): Likewise.
10256 (default_jump_align_max_skip): Likewise.
10257 (default_label_align_after_barrier_max_skip):
10258 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
10259 (LABEL_TO_MAX_SKIP): Remove.
10260 (label_to_alignment): Return align_flags type instead of integer.
10261 (label_to_max_skip): Remove.
10262 (align_fuzz): Use align_flags type.
10263 (compute_alignments): Use align_flags type and use align_flags::max
10264 to combine multiple alignments.
10265 (grow_label_align): Grow vec instead of C array.
10266 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
10267 (shorten_branches): Use align_flags type and use align_flags::max
10268 to combine multiple alignments.
10269 (final_scan_insn_1): Remove usage of secondary alignment that comes
10270 from label alignment, but instead use proper secondary alignment
10271 which is computed in grow_label_align.
10272 * flags.h (struct align_flags_tuple): Move to align.h.
10273 (struct align_flags): Likewise.
10274 (state_align_loops): Rename to align_loops.
10275 (state_align_jumps): Rename to align_jumps.
10276 (state_align_labels): Rename to align_labels.
10277 (state_align_functions): Rename to align_functions.
10278 (align_loops_log): Remove.
10279 (align_jumps_log): Remove.
10280 (align_labels_log): Remove.
10281 (align_functions_log): Remove.
10282 (align_loops_max_skip): Remove.
10283 (align_jumps_max_skip): Remove.
10284 (align_labels_max_skip): Remove.
10285 (align_functions_max_skip): Remove.
10286 (align_loops_value): Remove.
10287 (align_jumps_value): Remove.
10288 (align_labels_value): Remove.
10289 (align_functions_value): Remove.
10290 * output.h (label_to_alignment): Change return type to align_flags.
10291 (label_to_max_skip): Remove.
10292 * target.def: Remove loop_align_max_skip, label_align_max_skip,
10293 jump_align_max_skip macros.
10294 * targhooks.h (default_loop_align_max_skip): Remove.
10295 (default_label_align_max_skip): Likewise.
10296 (default_jump_align_max_skip): Likewise.
10297 (default_label_align_after_barrier_max_skip): Remove.
10298 * toplev.c (read_log_maxskip): Use ::normalize function.
10299 (parse_N_M): Remove not used argument and also call ::normalize.
10300 (parse_alignment_opts): Do not pass unused arguments.
10301 * varasm.c (assemble_start_function): Use directly align_functions
10302 instead of removed macros.
10303 * system.h: Do not poison removed macros.
10304
10305 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10306
10307 PR middle-end/86539
10308 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
10309 and cond temporaries don't have reference type if iterator has
10310 pointer type. For init use &for_pre_body instead of pre_p if
10311 for_pre_body is non-empty.
10312
10313 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10314
10315 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
10316 double-double modes to SFmode directly directly.
10317 (trunc<mode>sf2_fprs): Delete.
10318
10319 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10320
10321 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
10322 for conversions between IFmode and the decimal floating point modes.
10323 (init_float128_ieee): Use the correct names for conversions between
10324 KFmode and the decimal floating point modes.
10325
10326 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10327
10328 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
10329 for the conversions between TDmode and IFmode.
10330 (init_float128_ieee): Use more correct names for the conversions
10331 between TDmode and KFmode.
10332
10333 2018-07-16 Jakub Jelinek <jakub@redhat.com>
10334
10335 PR tree-optimization/86526
10336 * builtins.c (expand_builtin_memcmp): Formatting fixes.
10337 (inline_expand_builtin_string_cmp): Likewise.
10338 (inline_string_cmp): Likewise. Use c_readstr instead of
10339 builtin_memcpy_read_str. Add unit_mode temporary.
10340
10341 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
10342
10343 PR middle-end/86528
10344 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
10345 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
10346
10347 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
10348
10349 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
10350 Alphabetize prototypes of built-in functions, separating out
10351 built-in functions that are listed in this section but should be
10352 described elsewhere.
10353
10354 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
10355
10356 PR target/86511
10357 * expmed.c (emit_store_flag): Do not emit setcc followed by a
10358 conditional move when trapping comparison was split to a
10359 non-trapping one (and vice versa).
10360
10361 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10362
10363 * config/s390/s390.c (s390_function_profiler): Generate nops
10364 instead of profiler call sequences.
10365 * config/s390/s390.opt: Add the new option.
10366
10367 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10368
10369 * config/s390/s390.c (s390_function_profiler): Generate
10370 __mcount_loc section.
10371 * config/s390/s390.opt: Add the new option.
10372
10373 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10374
10375 * common.opt: Add the new warning.
10376 * config/s390/s390.c (s390_function_profiler): Emit "brasl
10377 %r0,__fentry__" when -mfentry is specified.
10378 (s390_option_override_internal): Disallow -mfentry for 31-bit
10379 CPUs.
10380 * config/s390/s390.opt: Add the new option.
10381
10382 2018-07-16 Richard Biener <rguenther@suse.de>
10383
10384 PR lto/86523
10385 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
10386 for function-local FUNCTION_DECL and RESULT_DECL immediately.
10387
10388 2018-07-16 Martin Liska <mliska@suse.cz>
10389
10390 PR ipa/86529
10391 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
10392 to ::get_create.
10393
10394 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10395
10396 * config/arc/arcHS.md: Update ARCHS scheduling rules.
10397
10398 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10399
10400 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
10401 for ARCHS4x.
10402 * config/arc/arc-cpus.def (hs4x): New cpu.
10403 (hs4xd): Likewise.
10404 * config/arc/arc-tables.opt: Regenerate.
10405 * config/arc/arc.c (arc_sched_issue_rate): New function.
10406 (TARGET_SCHED_ISSUE_RATE): Define.
10407 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
10408 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
10409 fpu_cvt.
10410 (attr tune): Add ARCHS4x tune values.
10411 (attr tune_dspmpy): Define.
10412 (*tst): Correct instruction type.
10413 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
10414 * config/arc/arcHS4x.md: New file.
10415 * config/arc/fpu.md: Update instruction type attributes.
10416 * config/arc/t-multilib: Regenerate.
10417
10418 2018-07-16 Tom de Vries <tdevries@suse.de>
10419
10420 PR debug/86455
10421 * var-tracking.c (vt_initialize): Fix pre_dec handling.
10422
10423 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10424
10425 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
10426 early clobber.
10427
10428 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
10429
10430 PR tree-optimization/86514
10431 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
10432 conversion to a boolean type from a type with greater precision.
10433
10434 2018-07-16 Tom de Vries <tdevries@suse.de>
10435
10436 * var-tracking.c (vt_initialize): Print adjusted insn slim if
10437 dump_flags request TDF_SLIM.
10438
10439 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
10440
10441 * fold-const.c (int_const_binop_1): Abstract...
10442 (wide_int_binop): ...wide int code here.
10443 (poly_int_binop): ...poly int code here.
10444 Abstract the rest of int_const_binop_1 into int_const_binop.
10445 * fold-const.h (wide_int_binop): New.
10446 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
10447 Remove useless PLUS/MINUS_EXPR case.
10448 (zero_nonzero_bits_from_vr): Move wide int code...
10449 (zero_nonzero_bits_from_bounds): ...here.
10450 (extract_range_from_binary_expr_1): Move mask optimization code...
10451 (range_easy_mask_min_max): ...here.
10452 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
10453 (range_easy_mask_min_max): New.
10454
10455 2018-07-15 Jeff Law <law@redhat.com>
10456
10457 PR target/85993
10458 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
10459 block.
10460
10461 2018-07-14 Jim Wilson <jimw@sifive.com>
10462
10463 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
10464
10465 2018-07-14 Paul Koning <ni1d@arrl.net>
10466
10467 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
10468
10469 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
10470
10471 * lto-streamer-out.c (copy_function_or_variable): Dump info about
10472 copying section.
10473
10474 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
10475 Steve Munroe <munroesj52@gmail.com>
10476
10477 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
10478 (_mm_andnot_si128): Likewise.
10479 (_mm_or_si128): Likewise.
10480 (_mm_xor_si128): Likewise.
10481
10482 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
10483
10484 PR middle-end/78809
10485 * builtins.c (expand_builtin_memcmp): Inline the calls first
10486 when result_eq is false.
10487 (expand_builtin_strcmp): Inline the calls first.
10488 (expand_builtin_strncmp): Likewise.
10489 (inline_string_cmp): New routine. Expand a string compare
10490 call by using a sequence of char comparison.
10491 (inline_expand_builtin_string_cmp): New routine. Inline expansion
10492 a call to str(n)cmp/memcmp.
10493 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
10494 New option.
10495 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
10496
10497 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
10498
10499 * config/arm/driver-arm.c: Include arm-native.h.
10500 (host_detect_local_cpu): Use auto-generated data tables.
10501 (vendors, arm_cpu_table): Delete. Move part information to ...
10502 * config/arm/arm-cpus.in: ... here.
10503 * config/arm/parsecpu.awk (gen_native): New function.
10504 (vendor, part): New CPU fields.
10505 (END): Add support for building the native CPU detection tables.
10506 * config/arm/t-arm (arm-native.h): Add build rule.
10507 (driver-arm.o): Add dependency on arm-native.h.
10508
10509 2018-07-13 Richard Biener <rguenther@suse.de>
10510
10511 PR middle-end/85974
10512 * match.pd (addr1 - addr2): Allow either of the operand to
10513 have a conversion.
10514
10515 2018-07-13 Tom de Vries <tdevries@suse.de>
10516
10517 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
10518 in remap_ssa_name.
10519
10520 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
10521
10522 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
10523 arrays instead of numbered variables.
10524
10525 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
10526
10527 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
10528 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
10529
10530 2018-07-13 Richard Biener <rguenther@suse.de>
10531
10532 PR debug/86452
10533 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
10534 instead of get_context_die.
10535
10536 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
10537 Richard Biener <rguenther@suse.de>
10538
10539 PR middle-end/86489
10540 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
10541 that the loop latch destination where phi is defined.
10542
10543 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
10544
10545 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
10546 (riscv_expand_epilogue): Add assertion to check interrupt mode.
10547 (riscv_set_current_function): Extract getting interrupt type to new
10548 function.
10549 (riscv_get_interrupt_type): New function.
10550 (riscv_merge_decl_attributes): New function, checking interrupt type is
10551 same.
10552 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
10553
10554 2018-07-12 Paul Koning <ni1d@arrl.net>
10555
10556 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
10557 directive.
10558
10559 2018-07-12 Paul Koning <ni1d@arrl.net>
10560
10561 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
10562 zero reference, add doloop_end instead.
10563 * doc/md.texi (decrement_and_branch_until_zero): Remove.
10564 (Looping patterns): Remove decrement_and_branch_until_zero. Add
10565 detail for doloop_end.
10566
10567 2018-07-12 Martin Sebor <msebor@redhat.com>
10568
10569 PR c/86453
10570 * attribs.c (decl_attributes): Reject conflicting attributes before
10571 calling attribute handlers.
10572
10573 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10574
10575 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
10576 parameter.
10577 (gcc::dump_manager::get_dump_file_name): likewise.
10578 (dump_begin): Likewise.
10579 * dumpfile.h (dump_begin): Update prototype.
10580 (gcc::dump_manager::get_dump_file_name,
10581 gcc::dump_manager::get_dump_file_name): Update prototype.
10582
10583 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10584
10585 * internal-fn.h (vectorizable_internal_fn_p): New function.
10586 * tree-vect-slp.c (compatible_calls_p): Likewise.
10587 (vect_build_slp_tree_1): Remove nops argument. Handle calls
10588 to internal functions.
10589 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
10590
10591 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10592
10593 * fold-const.h (inverse_conditions_p): Declare.
10594 * fold-const.c (inverse_conditions_p): New function.
10595 * match.pd: Use inverse_conditions_p. Add folds of view_converts
10596 that test the inverse condition of a conditional internal function.
10597 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
10598 * internal-fn.c (internal_fn_mask_index): Handle conditional
10599 internal functions.
10600 (vectorized_internal_fn_supported_p): New function.
10601 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
10602 (any_pred_load_store): Replace with...
10603 (need_to_predicate): ...this new variable.
10604 (redundant_ssa_names): New variable.
10605 (ifcvt_can_use_mask_load_store): Move initial checks to...
10606 (ifcvt_can_predicate): ...this new function. Handle tree codes
10607 for which a conditional internal function exists.
10608 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
10609 instead of ifcvt_can_use_mask_load_store. Update after variable
10610 name change.
10611 (predicate_load_or_store): New function, split out from
10612 predicate_mem_writes.
10613 (check_redundant_cond_expr): New function.
10614 (value_available_p): Likewise.
10615 (predicate_rhs_code): Likewise.
10616 (predicate_mem_writes): Rename to...
10617 (predicate_statements): ...this. Use predicate_load_or_store
10618 and predicate_rhs_code.
10619 (combine_blocks, tree_if_conversion): Update after above name changes.
10620 (ifcvt_local_dce): Handle redundant_ssa_names.
10621 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
10622 general conditional functions.
10623 * tree-vect-stmts.c (vectorizable_call): Likewise.
10624
10625 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10626 Alan Hayward <alan.hayward@arm.com>
10627 David Sherwood <david.sherwood@arm.com>
10628
10629 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
10630 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
10631 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
10632 plus and minus and convert them into IFN_COND_FMA-based sequences.
10633 (convert_mult_to_fma): Handle conditional plus and minus.
10634
10635 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10636
10637 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
10638 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
10639 (cond_fnms_optab): New optabs.
10640 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
10641 internal functions.
10642 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
10643 * internal-fn.h (get_conditional_internal_fn): Declare.
10644 (get_unconditional_internal_fn): Likewise.
10645 * internal-fn.c (cond_ternary_direct): New macro.
10646 (expand_cond_ternary_optab_fn): Likewise.
10647 (direct_cond_ternary_optab_supported_p): Likewise.
10648 (FOR_EACH_COND_FN_PAIR): Likewise.
10649 (get_conditional_internal_fn): New function.
10650 (get_unconditional_internal_fn): Likewise.
10651 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
10652 (gimple_match_op::gimple_match_op): Add a new overload for 5
10653 operands.
10654 (gimple_match_op::set_op): Likewise.
10655 (gimple_resimplify5): Declare.
10656 * genmatch.c (decision_tree::gen): Generate simplifications for
10657 5 operands.
10658 * gimple-match-head.c (gimple_simplify): Define an overload for
10659 5 operands. Handle calls with 5 arguments in the top-level overload.
10660 (convert_conditional_op): Handle conversions from unconditional
10661 internal functions to conditional ones.
10662 (gimple_resimplify5): New function.
10663 (build_call_internal): Pass a fifth operand.
10664 (maybe_push_res_to_seq): Likewise.
10665 (try_conditional_simplification): Try converting conditional
10666 internal functions to unconditional internal functions.
10667 Handle 3-operand unconditional forms.
10668 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
10669 Define ternary equivalents of the current rules for binary conditional
10670 internal functions.
10671 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
10672 ternary operations.
10673 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
10674 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
10675 (optab): Handle them.
10676 (SVE_COND_FP_TERNARY): New int iterator.
10677 (sve_fmla_op, sve_fmad_op): New int attributes.
10678 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
10679 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
10680 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
10681
10682 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10683
10684 * target.def (preferred_else_value): New target hook.
10685 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
10686 * doc/tm.texi: Regenerate.
10687 * targhooks.h (default_preferred_else_value): Declare.
10688 * targhooks.c (default_preferred_else_value): New function.
10689 * internal-fn.h (conditional_internal_fn_code): Declare.
10690 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
10691 (get_conditional_internal_fn): Use it.
10692 (conditional_internal_fn_code): New function.
10693 * gimple-match.h (gimple_match_cond): New struct.
10694 (gimple_match_op): Add a cond member function.
10695 (gimple_match_op::gimple_match_op): Update all forms to take a
10696 gimple_match_cond.
10697 * genmatch.c (expr::gen_transform): Use the same condition as res_op
10698 for the suboperation, but don't specify a particular else_value.
10699 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
10700 (visit_nary_op, visit_reference_op_load): Pass
10701 gimple_match_cond::UNCOND to the gimple_match_op constructor.
10702 * gimple-match-head.c: Include tree-eh.h
10703 (convert_conditional_op): New function.
10704 (maybe_resimplify_conditional_op): Likewise.
10705 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
10706 (gimple_resimplify2): Likewise.
10707 (gimple_resimplify3): Likewise.
10708 (gimple_resimplify4): Likewise.
10709 (maybe_push_res_to_seq): Return null for conditional operations.
10710 (try_conditional_simplification): New function.
10711 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
10712 constructor.
10713 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
10714 IFN_COND_* call.
10715 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
10716 function.
10717 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
10718
10719 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10720
10721 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
10722 DECL_FCONTEXT
10723 (hash_tree): Do not hash DECL_FCONTEXT
10724 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
10725 Do not stream DECL_FCONTEXT.
10726 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
10727 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
10728
10729 2018-07-12 Richard Biener <rguenther@suse.de>
10730
10731 PR debug/86462
10732 * dwarf2out.c (gen_block_die): Only output blocks when they have
10733 at least one !DECL_IGNORED_P variable.
10734
10735 2018-07-12 Richard Biener <rguenther@suse.de>
10736
10737 PR target/84829
10738 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
10739 Remove -mieee-fp handling.
10740
10741 2018-07-12 Richard Biener <rguenther@suse.de>
10742
10743 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
10744 left-over from last patch.
10745
10746 2018-07-12 Jakub Jelinek <jakub@redhat.com>
10747
10748 PR tree-optimization/86492
10749 * gimple-ssa-store-merging.c
10750 (imm_store_chain_info::coalesce_immediate_stores): Call
10751 check_no_overlap even for the merge_overlapping case. Formatting fix.
10752
10753 2018-07-12 Richard Biener <rguenther@suse.de>
10754
10755 PR middle-end/86479
10756 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
10757 move possibly trapping operations into the conditional.
10758
10759 2018-07-12 Richard Biener <rguenther@suse.de>
10760
10761 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
10762 (vn_lookup_simplify_result): Remove recursion limit applied
10763 here.
10764 (vn_nary_build_or_lookup_1): Adjust.
10765 (try_to_simplify): Likewise.
10766 * gimple-match-head.c (gimple_resimplify1): Instead apply one
10767 here.
10768 (gimple_resimplify2): Likewise.
10769 (gimple_resimplify3): Likewise.
10770 (gimple_resimplify4): Likewise.
10771
10772 2018-07-11 Jakub Jelinek <jakub@redhat.com>
10773
10774 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
10775 Use __mmask64 type instead of __mmask8 for __M argument.
10776 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
10777 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
10778 __U argument.
10779 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
10780 __mmask16 for __M argument.
10781 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
10782 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
10783 to __mmask16 instead of __mmask8.
10784 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
10785 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
10786 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
10787 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
10788 instead of __mmask16 for __U argument.
10789 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
10790 __mmask16 instead of __mmask8 for __U argument.
10791 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
10792 __U argument.
10793 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
10794 __mmask16.
10795 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
10796 argument.
10797 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
10798 __U argument.
10799 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
10800 __mmask16.
10801 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
10802 of __mmask16.
10803 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
10804 __U argument.
10805 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
10806 __U argument.
10807 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
10808 __U argument.
10809 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
10810 __U argument.
10811 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
10812 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
10813 return type as well as __M argument type and all casts from __mmask8
10814 to __mmask32.
10815 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
10816 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
10817 return type as well as __M argument type and all casts from __mmask8
10818 to __mmask16.
10819 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
10820 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
10821 return type as well as __M argument type and all casts from __mmask8
10822 to __mmask32.
10823 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
10824 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
10825 return type as well as __M argument type and all casts from __mmask8
10826 to __mmask16.
10827 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
10828 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
10829 __mmask16.
10830
10831 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
10832
10833 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
10834 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
10835 for __U argument.
10836
10837 2018-07-11 Paul Koning <ni1d@arrl.net>
10838
10839 * doc/md.texi (define_subst): Document how multiple occurrences of
10840 the same argument in the replacement pattern are handled.
10841
10842 2018-07-11 Paul Koning <ni1d@arrl.net>
10843
10844 * doc/extend.texi (Common Variable Attributes): Move "mode" into
10845 alphabetical order.
10846 (Common Type Attributes): Add "mode" attribute.
10847
10848 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
10849
10850 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
10851 stream DECL_ORIGINAL_TYPE.
10852 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
10853 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
10854 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
10855 Do not walk original type.
10856 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
10857 external decls.
10858 (write_ts_decl_non_common_tree_pointers): Do not stream
10859 DECL_ORIGINAL_TYPE
10860 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
10861 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
10862
10863 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10864
10865 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
10866 thread twice from the same starting edge.
10867
10868 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10869
10870 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
10871 * gimple.c (gimple_call_nonnull_result_p): ...here...
10872 (gimple_call_nonnull_arg): ...and here.
10873 * gimple.h (gimple_call_nonnull_result_p): New.
10874 (gimple_call_nonnull_arg): New.
10875
10876 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
10877
10878 * config/arm/arm-cpus.in: Move information from fpu field of each
10879 cpu definition to the isa field.
10880 * config/arm/parsecpu.awk (fpu): Delete match rule.
10881 (gen_comm_data): Don't add bits from the CPU's FPU entry.
10882
10883 2018-07-11 Richard Biener <rguenther@suse.de>
10884
10885 PR debug/86457
10886 * dwarf2out.c (init_sections_and_labels): Use
10887 output_asm_line_debug_info consistently.
10888 (dwarf2out_early_finish): Likewise.
10889 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
10890 type units.
10891
10892 2018-07-11 Richard Biener <rguenther@suse.de>
10893
10894 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
10895 Rework father_bb setting in a way to avoid propagating constants
10896 multiple times on a loop body.
10897
10898 2018-07-10 Mark Wielaard <mark@klomp.org>
10899
10900 PR debug/86459
10901 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
10902
10903 2018-07-10 Richard Biener <rguenther@suse.de>
10904
10905 * hash-map.h (hash_map::iterator::operator*): Return
10906 references to key and value.
10907
10908 2018-07-10 Jakub Jelinek <jakub@redhat.com>
10909
10910 PR c++/86443
10911 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
10912 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
10913 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
10914 (gimplify_omp_for): For composite loops, move outer
10915 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
10916 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
10917 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
10918 TREE_LIST for both the original class iterator and the "last" helper
10919 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
10920 loop, remember has_decl_expr from outer composite loops for the
10921 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
10922
10923 2018-07-09 Martin Sebor <msebor@redhat.com>
10924
10925 PR middle-end/77357
10926 PR middle-end/86428
10927 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
10928 accessing implicitly initialized array elements.
10929 * expr.c (string_constant): Handle string initializers of
10930 character arrays within aggregates.
10931 * gimple-fold.c (fold_array_ctor_reference): Add argument.
10932 Store element offset. As a special case, handle zero size.
10933 (fold_nonarray_ctor_reference): Same.
10934 (fold_ctor_reference): Add argument. Store subobject offset.
10935 * gimple-fold.h (fold_ctor_reference): Add argument.
10936
10937 2018-07-09 Paul Koning <ni1d@arrl.net>
10938
10939 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
10940 (pdp11_insn_cost): New function.
10941 (pdp11_md_asm_adjust): New function.
10942 (TARGET_INVALID_WITHIN_DOLOOP): Define.
10943 (pdp11_rtx_costs): Update to match machine better.
10944 (output_addr_const_pdp11): Correct format mismatch warnings.
10945 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
10946 * config/pdp11/pdp11.md: General change to add base_cost and/or
10947 length attributes for use by new pdp11_insn_cost function.
10948 (MIN_BRANCH): Correct definition.
10949 (MIN_SOB): Ditto.
10950 (doloop_end): Use standard pattern name for looping pattern.
10951 (doloop_end_nocc): New.
10952 (movsf): Add another constraint alternative.
10953 (zero_extendqihi2): Add constraint alternatives for not in place
10954 extend.
10955 (zero_extendhisi2): Remove.
10956 (shift patterns): Add CC handling variants.
10957 (bswaphi2): New.
10958 (bswapsi2): New.
10959 (rothi3): New.
10960 (define_peephole2): New peephole to recognize mov that sets CC for
10961 subsequent test.
10962
10963 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10964
10965 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
10966 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
10967 wi::add.
10968
10969 2018-07-09 Jakub Jelinek <jakub@redhat.com>
10970
10971 PR c/86420
10972 * real.c (real_nextafter): Return true if result is denormal.
10973
10974 2018-07-09 Martin Liska <mliska@suse.cz>
10975
10976 * common.opt: Add back wrongly removed attribute.
10977
10978 2018-07-09 Richard Biener <rguenther@suse.de>
10979
10980 PR debug/86413
10981 * dwarf2out.c (gen_block_die): For an early generated DIE
10982 always output high/low PC attributes.
10983
10984 2018-07-09 Tom de Vries <tdevries@suse.de>
10985
10986 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
10987 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
10988 onto VAR_DECL with abstract origin.
10989
10990 2018-07-07 Jim Wilson <jimw@sifive.com>
10991
10992 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
10993
10994 2018-07-07 Tom de Vries <tdevries@suse.de>
10995
10996 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
10997
10998 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
10999
11000 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
11001 overflow_type.
11002 (combine_bound): Use wide-int overflow calculation instead of
11003 rolling our own.
11004 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
11005 overflow_type.
11006 * fold-const.c (int_const_binop_2): Same.
11007 (extract_muldiv_1): Same.
11008 (fold_div_compare): Same.
11009 (fold_abs_const): Same.
11010 * match.pd: Same.
11011 * poly-int.h (add): Same.
11012 (sub): Same.
11013 (neg): Same.
11014 (mul): Same.
11015 * predict.c (predict_iv_comparison): Same.
11016 * profile-count.c (slow_safe_scale_64bit): Same.
11017 * simplify-rtx.c (simplify_const_binary_operation): Same.
11018 * tree-chrec.c (tree_fold_binomial): Same.
11019 * tree-data-ref.c (split_constant_offset_1): Same.
11020 * tree-if-conv.c (idx_within_array_bound): Same.
11021 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
11022 * tree-ssa-phiopt.c (minmax_replacement): Same.
11023 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
11024 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
11025 * vr-values.c (vr_values::adjust_range_with_scev): Same.
11026 * wide-int.cc (wi::add_large): Same.
11027 (wi::mul_internal): Same.
11028 (wi::sub_large): Same.
11029 (wi::divmod_internal): Same.
11030 * wide-int.h: Change overflow type to overflow_type for neg, add,
11031 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
11032 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
11033 mul_internal, divmod_internal.
11034 (overflow_type): New enum.
11035 (accumulate_overflow): New.
11036
11037 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
11038
11039 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
11040 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
11041
11042 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
11043
11044 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
11045 argument is checked for zero before entering loop, avoid checking again.
11046
11047 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
11048
11049 * gimplify.h (generic_expr_could_trap_p): Set as global function.
11050 * gimplify.h (generic_expr_could_trap_p): Likwise.
11051 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
11052
11053 2018-07-06 Jakub Jelinek <jakub@redhat.com>
11054
11055 PR tree-optimization/86401
11056 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
11057 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
11058 (fold_bit_and_mask): ... here. New helper function for match.pd.
11059 * fold-const.h (fold_bit_and_mask): Declare.
11060 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
11061
11062 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
11063
11064 PR target/86324
11065 * target.def (translate_mode_attribute): New hook.
11066 * targhooks.h (default_translate_mode_attribute): Declare.
11067 * targhooks.c (default_translate_mode_attribute): New function.
11068 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
11069 * doc/tm.texi: Regenerate.
11070 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
11071 (rs6000_translate_mode_attribute): New function.
11072
11073 2018-07-06 Paul Koning <ni1d@arrl.net>
11074
11075 * doc/md.texi (define_split): Document DONE and FAIL.
11076 (define_peephole2): Ditto.
11077
11078 2018-07-05 Jeff Law <law@redhat.com>
11079
11080 PR tree-optimization/86010
11081 * tree-ssa-dse.c (compute_trims): More aggressively trim at
11082 both the head and tail of mem* and str* calls.
11083
11084 2018-07-05 Jim Wilson <jimw@sifive.com>
11085
11086 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
11087
11088 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
11089
11090 * config/aarch64/aarch64-simd.md: correct flags text for
11091 MIN_EXPR replacement.
11092
11093 2018-07-05 James Clarke <jrtc27@jrtc27.com>
11094
11095 * configure: Regenerated.
11096
11097 2018-07-05 Carl Love <cel@us.ibm.com>
11098
11099 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
11100 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
11101 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
11102 VSX_BUILTIN_DOUBLEL_V4SF.
11103
11104 2018-07-05 Martin Sebor <msebor@redhat.com>
11105
11106 PR c++/86400
11107 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
11108 than its domain to compute its the upper bound of a char array.
11109
11110 2018-07-05 Nathan Sidwell <nathan@acm.org>
11111
11112 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
11113 * doc/cpp.texi: Update comment.
11114 * doc/tm.texi: Rebuilt.
11115 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
11116 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
11117 * doc/extend.texi (Backwards Compatibility): Clarify it is system
11118 headers affected by extern "C".
11119 * system.h: Poison NO_IMPLICIT_EXTERN_C.
11120 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
11121 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
11122 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
11123 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
11124 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
11125 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
11126 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
11127 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
11128 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
11129 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
11130 config/sparc/sp64-elf.h, config/spu/spu.h,
11131 config/stormy16/stormy16.h, config/v850/v850.h,
11132 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
11133 define NO_IMPLICIT_EXTERN_C.
11134 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
11135
11136 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11137
11138 PR target/84711
11139 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
11140 instead of GET_MODE_SIZE when comparing Units.
11141
11142 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11143
11144 PR target/84711
11145 * rtlanal.c (set_noop_p): Constrain on mode change,
11146 include hard-reg-set.h
11147
11148 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11149
11150 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
11151
11152 2018-07-05 Jakub Jelinek <jakub@redhat.com>
11153
11154 Revert
11155 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11156
11157 PR sanitizer/84250
11158 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11159 libasan.
11160 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11161
11162 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11163
11164 PR sanitizer/84250
11165 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11166 libasan.
11167 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11168
11169 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
11170
11171 PR middle-end/86380
11172 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
11173
11174 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
11175
11176 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
11177 neg_*_op* variables.
11178
11179 2018-07-04 Martin Liska <mliska@suse.cz>
11180
11181 * tree-switch-conversion.c: Define
11182 max_ratio_for_speed and max_ratio_for_size constants.
11183
11184 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11185 Martin Liska <mliska@suse.cz>
11186
11187 PR middle-end/66240
11188 PR target/45996
11189 PR c/84100
11190 * common.opt: Rename align options with 'str_' prefix.
11191 * common/config/i386/i386-common.c (set_malign_value): New
11192 function.
11193 (ix86_handle_option): Use it to set -falign-* options/
11194 * config/aarch64/aarch64-protos.h (struct tune_params): Change
11195 type from int to string.
11196 * config/aarch64/aarch64.c: Update default values from int
11197 to string.
11198 * config/alpha/alpha.c (alpha_override_options_after_change):
11199 Likewise.
11200 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
11201 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11202 max skip conditionally.
11203 * config/i386/freebsd.h (SUBALIGN_LOG): New.
11204 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11205 max skip conditionally.
11206 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11207 max skip conditionally.
11208 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
11209 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11210 max skip conditionally.
11211 * config/i386/i386.c (struct ptt): Change type from int to
11212 string.
11213 (ix86_default_align): Set default values.
11214 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
11215 max skip conditionally.
11216 * config/i386/iamcu.h (SUBALIGN_LOG): New.
11217 (ASM_OUTPUT_MAX_SKIP_ALIGN):
11218 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
11219 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11220 max skip conditionally.
11221 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
11222 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
11223 * config/i386/x86-64.h (SUBALIGN_LOG): New.
11224 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11225 max skip conditionally.
11226 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11227 * config/ia64/ia64.c (ia64_option_override): Set default values
11228 for alignment options.
11229 * config/m68k/m68k.c: Handle new str_align_* options.
11230 * config/mips/mips.c (mips_set_compression_mode): Change
11231 type of constants.
11232 (mips_option_override): Set default values for options.
11233 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
11234 Likewise.
11235 * config/rs6000/rs6000.c (rs6000_option_override_internal):
11236 Likewise.
11237 * config/rx/rx.c (rx_option_override): Likewise.
11238 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
11239 (LABEL_ALIGN): Use align_labels_log.
11240 (LOOP_ALIGN): Use align_loops_align.
11241 * config/s390/s390.c (s390_asm_output_function_label): Use new
11242 macros.
11243 * config/sh/sh.c (sh_override_options_after_change):
11244 Change type of constants.
11245 * config/spu/spu.c (spu_sched_init): Likewise.
11246 * config/sparc/sparc.c (sparc_option_override): Set default
11247 values for options.
11248 * config/visium/visium.c (visium_option_override): Likewise.
11249 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
11250 emit p2align format with last argument if it's not needed.
11251 * doc/invoke.texi: Document extended format of -falign-*.
11252 * final.c: Use align_labels alignment.
11253 * flags.h (struct target_flag_state): Change type to use
11254 align_flags.
11255 (struct align_flags_tuple): New.
11256 (struct align_flags): Likewise.
11257 (align_loops_log): Redefine macro to use new types.
11258 (align_loops_max_skip): Redefine macro to use new types.
11259 (align_jumps_log): Redefine macro to use new types.
11260 (align_jumps_max_skip): Redefine macro to use new types.
11261 (align_labels_log): Redefine macro to use new types.
11262 (align_labels_max_skip): Redefine macro to use new types.
11263 (align_functions_log): Redefine macro to use new types.
11264 (align_loops): Redefine macro to use new types.
11265 (align_jumps): Redefine macro to use new types.
11266 (align_labels): Redefine macro to use new types.
11267 (align_functions): Redefine macro to use new types.
11268 (align_functions_max_skip): Redefine macro to use new types.
11269 (align_loops_value): New macro.
11270 (align_jumps_value): New macro.
11271 (align_labels_value): New macro.
11272 (align_functions_value): New macro.
11273 * function.c (invoke_set_current_function_hook): Propagate
11274 alignment values from flags to global variables default in
11275 topleev.h.
11276 * ipa-icf.c (sem_function::equals_wpa): Use
11277 cl_optimization_option_eq instead of memcmp.
11278 * lto-streamer.h (cl_optimization_stream_out): Support streaming
11279 of string types.
11280 (cl_optimization_stream_in): Likewise.
11281 * optc-save-gen.awk: Support strings in cl_optimization.
11282 * opth-gen.awk: Likewise.
11283 * opts.c (finish_options): Remove error checking of invalid
11284 value ranges.
11285 (MAX_CODE_ALIGN): Remove.
11286 (MAX_CODE_ALIGN_VALUE): Likewise.
11287 (parse_and_check_align_values): New function.
11288 (check_alignment_argument): Likewise.
11289 (common_handle_option): Use check_alignment_argument.
11290 * opts.h (parse_and_check_align_values): Declare.
11291 * toplev.c (init_alignments): Remove.
11292 (read_log_maxskip): New.
11293 (parse_N_M): Likewise.
11294 (parse_alignment_opts): Likewise.
11295 (backend_init_target): Remove usage of init_alignments.
11296 * toplev.h (parse_alignment_opts): Declare.
11297 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
11298 argument.
11299 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
11300 * tree.c (cl_option_hasher::equal): New.
11301 * varasm.c: Use new global macros.
11302
11303 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11304
11305 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
11306 Use a simpler align directive also if MAXSKIP = ALIGN-1.
11307 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11308 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11309 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11310 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11311 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
11312 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
11313 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
11314 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11315 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11316 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11317 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11318
11319 2018-07-04 Martin Liska <mliska@suse.cz>
11320 Jonathan Wakely <jwakely@redhat.com>
11321
11322 * coverage.c: Use correct type.
11323 * doc/invoke.texi: Language correction.
11324
11325 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
11326
11327 PR target/85620
11328 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
11329 ENDBRANCH for non-tail call which may return via indirect branch.
11330 * doc/extend.texi: Document indirect_return attribute.
11331
11332 2018-07-03 Martin Sebor <msebor@redhat.com>
11333
11334 PR tree-optimization/86274
11335 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
11336 precondition.
11337 (format_floating): Correct handling of infinities and NaNs.
11338
11339 2018-07-03 Martin Sebor <msebor@redhat.com>
11340
11341 * print-tree.c (print_real_cst): New function.
11342 (print_node_brief): Call it.
11343 (print_node): Ditto.
11344
11345 2018-07-03 Jeff Law <law@redhat.com>
11346
11347 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
11348 into a single pattern.
11349
11350 * config/h8300/h8300.md (ors code_iterator): New.
11351 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
11352 a single pattern and single splitter.
11353 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
11354 (iorqi3_1, xorqi3_1): Likewise.
11355 (iorqi3, xorqi3 expanders): Similarly.
11356
11357 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
11358 (movmd_internal) into a single pattern using the P mode iterator.
11359 (movmd splitters): Similarly.
11360 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
11361 (movsd splitters): Similarly.
11362
11363 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
11364 ADDB, ADDW and ADDL into a single ADD attribute which selects the
11365 right table based on the size of the operand.
11366 * config/h8300/h8300.md (length_table): Corresponding changes. All
11367 references to "addb", "addw" and "addl" changed to "add".
11368 (btst patterns): Merge two variants into a single pattern.
11369 (tstqi, tsthi): Likewise.
11370 (addhi3_incdec, addsi3_incdec): Likewise.
11371 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
11372 (mulhi3, mulsi3): Likewise.
11373 (udivhi3, udivsi3): Likewise.
11374 (divhi3, divsi3): Likewise.
11375 (andorqi3, andorhi3, andorsi3): Likewise.
11376
11377 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
11378
11379 PR target/85694
11380 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
11381 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
11382
11383 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11384
11385 PR tree-optimization/85694
11386 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
11387 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
11388 UNSPEC_URHADD.
11389 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
11390 (<u>avg<mode>3_ceil): New patterns.
11391
11392 2018-07-03 David Malcolm <dmalcolm@redhat.com>
11393
11394 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
11395 scan-tree-dump directive.
11396 * gcc.dg/vect/slp-perm-2.c: Likewise.
11397 * gcc.dg/vect/slp-perm-3.c: Likewise.
11398 * gcc.dg/vect/slp-perm-5.c: Likewise.
11399 * gcc.dg/vect/slp-perm-6.c: Likewise.
11400 * gcc.dg/vect/slp-perm-7.c: Likewise.
11401 * gcc.dg/vect/slp-perm-8.c: Likewise.
11402
11403 2018-07-03 Marek Polacek <polacek@redhat.com>
11404
11405 PR middle-end/86202
11406 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
11407
11408 2018-07-03 Richard Biener <rguenther@suse.de>
11409
11410 PR ipa/86389
11411 * tree-ssa-structalias.c (find_func_clobbers): Properly
11412 handle indirect calls.
11413
11414 2018-07-03 Jeff Law <law@redhat.com>
11415
11416 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
11417 (shifts): New code iterator.
11418 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
11419 expander. Fix HImode handling on H8/SX.
11420 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
11421 (subqi3, subhi3, subsi3 expanders): Likewise.
11422 (andqi3, andhi3, andsi3 expanders): Likewise.
11423 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
11424 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
11425 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
11426 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
11427 (zero_extendqihi2, zero_extendqisi2): Likewise.
11428 (extendqihi2, extendqisi2): Likewise.
11429 (rotlqi3, rotlhi3, rotlsi3): Likewise.
11430 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
11431 (rotlqi3_1, rotlhi3_1): Likewise.
11432 (logicalhi3_sn, logicalsi3_sn): Likewise.
11433 (logicalhi3, logicalsi3): Likewise.
11434
11435 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11436
11437 * tree-vect-patterns.c (vect_recog_rotate_pattern)
11438 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11439 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
11440 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
11441 type to append_pattern_def_seq instead of creating a stmt_vec_info
11442 directly.
11443 (build_mask_conversion): Likewise. Remove vinfo argument.
11444 (vect_add_conversion_to_patterm): Likewise, renaming to...
11445 (vect_add_conversion_to_pattern): ...this.
11446 (vect_recog_mask_conversion_pattern): Update call to
11447 build_mask_conversion. Pass the vector type to
11448 append_pattern_def_seq here too.
11449 (vect_recog_gather_scatter_pattern): Update call to
11450 vect_add_conversion_to_pattern.
11451
11452 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11453
11454 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
11455 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11456 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
11457 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
11458 STMT_VINFO_PATTERN_DEF_SEQ to null here.
11459 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
11460 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
11461 append_pattern_def_seq instead of new_pattern_def_seq.
11462 (vect_recog_divmod_pattern): Do both of the above.
11463 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
11464 is null.
11465
11466 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11467
11468 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
11469 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
11470 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
11471 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
11472 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
11473 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11474 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
11475 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
11476 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
11477 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
11478 parameter with a single stmt_vec_info.
11479 (vect_recog_func_ptr): Likewise.
11480 (vect_recog_gather_scatter_pattern): Likewise, folding in...
11481 (vect_try_gather_scatter_pattern): ...this.
11482 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
11483 the stmt_vec_info of the statement to be matched. Don't clear
11484 STMT_VINFO_RELATED_STMT.
11485 (vect_pattern_recog): Update call accordingly.
11486
11487 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11488
11489 PR tree-optimization/85694
11490 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
11491 (uavgM3_ceil): Document new optabs.
11492 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
11493 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
11494 functions.
11495 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
11496 (savg_ceil_optab): New optabs.
11497 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
11498 (vect_vect_recog_func_ptrs): Add it.
11499 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
11500 constant directly from the associated lhs.
11501
11502 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11503
11504 * tree-vect-patterns.c (vect_split_statement): New function.
11505 (vect_convert_input): Use it to try to split an existing cast.
11506
11507 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11508
11509 * poly-int.h (print_hex): New function.
11510 * dumpfile.h (dump_dec, dump_hex): Declare.
11511 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
11512 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
11513 min_input_precision, operation_precision and operation_sign.
11514 * tree-vect-patterns.c (vect_get_range_info): New function.
11515 (vect_same_loop_or_bb_p, vect_single_imm_use)
11516 (vect_operation_fits_smaller_type): Delete.
11517 (vect_look_through_possible_promotion): Add an optional
11518 single_use_p parameter.
11519 (vect_recog_over_widening_pattern): Rewrite to use new
11520 stmt_vec_info infomration. Handle one operation at a time.
11521 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
11522 (vect_truncatable_operation_p, vect_set_operation_type)
11523 (vect_set_min_input_precision): New functions.
11524 (vect_determine_min_output_precision_1): Likewise.
11525 (vect_determine_min_output_precision): Likewise.
11526 (vect_determine_precisions_from_range): Likewise.
11527 (vect_determine_precisions_from_users): Likewise.
11528 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
11529 (vect_vect_recog_func_ptrs): Put over_widening first.
11530 Add cast_forwprop.
11531 (vect_pattern_recog): Call vect_determine_precisions.
11532
11533 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11534
11535 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
11536 statements that have been replaced by further pattern statements.
11537 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
11538
11539 2018-07-03 Richard Biener <rguenther@suse.de>
11540
11541 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
11542 always set *dt. Dump vectype in vectype overload.
11543 * dumpfile.h (dump_gimple_expr): New function.
11544 (dump_gimple_expr_loc): Likewise.
11545 * dumpfile.c (dump_gimple_expr): New function.
11546 (dump_gimple_expr_loc): Likewise.
11547
11548 2018-07-02 Jeff Law <law@redhat.com>
11549
11550 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
11551 the H8/300, H8/300H and H8/S variants into a single pattern.
11552 (movhi_h8300, movqi_h8300hs): Similarly.
11553 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
11554 (QHI mode iterator): New.
11555
11556 * config/h8300/h8300.md: Remove trailing whitespace.
11557
11558 2018-07-02 Jim Wilson <jimw@sifive.com>
11559
11560 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
11561 instead of emit_insn for interrupt returns.
11562 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
11563 (riscv_sret, riscv_uret): Likewise.
11564
11565 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11566
11567 * pretty-print.c (selftest::test_pp_format): Move save and restore
11568 of quotes to class auto_fix_quotes, and add an instance.
11569 * selftest.c: Include "intl.h".
11570 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
11571 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
11572 * selftest.h (selftest::auto_fix_quotes): New class.
11573
11574 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
11575
11576 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
11577 (aarch64_sve_prepare_conditional_op): Remove.
11578 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
11579 Allow aarch64_simd_reg_or_zero as select operand; remove
11580 the aarch64_sve_prepare_conditional_op call.
11581 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
11582 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11583 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
11584 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
11585 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
11586 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
11587 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
11588 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
11589 and a splitters to match all of the *_any patterns.
11590 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
11591
11592 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
11593 (SVE_COND_FP_BINARY_REV): Remove.
11594 (sve_int_op_rev, sve_fp_op_rev): New.
11595 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
11596 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
11597 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
11598 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
11599 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
11600 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
11601 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
11602 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
11603 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
11604
11605 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
11606 Remove match_dup 1 from the inner unspec.
11607 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11608
11609 * config/aarch64/aarch64.md (movprfx): New attr.
11610 (length): Default movprfx to 8.
11611 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
11612 (*madd<SVE_I>, *msub<SVE_I): Likewise.
11613 (*<su>mul<SVE_I>3_highpart): Likewise.
11614 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
11615 (*v<ASHIFT><SVE_I>3): Likewise.
11616 (*<su><MAXMIN><SVE_I>3): Likewise.
11617 (*<su><MAXMIN><SVE_F>3): Likewise.
11618 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
11619 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
11620 (*div<SVE_F>4): Likewise.
11621
11622 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
11623
11624 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
11625 in dump string.
11626
11627 2018-07-02 Richard Biener <rguenther@suse.de>
11628
11629 PR tree-optimization/86363
11630 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
11631 memset argument refers to a non-variable address.
11632
11633 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11634
11635 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
11636 {PLUS,MINUS}_EXPR code to...
11637 (adjust_symbolic_bound): ...here,
11638 (combine_bound): ...here,
11639 (set_value_range_with_overflow): ...and here.
11640
11641 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11642
11643 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
11644 code...
11645 (extract_range_from_abs_expr): ...here.
11646
11647 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
11648
11649 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
11650 -fno-omit-frame-pointer when not optimizing.
11651
11652 2018-07-02 Martin Liska <mliska@suse.cz>
11653
11654 PR ipa/86279
11655 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
11656 (propagate_nothrow): Likewise.
11657
11658 2018-07-02 Martin Liska <mliska@suse.cz>
11659
11660 PR ipa/86323
11661 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
11662
11663 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11664
11665 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
11666 function in r262149, changing "loc" param from source_location to
11667 const dump_location_t &.
11668 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
11669 declaration, as above.
11670
11671 2018-07-01 Paul Koning <ni1d@arrl.net>
11672
11673 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
11674 -munit-asm, -mgnu-asm, -mdec-asm.
11675 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
11676 (pdp11_output_labelref): New.
11677 (pdp11_output_def): New.
11678 (pdp11_output_addr_vec_elt): New.
11679 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
11680 %# and %@ format codes.
11681 (pdp11_option_override): New.
11682 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
11683 (pdp11_output_ident): New.
11684 (pdp11_asm_named_section): New.
11685 (pdp11_asm_init_sections): New.
11686 (pdp11_file_start): New.
11687 (pdp11_file_end): New.
11688 (output_ascii): Use .ascii/.asciz for -mdec-asm.
11689 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
11690 %o, like %c but octal.
11691 (pdp11_option_override): New.
11692 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
11693 -mdec-asm.
11694 (DATA_SECTION_ASM_OP): Ditto.
11695 (READONLY_DATA_SECTION_ASM_OP): New.
11696 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
11697 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
11698 (ASM_OUTPUT_LABELREF): Ditto.
11699 (ASM_OUTPUT_DEF): Ditto.
11700 (ASM_OUTPUT_EXTERNAL): New.
11701 (ASM_OUTPUT_SOURCE_FILENAME): New.
11702 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
11703 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
11704 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
11705 %# and %@ format codes.
11706 * config/pdp11/pdp11.opt (mgnu-asm): New.
11707 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
11708 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
11709 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
11710
11711 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
11712
11713 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
11714 dereferencing path[] beyond its length.
11715 (debug_path): New.
11716 (debug_all_paths): New.
11717 (rewire_first_differing_edge): New.
11718 (adjust_paths_after_duplication): New.
11719 (duplicate_thread_path): Call adjust_paths_after_duplication.
11720 Add new argument.
11721 (thread_through_all_blocks): Add new argument to
11722 duplicate_thread_path.
11723
11724 2018-06-30 Jim Wilson <jimw@sifive.com>
11725
11726 * config/riscv/predicates.md (p2m1_shift_operand): New.
11727 (high_mask_shift_operand): New.
11728 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
11729 pattern using p2m1_shift_operand.
11730 (lshsi3_zero_extend_3+2): New combiner pattern using
11731 high_mask_shift_operand.
11732
11733 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11734
11735 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
11736 split out from...
11737 (vect_recog_rotate_pattern): ...here.
11738 (vect_convert_input): Try to insert casts of invariants in the
11739 preheader.
11740 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
11741 preheader to be empty.
11742
11743 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11744
11745 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
11746 vector type. If given, install it in the new statement's
11747 STMT_VINFO_VECTYPE.
11748 (vect_element_precision): New function.
11749 (vect_unpromoted_value): New struct.
11750 (vect_unpromoted_value::vect_unpromoted_value): New function.
11751 (vect_unpromoted_value::set_op): Likewise.
11752 (vect_look_through_possible_promotion): Likewise.
11753 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
11754 (vect_widened_op_tree, vect_convert_input): Likewise.
11755 (vect_convert_inputs, vect_convert_output): Likewise.
11756 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
11757 to handle the optional cast of the multiplication result and
11758 vect_widened_op_tree to detect the widened multiplication itself.
11759 Do not require the input and output of promotion casts to have
11760 the same sign, but base the signedness of the operation on the
11761 input rather than the result. If the pattern includes two
11762 promotions, check that those promotions have the same sign.
11763 Do not restrict the MULT_EXPR handling to a double-width result;
11764 handle quadruple-width results and wider. Use vect_convert_inputs
11765 to convert the inputs to the common type.
11766 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
11767 to handle the optional cast of the ABS result. Also allow a sign
11768 change or a sign extension between the ABS and MINUS.
11769 Use vect_widened_op_tree to detect the widened subtraction and use
11770 vect_convert_inputs to convert the inputs to the common type.
11771 (vect_handle_widen_op_by_const): Delete.
11772 (vect_recog_widen_op_pattern): New function.
11773 (vect_recog_widen_mult_pattern): Use it.
11774 (vect_recog_widen_shift_pattern): Likewise.
11775 (vect_recog_widen_sum_pattern): Use
11776 vect_look_through_possible_promotion to handle the promoted
11777 PLUS_EXPR operand.
11778
11779 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11780
11781 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
11782 the containing gimple_seq *.
11783 * gimple-iterator.h (gsi_for_stmt): Declare it.
11784 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
11785 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
11786 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11787 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11788 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
11789 checks.
11790 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
11791 split out from...
11792 (vect_mark_pattern_stmts): ...here. Handle cases in which the
11793 statement being replaced is part of an existing pattern
11794 definition sequence, inserting the new pattern statements before
11795 the original one.
11796 (vect_pattern_recog_1): Don't return a bool. If the statement
11797 is already part of a pattern, instead apply pattern matching
11798 to the pattern definition statements. Don't clear the
11799 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
11800 (vect_pattern_recog): Don't break after the first match;
11801 continue processing the pattern definition statements instead.
11802 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
11803
11804 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11805
11806 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
11807 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11808 (vect_recog_widen_sum_pattern): Use it.
11809
11810 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11811
11812 * tree-vect-loop.c (vectorizable_reduction): Assert that the
11813 phi is not a pattern statement and has not been replaced by
11814 a pattern statement.
11815 * tree-vect-patterns.c (type_conversion_p): Don't check
11816 STMT_VINFO_IN_PATTERN_P.
11817 (vect_recog_vector_vector_shift_pattern): Likewise.
11818 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
11819 the pattern statement rather than the original statement; check
11820 directly for a WIDEN_MULT_EXPR here.
11821 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
11822 vect_is_simple_use to return the pattern statement rather
11823 than the original statement; use is_pattern_stmt_p to check
11824 for such a pattern statement.
11825 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
11826 to return the pattern statement rather than the original statement;
11827 don't do the same transformation here.
11828 (vect_is_simple_use): If the defining statement has been replaced
11829 by a pattern statement, return the pattern statement instead.
11830 Remove the corresponding (local) transformation from the vectype
11831 overload.
11832
11833 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11834
11835 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
11836 end and default to null.
11837 * tree-vect-loop.c (vect_create_epilog_for_reduction)
11838 (vectorizable_reduction): Update calls accordingly, dropping the
11839 gimple ** argument if the passed-back statement isn't needed.
11840 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
11841 (vect_recog_rotate_pattern): Likewise.
11842 (vect_recog_mask_conversion_pattern): Likewise.
11843 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
11844 (vect_mask_constant_operand_p): Likewise.
11845 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
11846 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
11847 (get_group_load_store_type, get_load_store_type): Likewise.
11848 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
11849 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
11850 (vectorizable_conversion, vectorizable_assignment): Likewise.
11851 (vectorizable_shift, vectorizable_operation): Likewise.
11852 (vectorizable_store, vect_is_simple_cond): Likewise.
11853 (vectorizable_condition, vectorizable_comparison): Likewise.
11854 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
11855 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
11856 and move it to the end. Cope with null def_stmt_outs.
11857
11858 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
11859
11860 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
11861
11862 2018-06-29 Jeff Law <law@redhat.com>
11863
11864 * config/v850/v850.c (v850_legitimate_address_p): Handle large
11865 displacements for TARGET_V850E2V3 and newer.
11866 (TARGET_LRA_P): Remove. Defaults to LRA now.
11867 * config/v850/v850.md (sign23byte_load): Remove.
11868 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
11869 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
11870
11871 2018-06-29 Martin Liska <mliska@suse.cz>
11872
11873 PR lto/85759
11874 * coverage.c (coverage_init): Mangle full path name.
11875 * doc/invoke.texi: Document the change.
11876 * gcov-io.c (mangle_path): New.
11877 * gcov-io.h (mangle_path): Likewise.
11878 * gcov.c (mangle_name): Use mangle_path for path mangling.
11879
11880 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11881
11882 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
11883 if starting source register is not even.
11884
11885 2018-06-29 Martin Liska <mliska@suse.cz>
11886
11887 PR tree-optimization/86263
11888 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
11889 Make edge redirection.
11890
11891 2018-06-29 David Malcolm <dmalcolm@redhat.com>
11892
11893 * dumpfile.c (dump_loc): Add indentation based on scope depth.
11894 (dump_scope_depth): New variable.
11895 (get_dump_scope_depth): New function.
11896 (dump_begin_scope): New function.
11897 (dump_end_scope): New function.
11898 * dumpfile.h (get_dump_scope_depth): New declaration.
11899 (dump_begin_scope): New declaration.
11900 (dump_end_scope): New declaration.
11901 (class auto_dump_scope): New class.
11902 (AUTO_DUMP_SCOPE): New macro.
11903 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
11904 AUTO_DUMP_SCOPE.
11905
11906 2018-06-29 Richard Biener <rguenther@suse.de>
11907
11908 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
11909 compute_all_dependences succeeds.
11910 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
11911 exceed --param loop-max-datarefs-for-datadeps.
11912
11913 2018-06-29 Jakub Jelinek <jakub@redhat.com>
11914
11915 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
11916
11917 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
11918
11919 PR target/86348
11920 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
11921 alternative 0 in preferred_for_speed attribute.
11922
11923 2018-06-28 Paul Koning <ni1d@arrl.net>
11924
11925 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
11926 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
11927 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
11928 * config/pdp11/pdp11.md: Correct "length" attribute calculation
11929 for shift insn patterns.
11930
11931 2018-06-28 David Malcolm <dmalcolm@redhat.com>
11932
11933 * cgraph.c (cgraph_node::get_body): Replace assignments to
11934 "dump_file" with calls to set_dump_file.
11935 * dumpfile.c (alt_dump_file): Make static, and group with...
11936 (alt_flags): ...this definition.
11937 (dumps_are_enabled): New variable.
11938 (refresh_dumps_are_enabled): New function.
11939 (set_dump_file): New function.
11940 (set_alt_dump_file): New function.
11941 (gcc::dump_manager::dump_start): Replace assignments to
11942 "dump_file" and "alt_dump_file" with calls to set_dump_file and
11943 set_alt_dump_file.
11944 (gcc::dump_manager::dump_finish): Likewise.
11945 * dumpfile.h (alt_dump_file): Delete decl.
11946 (dumps_are_enabled): New variable decl.
11947 (set_dump_file): New function decl.
11948 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
11949 global.
11950 * tree-nested.c (lower_nested_functions): Replace assignments to
11951 "dump_file" with calls to set_dump_file.
11952
11953 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
11954
11955 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
11956 goto_locus of each outgoing edge of each basic block.
11957
11958 2018-06-28 Richard Biener <rguenther@suse.de>
11959
11960 * dwarf2out.c (decl_scope_table): Remove.
11961 (push_decl_scope): Likewise.
11962 (pop_decl_scope): Likewise.
11963 (gen_type_die_for_member): Do not call push/pop_decl_scope.
11964 (gen_struct_or_union_type_die): Likewise.
11965 (gen_tagged_type_die): Likewise.
11966 (dwarf2out_init): Do not initialize decl_scope_table.
11967 (dwarf2out_c_finalize): Do not free it.
11968
11969 2018-06-28 Richard Biener <rguenther@suse.de>
11970
11971 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
11972 deciding whether to not re-use a DIE.
11973
11974 2018-06-28 Richard Biener <rguenther@suse.de>
11975
11976 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
11977 DW_AT_abstract_origin attribute.
11978
11979 2018-06-28 Martin Liska <mliska@suse.cz>
11980
11981 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
11982 Use newly introduced constants.
11983 * tree-switch-conversion.h (struct jump_table_cluster):
11984 Define max_ratio_for_size and max_ratio_for_speed.
11985
11986 2018-06-28 Martin Liska <mliska@suse.cz>
11987
11988 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
11989 Add new checking assert to catch invalid state.
11990 (jump_table_cluster::can_be_handled): Handle single case
11991 clusters.
11992 (jump_table_cluster::is_beneficial): Bail out for such case.
11993 (bit_test_cluster::find_bit_tests):
11994 Add new checking assert to catch invalid state.
11995 (bit_test_cluster::can_be_handled): Handle single case
11996 clusters.
11997 (bit_test_cluster::is_beneficial): Bail out for such case.
11998 (switch_decision_tree::analyze_switch_statement):
11999 Fix comment.
12000
12001 2018-06-28 Martin Liska <mliska@suse.cz>
12002
12003 * common.opt: Introduce -completion option.
12004 * gcc.c (driver_handle_option): Handle it.
12005 (driver::main): Print completions if completion
12006 is set.
12007 * opt-suggestions.c (option_proposer::get_completions):
12008 New function.
12009 (option_proposer::suggest_completion): Likewise.
12010 (option_proposer::find_param_completions): Likewise.
12011 (verify_autocompletions): Likewise.
12012 (test_completion_valid_options): Likewise.
12013 (test_completion_valid_params): Likewise.
12014 (in_completion_p): Likewise.
12015 (empty_completion_p): Likewise.
12016 (test_completion_partial_match): Likewise.
12017 (test_completion_garbage): Likewise.
12018 (opt_proposer_c_tests): Likewise.
12019 * opt-suggestions.h: Declare new functions.
12020 * opts.c (common_handle_option): Handle OPT__completion_.
12021 * selftest-run-tests.c (selftest::run_tests): Add
12022 opt_proposer_c_tests.
12023 * selftest.c (assert_str_startswith): New.
12024 * selftest.h (assert_str_startswith): Likewise.
12025 (opt_proposer_c_tests): New.
12026 (ASSERT_STR_STARTSWITH): Likewise.
12027
12028 2018-06-28 Martin Liska <mliska@suse.cz>
12029
12030 * Makefile.in: Add opt-suggestions.o.
12031 * gcc-main.c: Include opt-suggestions.h.
12032 * gcc.c (driver::driver): Likewise.
12033 (driver::~driver): Remove m_option_suggestions.
12034 (driver::build_option_suggestions): Moved to option_proposer.
12035 (driver::suggest_option): Likewise.
12036 (driver::handle_unrecognized_options): Use option_proposer.
12037 * gcc.h (class driver): Add new memver m_option_proposer.
12038 * opt-suggestions.c: New file.
12039 * opt-suggestions.h: New file.
12040
12041 2018-06-28 Martin Liska <mliska@suse.cz>
12042
12043 * vec.h (class auto_string_vec): New (moved from auto_argvec).
12044 (auto_string_vec::~auto_string_vec): Likewise.
12045
12046 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
12047
12048 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
12049 prevent_decl_creation_for_types fields up and add reset_location field.
12050 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
12051 statement if id->reset_location is true.
12052 (copy_edges_for_bb): Do not set goto_locus on the new edges if
12053 id->reset_location is true.
12054 (copy_phis_for_bb): Force input_location on the arguments if
12055 id->reset_location is true.
12056 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
12057 is set on the function to be inlined.
12058
12059 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
12060
12061 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
12062
12063 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
12064
12065 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
12066 registers for Pmode.
12067 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
12068 hard registers for the clobbered pseudo.
12069
12070 2018-06-27 Paul Koning <ni1d@arrl.net>
12071
12072 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
12073 mutually exclusive options.
12074 * config/pdp11/constraints.md (h): New constraint.
12075 (O): Update definition to match shift code generation.
12076 (D): New constraint.
12077 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
12078 (CCFP): Remove.
12079 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
12080 function.
12081 (output_jump): Change arguments.
12082 (pdp11_fixed_cc_regs): New function.
12083 (pdp11_cc_mode): Ditto.
12084 (pdp11_expand_shift): Ditto.
12085 (pdp11_assemble_shift): Ditto.
12086 (pdp11_small_shift): Ditto.
12087 (pdp11_branch_cost): Remove.
12088 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
12089 from output.
12090 (pdp11_register_move_cost): Update for CC registers.
12091 (pdp11_rtx_costs): Add case for LSHIFTRT.
12092 (pdp11_output_jump): Add CCNZ mode conditional branches.
12093 (notice_update_cc_on_set): Remove.
12094 (pdp11_cc_mode): New function.
12095 (simple_memory_operand): Correct pre/post decrement case.
12096 (no_side_effect_operand): New function.
12097 (pdp11_regno_reg_class): Add CC_REGS class.
12098 (pdp11_fixed_cc_regs): New function.
12099 (pdp11_small_shift): New function.
12100 (pdp11_expand_shift): New function to expand shift insns.
12101 (pdp11_assemble_shift): New function to output shifts.
12102 (pdp11_branch_cost): Remove.
12103 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
12104 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
12105 (WCHAR_TYPE): Ditto.
12106 (PTRDIFF_TYPE): Ditto.
12107 (ADJUST_INSN_LENGTH): New macro.
12108 (FIXED_REGISTERS): Add CC registers.
12109 (CALL_USED_REGISTERS): Ditto.
12110 (reg_class): Ditto.
12111 (REG_CLASS_NAMES): Ditto.
12112 (REG_CLASS_CONTENTS): Ditto.
12113 (SELECT_CC_MODE): Use new function.
12114 (TARGET_FLAGS_REGNUM): New macro.
12115 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
12116 (cc0_reg_rtx): Remove.
12117 (CC_STATUS_MDEP): Remove.
12118 (CC_STATUS_MDEFP_INIT): Remove.
12119 (CC_IN_FPU): Remove.
12120 (NOTICE_UPDATE_CC): Remove.
12121 (REGISTER_NAMES): Add CC registers.
12122 (BRANCH_COST): Change to constant 1.
12123 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
12124 handling.
12125 * config/pdp11/pdp11.opt (mbcopy): Remove.
12126 (mbcopy-builtin): Remove.
12127 (mbranch-cheap): Remove.
12128 (mbranch-expensive): Remove.
12129 * config/pdp11/predicates.md (expand_shift_operand): Update to
12130 match shift code generation.
12131 (ccnz_operator): New predicate.
12132 * doc/invoke.texi (PDP-11 Options): Remove deleted options
12133 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
12134 Remove non-existent option -mabshi, -mno-abshi. Document mutually
12135 exclusive options.
12136 * doc/md.texi (PDP-11): Document new D and h constraints. Update
12137 description of O constraint.
12138
12139 2018-06-27 Jeff Law <law@redhat.com>
12140 Austin Law <austinklaw@gmail.com>
12141
12142 * config/v850/v850.md (addsi3_set_flags): New pattern.
12143 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
12144 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
12145 (zero_extendhisi2_v850_set_flags): Likewise.
12146 (zero_extendqisi2_v850_set_flags): Likewise.
12147 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
12148 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
12149 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
12150
12151 * config/v850/v850-protos.h (notice_update_cc): Remove.
12152 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
12153 (v850_print_operand): Handle 'D' and "d".
12154 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
12155 Add handling of arithmetic/logical operations compared against zero.
12156 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
12157 Do not look at v850_compare_op, instead get mode from last argument.
12158 (v850_gen_compare): Remove
12159 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
12160 after reload for prologue insns.
12161 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
12162 patterns.
12163 (construct_save_jarl): Likewise.
12164 (TARGET_FLAGS_REGNUM): Define.
12165 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
12166 (NOTICE_UPDATE_CC): Remove.
12167 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
12168 than cc0. Conditionalize on reload_completed.
12169 (cmpsi_insn, setfcc_insn): Likewise.
12170 (tst1 splitter): Turn into define_and_split which sets the flags
12171 after reload.
12172 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
12173 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
12174 (cstoresf4, cstoredf4): Clobber the flags.
12175 (cmpsi, cmpsf, cmpdf): Remove expanders.
12176 (setf_insn): Remove pattern.
12177 (addsi3): Turn into define_and_split which clobbers the flags after
12178 reload and a suitable pattern (addsi3_clobber_flags) for use after
12179 reload.
12180 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
12181 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
12182 (ashrsi3, ashrsi3_v850e2): Likewise.
12183 (bins): Clobber the flags.
12184 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
12185 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
12186 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
12187 (call_value_internal_short, call_value_internal_long): Likewise.
12188 (callt_save_interrupt, callt_return_interrupt): Likewise.
12189 (save_interrupt, return_interrupt): Likewise.
12190 (callt_save_all_interrupt, save_all_interrupt): Likewise.
12191 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
12192 (restore_all_interrupt, _restore_all_interrupt): Likewise.
12193 (All FP comparisons): Only allow after reload has completed.
12194 (trfsr): Likewise.
12195 (divh, divhu): Tweak output template.
12196 (branch_z_normal, branch_z_invert): Remove
12197 (branch_nz_normal, branch_nz_invert): Likewise.
12198 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
12199
12200 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
12201 * config/v850/v850.c (notice_update_cc): Remove.
12202 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
12203 (CC_NO_CARRY): Likewise.
12204 (NOTICE_UPDATE_CC): Define to nothing.
12205 * config/v850/v850.md: Remove block comment on cc0 handling
12206 Remove "cc" attribute from all patterns. Remove cc_status handling
12207 from all patterns. Minor formatting fixes.
12208
12209 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12210
12211 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
12212 (cortex-a76.cortex-a55): Likewise.
12213 * config/aarch64/aarch64-tune.md: Regenerate.
12214 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
12215 cortex-a76.cortex-a55.
12216
12217 2018-06-27 Jeff Law <law@redhat.com>
12218
12219 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
12220 (MULTILIB_DIRNAMES): Similarly.
12221
12222 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
12223
12224 * gimple.h (gimple_return_retbnd): Delete.
12225 (gimple_return_set_retbnd): Likewise.
12226 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
12227 gimple_return_set_retbnd.
12228 * gimple-pretty-print.c (dump_gimple_return): Remove call to
12229 gimple_return_retbnd and adjust.
12230 * tree-inline.h (struct copy_body_data): Remove retbnd field.
12231 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
12232 Explicitly return NULL in a couple more cases. Move assertion
12233 on debug statements and remove unreachable code.
12234 (reset_debug_binding): Do not test id->retbnd.
12235 (expand_call_inline): Do not set it.
12236
12237 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12238
12239 * configure.ac: Add --disable-gcov option.
12240 * configure: Regenerate.
12241 * Makefile.in: Honour @enable_gcov@.
12242 * doc/install.texi: Document --disable-gcov.
12243
12244 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12245
12246 * config/arm/arm-cpus.in (cortex-a76): New entry.
12247 (cortex-a76.cortex-a55): Likewise.
12248 * config/arm/arm-tables.opt: Regenerate.
12249 * config/arm/arm-tune.md: Likewise.
12250 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
12251 * doc/invoke.texi (ARM Options): Document cortex-a76 and
12252 cortex-a76.cortex-a55.
12253
12254 2018-06-27 Tamar Christina <tamar.christina@arm.com>
12255
12256 PR target/85769
12257 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
12258
12259 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
12260
12261 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
12262 comment.
12263 (EPILOGUE_USES): Likewise.
12264
12265 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
12266
12267 * tree-inline.c (remap_location): New function extracted from...
12268 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
12269 (copy_phis_for_bb): ...here. Call remap_location.
12270 (copy_cfg_body): Adjust call to copy_edges_for_bb.
12271
12272 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
12273
12274 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
12275 unaligned vsx for 16B memset.
12276
12277 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
12278
12279 PR target/86285
12280 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
12281 ieee128_float_type_node to long_double_type_node unless
12282 TARGET_LONG_DOUBLE_128 is set.
12283
12284 2018-06-26 David Malcolm <dmalcolm@redhat.com>
12285
12286 * cfgloop.c (get_loop_location): Convert return type from
12287 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
12288 by implicit construction from rtx_insn *, and using
12289 dump_user_location_t::from_function_decl for the fallback case.
12290 * cfgloop.h (get_loop_location): Convert return type from
12291 location_t to dump_user_location_t.
12292 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
12293 dump_printf_loc to pass in a dump_location_t rather than a
12294 location_t, via the gimple stmt.
12295 * coverage.c (get_coverage_counts): Update calls to
12296 dump_printf_loc to pass in dump_location_t rather than a
12297 location_t.
12298 * doc/optinfo.texi (Dump types): Convert example of
12299 dump_printf_loc from taking "locus" to taking "insn". Update
12300 description of the "_loc" calls to cover dump_location_t.
12301 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
12302 "selftest.h".
12303 (dump_user_location_t::dump_user_location_t): New constructors,
12304 from gimple *stmt and rtx_insn *.
12305 (dump_user_location_t::from_function_decl): New function.
12306 (dump_loc): Make static.
12307 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
12308 const dump_location_t &.
12309 (dump_generic_expr_loc): Delete.
12310 (dump_printf_loc): Convert param "loc" from location_t to
12311 const dump_location_t &.
12312 (selftest::test_impl_location): New function.
12313 (selftest::dumpfile_c_tests): New function.
12314 * dumpfile.h: Include "profile-count.h".
12315 (class dump_user_location_t): New class.
12316 (struct dump_impl_location_t): New struct.
12317 (class dump_location_t): New class.
12318 (dump_printf_loc): Convert 2nd param from source_location to
12319 const dump_location_t &.
12320 (dump_generic_expr_loc): Delete.
12321 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
12322 const dump_location_t &.
12323 * gimple-fold.c (fold_gimple_assign): Update call to
12324 dump_printf_loc to pass in a dump_location_t rather than a
12325 location_t, via the gimple stmt.
12326 (gimple_fold_call): Likewise.
12327 * gimple-loop-interchange.cc
12328 (loop_cand::analyze_iloop_reduction_var): Update for change to
12329 check_reduction_path.
12330 (tree_loop_interchange::interchange): Update for change to
12331 find_loop_location.
12332 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
12333 change in return-type of find_loop_location.
12334 (graphite_regenerate_ast_isl): Likewise.
12335 * graphite-optimize-isl.c (optimize_isl): Likewise.
12336 * graphite.c (graphite_transform_loops): Likewise.
12337 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
12338 pass in a dump_location_t rather than a location_t, via the
12339 gimple stmt.
12340 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
12341 * ipa.c (walk_polymorphic_call_targets): Likewise.
12342 * loop-unroll.c (report_unroll): Convert "locus" param from
12343 location_t to dump_location_t.
12344 (decide_unrolling): Update for change to get_loop_location's
12345 return type.
12346 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
12347 location_t to dump_user_location_t.
12348 (grid_find_single_omp_among_assignments_1): Updates calls to
12349 dump_printf_loc to pass in a dump_location_t rather than a
12350 location_t, via the gimple stmt.
12351 (grid_parallel_clauses_gridifiable): Convert "tloc" from
12352 location_t to dump_location_t. Updates calls to dump_printf_loc
12353 to pass in a dump_location_t rather than a location_t, via the
12354 gimple stmt.
12355 (grid_inner_loop_gridifiable_p): Likewise.
12356 (grid_dist_follows_simple_pattern): Likewise.
12357 (grid_gfor_follows_tiling_pattern): Likewise.
12358 (grid_target_follows_gridifiable_pattern): Likewise.
12359 (grid_attempt_target_gridification): Convert initialization
12360 of local "grid" from memset to zero-initialization; FIXME: does
12361 this require C++11? Update call to dump_printf_loc to pass in a
12362 optinfo_location rather than a location_t, via the gimple stmt.
12363 * profile.c (read_profile_edge_counts): Updates call to
12364 dump_printf_loc to pass in a dump_location_t rather than a
12365 location_t
12366 (compute_branch_probabilities): Likewise.
12367 * selftest-run-tests.c (selftest::run_tests): Call
12368 dumpfile_c_tests.
12369 * selftest.h (dumpfile_c_tests): New decl.
12370 * tree-loop-distribution.c (pass_loop_distribution::execute):
12371 Update for change in return type of find_loop_location.
12372 * tree-parloops.c (parallelize_loops): Likewise.
12373 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
12374 "locus" from location_t to dump_user_location_t.
12375 (canonicalize_loop_induction_variables): Likewise.
12376 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
12377 for change in return type of find_loop_location.
12378 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
12379 to dump_printf_loc to pass in a dump_location_t rather than a
12380 location_t, via the stmt.
12381 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
12382 Likewise.
12383 * tree-vect-loop-manip.c (find_loop_location): Convert return
12384 type from source_location to dump_user_location_t.
12385 (vect_do_peeling): Update for above change.
12386 (vect_loop_versioning): Update for change in type of
12387 vect_location.
12388 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
12389 from location_t to dump_user_location_t.
12390 (vect_estimate_min_profitable_iters): Update for change in type
12391 of vect_location.
12392 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
12393 location_t to dump_location_t.
12394 (vect_slp_bb): Update for change in type of vect_location.
12395 * tree-vectorizer.c (vect_location): Convert from source_location
12396 to dump_user_location_t.
12397 (try_vectorize_loop_1): Update for change in vect_location's type.
12398 (vectorize_loops): Likewise.
12399 (increase_alignment): Likewise.
12400 * tree-vectorizer.h (vect_location): Convert from source_location
12401 to dump_user_location_t.
12402 (find_loop_location): Convert return type from source_location to
12403 dump_user_location_t.
12404 (check_reduction_path): Convert 1st param from location_t to
12405 dump_user_location_t.
12406 * value-prof.c (check_counter): Update call to dump_printf_loc to
12407 pass in a dump_user_location_t rather than a location_t; update
12408 call to error_at for change in type of "locus".
12409 (check_ic_target): Update call to dump_printf_loc to
12410 pass in a dump_user_location_t rather than a location_t, via the
12411 call_stmt.
12412
12413 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
12414
12415 * config/s390/s390.h (enum processor_flags): Do not use
12416 default tune parameter when -march was specified.
12417
12418 2018-06-26 Jakub Jelinek <jakub@redhat.com>
12419
12420 PR target/86314
12421 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
12422 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
12423 operands.
12424
12425 2018-06-26 Richard Biener <rguenther@suse.de>
12426
12427 PR tree-optimization/86287
12428 PR bootstrap/86316
12429 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
12430 (vect_analyze_loop): Initialize n_stmts.
12431
12432 2018-06-26 Richard Biener <rguenther@suse.de>
12433
12434 PR middle-end/86271
12435 * fold-const.c (fold_convertible_p): Pointer extension
12436 isn't valid.
12437
12438 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
12439
12440 PR debug/86064
12441 * dwarf2out.c (loc_list_has_views): Adjust comments.
12442 (dw_loc_list): Split single cross-partition range with
12443 nonzero locview.
12444
12445 2018-06-25 Jeff Law <law@redhat.com>
12446
12447 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
12448 on -mbig-switch by default.
12449
12450 * config/v850/predicates.md (const_float_1_operand): Fix match_code
12451 test.
12452 (const_float_0_operand): Remove unused predicate.
12453 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
12454 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
12455 (recipsf2): New expander. Original pattern now called
12456 (recipsf2_insn).
12457 (recipdf2, recipdf2_insn): Similarly.
12458 (rsqrtsf2, rsqrtsf2_insn): Similarly
12459 (rsqrtdf2, rsqrtdf2_insn): Similarly
12460
12461 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
12462
12463 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
12464 Simplify logic for FreeBSD (twice).
12465
12466 2018-06-25 Martin Sebor <msebor@redhat.com>
12467
12468 PR tree-optimization/86204
12469 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
12470 a strnlen result if it's less than the length of the string.
12471
12472 2018-06-25 Martin Sebor <msebor@redhat.com>
12473
12474 PR tree-optimization/85700
12475 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
12476 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
12477 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
12478
12479 2018-06-25 Martin Sebor <msebor@redhat.com>
12480
12481 * doc/extend.texi (Zero-length arrays): Update and clarify.
12482
12483 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
12484
12485 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
12486 added IEEE/IBM long double multilib support on PowerPC little
12487 endian Linux systems.
12488 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
12489 (MULTILIB_DEFAULTS): Likewise.
12490 * config/rs6000/rs6000.c (rs6000_option_override_internal):
12491 Likewise.
12492 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
12493 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
12494 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
12495
12496 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
12497
12498 PR middle-end/86311
12499 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
12500 (REORDER_45): Likewise.
12501
12502 2018-06-25 Jeff Law <law@redhat.com>
12503
12504 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
12505 dividend to 32 bits. Adjust length.
12506 (udivmodhi4): Cleanup output template. Fix length.
12507
12508 2018-06-25 Carl Love <cel@us.ibm.com>
12509
12510 * config/rs6000/vsx.md: Change word selector to prefered location.
12511
12512 2018-06-25 Richard Biener <rguenther@suse.de>
12513
12514 PR tree-optimization/86304
12515 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
12516 epilogue-if-converted loops as well.
12517
12518 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
12519
12520 * lto-section-out.c (lto_begin_section): Do not print section
12521 name for noaddr and unnumbered dumps.
12522
12523 2018-06-25 Richard Biener <rguenther@suse.de>
12524
12525 * tree-vectorizer.h (struct vec_info_shared): New structure
12526 with parts split out from struct vec_info and loop_nest from
12527 struct _loop_vec_info.
12528 (struct vec_info): Adjust accordingly.
12529 (struct _loop_vec_info): Likewise.
12530 (LOOP_VINFO_LOOP_NEST): Adjust.
12531 (LOOP_VINFO_DATAREFS): Likewise.
12532 (LOOP_VINFO_DDRS): Likewise.
12533 (struct _bb_vec_info): Likewise.
12534 (BB_VINFO_DATAREFS): Likewise.
12535 (BB_VINFO_DDRS): Likewise.
12536 (struct _stmt_vec_info): Add dr_aux member.
12537 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
12538 (DR_MISALIGNMENT_UNINITIALIZED): New.
12539 (set_dr_misalignment): Adjust.
12540 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
12541 (vect_analyze_loop): Adjust prototype.
12542 (vect_analyze_loop_form): Likewise.
12543 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
12544 Compute dependences lazily.
12545 (vect_record_base_alignments): Use shared datarefs/ddrs.
12546 (vect_verify_datarefs_alignment): Likewise.
12547 (vect_analyze_data_refs_alignment): Likewise.
12548 (vect_analyze_data_ref_accesses): Likewise.
12549 (vect_analyze_data_refs): Likewise.
12550 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
12551 constructor parameter for shared part.
12552 (vect_analyze_loop_form): Pass in shared part and adjust.
12553 (vect_analyze_loop_2): Pass in storage for the number of
12554 stmts. Move loop nest finding to the caller. Compute
12555 datarefs lazily.
12556 (vect_analyze_loop): Pass in shared part.
12557 (vect_transform_loop): Verify shared datarefs are unchanged.
12558 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
12559 constructor parameter for shared part.
12560 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
12561 (vect_slp_bb): Verify shared datarefs are unchanged before
12562 transform.
12563 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
12564 change.
12565 (new_stmt_vec_info): Initialize DR_AUX misalignment to
12566 DR_MISALIGNMENT_UNINITIALIZED.
12567 * tree-vectorizer.c (vec_info::vec_info): Add constructor
12568 parameter for shared part.
12569 (vec_info::~vec_info): Adjust.
12570 (vec_info_shared::vec_info_shared): New.
12571 (vec_info_shared::~vec_info_shared): Likewise.
12572 (vec_info_shared::save_datarefs): Likewise.
12573 (vec_info_shared::check_datarefs): Likewise.
12574 (try_vectorize_loop_1): Construct shared part live for analyses
12575 of a single loop for multiple vector sizes.
12576 * tree-parloops.c (gather_scalar_reductions): Adjust.
12577
12578 2018-06-25 Richard Biener <rguenther@suse.de>
12579
12580 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
12581 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
12582 (vect_analyze_data_refs): Remove similar code from here and
12583 simplify accordingly.
12584
12585 2018-06-25 Richard Biener <rguenther@suse.de>
12586
12587 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
12588 for reverse storage order accesses rather than asserting
12589 they cannot happen here.
12590
12591 2018-06-25 Tom de Vries <tdevries@suse.de>
12592
12593 PR debug/86257
12594 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
12595 Use data16 instead of .byte for insn prefix.
12596
12597 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
12598
12599 PR C++/86082
12600 * parser.c (make_char_string_pack): Pass this literal chars
12601 through cpp_interpret_string.
12602 (cp_parser_userdef_numeric_literal): Check the result of
12603 make_char_string_pack.
12604
12605 2018-06-24 Maya Rashish <coypu@sdf.org>
12606
12607 * ginclude/stddef.h: Simplify conditions around avoiding
12608 re-definition of __size_t.
12609
12610 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12611
12612 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
12613 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
12614
12615 2018-06-22 Maya Rashish <coypu@sdf.org>
12616
12617 * doc/invoke.texi (mno-fancy-math-387): Update for changes
12618 made to OpenBSD and NetBSD through the years.
12619
12620 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
12621
12622 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12623 behavior of vec_pack (vector double, vector double) to match
12624 behavior of vec_float2 (vector double, vector double).
12625
12626 2018-06-22 Olivier Hainque <hainque@adacore.com>
12627
12628 * gimplify.c (gimplify_function_tree): Prevent creation
12629 of a trampoline for the address of the current function
12630 passed to entry/exit instrumentation hooks.
12631
12632 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
12633
12634 PR target/86222
12635 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
12636 correctly.
12637
12638 2018-06-22 Martin Liska <mliska@suse.cz>
12639
12640 PR tree-optimization/86263
12641 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12642 Bail out if is_enabled is false.
12643 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
12644 New declaration.
12645 (jump_table_cluster::is_enabled): New function.
12646
12647 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12648
12649 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
12650 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
12651 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
12652 (lto_input_ts_binfo_tree_pointers): Likewise.
12653 * tree-streamer-out.c (streamer_write_tree_bitfields,
12654 write_ts_binfo_tree_pointers): Likewise.
12655 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
12656
12657 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12658
12659 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
12660
12661 2018-06-22 Martin Liska <mliska@suse.cz>
12662
12663 * symbol-summary.h (get): Make it pure and inline move
12664 functionality from ::get function.
12665 (get): Remove and inline into ::get and ::get_create.
12666 (get_create): Move code from ::get function.
12667
12668 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12669
12670 PR target/85994
12671 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
12672 -x assembler-with-cpp.
12673
12674 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12675
12676 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
12677 _FILE_OFFSET_BITS=64 for C++.
12678
12679 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
12680
12681 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
12682 conversion insn that shows up when pr85657-3.c is compiled using
12683 IEEE 128-bit long double.
12684 (neg<mode>2_internal): Use the correct mode to check whether the
12685 mode is IBM extended.
12686 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
12687 multiply and divide external functions from being created more
12688 than once.
12689
12690 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12691
12692 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
12693 functions.
12694 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
12695 the edge can be forwarded.
12696 (cfg_layout_merge_blocks): Likewise.
12697
12698 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12699
12700 * except.c (finish_eh_generation): Commit edge insertions only after
12701 the EH edges have been redirected from post-landing to landing pads.
12702
12703 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12704
12705 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
12706 create_tmp_var_for to create the FRAME decl.
12707 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
12708
12709 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12710
12711 * tree-inline.c (copy_edges_for_bb): Minor tweak.
12712 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
12713 debug statement when resetting its value.
12714 (expand_call_inline): Copy the locus of the call onto the assignment
12715 of the return value, if any. Use local variable in more cases.
12716
12717 2018-06-21 Martin Liska <mliska@suse.cz>
12718
12719 * ipa-pure-const.c (propagate_nothrow): Use
12720 funct_state_summaries->get.
12721 (dump_malloc_lattice): Likewise.
12722 (propagate_malloc): Likewise.
12723
12724 2018-06-21 Richard Biener <rguenther@suse.de>
12725
12726 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
12727 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
12728 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
12729 comment.
12730 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
12731 BLOCK_ABSTRACT_ORIGIN unconditionally.
12732
12733 2018-06-21 David Malcolm <dmalcolm@redhat.com>
12734
12735 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
12736 deleting it.
12737 * ipa-reference.c (ipa_reference_c_finalize): Delete
12738 ipa_ref_opt_sum_summaries and set it to NULL.
12739
12740 2018-06-21 Tom de Vries <tdevries@suse.de>
12741
12742 PR tree-optimization/85859
12743 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
12744 test with comment from bb_no_side_effects_p.
12745
12746 2018-06-21 Richard Biener <rguenther@suse.de>
12747
12748 PR tree-optimization/86232
12749 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
12750 max for constant niter.
12751
12752 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12753
12754 * config/aarch64/aarch64-simd.md
12755 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
12756
12757 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12758
12759 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
12760 Make opernads of the unspec commutative.
12761
12762 2018-06-21 Richard Biener <rguenther@suse.de>
12763
12764 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
12765 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
12766 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
12767 (vect_analyze_data_ref_dependence): Re-order checks to deal with
12768 NULL DR_STEP.
12769 (vect_record_base_alignments): Do not record base alignment
12770 for gathers or scatters.
12771 (vect_compute_data_ref_alignment): Drop return value that is always
12772 true. Bail out early for gathers or scatters.
12773 (vect_enhance_data_refs_alignment): Bail out early for gathers
12774 or scatters.
12775 (vect_find_same_alignment_drs): Likewise.
12776 (vect_analyze_data_refs_alignment): Remove dead code.
12777 (vect_slp_analyze_and_verify_node_alignment): Likewise.
12778 (vect_analyze_data_refs): For possible gathers or scatters do
12779 not create an alternate DR, just check their possible validity
12780 and mark them. Adjust DECL_NONALIASED handling to not rely
12781 on DR_BASE_ADDRESS.
12782 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
12783 update inits of gathers or scatters.
12784 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
12785 Also copy gather/scatter flag to pattern vinfo.
12786
12787 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
12788
12789 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12790 behavior of vec_packsu (vector unsigned long long, vector unsigned
12791 long long) to match behavior of vec_packs with same signature.
12792
12793 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
12794 Thomas Schwinge <thomas@codesourcery.com>
12795 Cesar Philippidis <cesar@codesourcery.com>
12796
12797 * gimplify.c (gimplify_scan_omp_clauses): Add support for
12798 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12799 (gimplify_adjust_omp_clauses): Likewise.
12800 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
12801 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
12802 (gimplify_omp_target_update): Update handling of acc update and
12803 enter/exit data.
12804 * omp-low.c (install_var_field): Remove unused parameter
12805 base_pointers_restrict.
12806 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
12807 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
12808 FINALIZE}
12809 (omp_target_base_pointers_restrict_p): Delete.
12810 (scan_omp_target): Update call to scan_sharing_clauses.
12811 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
12812 FINALIZE}.
12813 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
12814 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12815 (convert_local_omp_clauses): Likewise.
12816 * tree-pretty-print.c (dump_omp_clause): Likewise.
12817 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
12818 FINALIZE}.
12819 (omp_clause_code_name): Likewise.
12820
12821 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12822
12823 PR debug/86194
12824 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
12825 be narrowed.
12826
12827 PR tree-optimization/86231
12828 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
12829 anti-range don't overwrite *vr0min before using it to compute *vr0max.
12830
12831 2018-06-20 Tom de Vries <tdevries@suse.de>
12832
12833 PR tree-optimization/86097
12834 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
12835 iv type if signedness of iv type is not the same as that of *nit.
12836
12837 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12838
12839 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
12840 EDGE_EH edges, verify they are all EDGE_EH.
12841
12842 2018-06-20 Maya Rashish <coypu@sdf.org>
12843
12844 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
12845
12846 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12847
12848 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
12849 * config/aarch64/aarch64.c (xgene1_tunings): Add
12850 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
12851 (aarch64_mode_valid_for_sched_fusion_p):
12852 Allow 16-byte modes.
12853 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
12854 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
12855 128-bit modes.
12856 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
12857 New pattern.
12858 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
12859 * config/aarch64/iterators.md (VQ2): New mode iterator.
12860
12861 2018-06-20 Martin Liska <mliska@suse.cz>
12862
12863 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
12864 Change default ratio from 10 to 8.
12865
12866 2018-06-20 Martin Liska <mliska@suse.cz>
12867
12868 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12869 New.
12870 (bit_test_cluster::find_bit_tests): Likewise.
12871 (switch_decision_tree::analyze_switch_statement): Find clusters.
12872 * tree-switch-conversion.h (struct jump_table_cluster): Document
12873 hierarchy.
12874
12875 2018-06-20 Martin Liska <mliska@suse.cz>
12876
12877 * tree-switch-conversion.c (switch_conversion::collect):
12878 Record m_uniq property.
12879 (switch_conversion::expand): Bail out for special conditions.
12880 (group_cluster::~group_cluster): New.
12881 (group_cluster::group_cluster): Likewise.
12882 (group_cluster::dump): Likewise.
12883 (jump_table_cluster::emit): New.
12884 (switch_decision_tree::fix_phi_operands_for_edges): New.
12885 (struct case_node): Remove struct.
12886 (jump_table_cluster::can_be_handled): New.
12887 (case_values_threshold): Moved to header.
12888 (reset_out_edges_aux): Likewise.
12889 (jump_table_cluster::is_beneficial): New.
12890 (bit_test_cluster::can_be_handled): Likewise.
12891 (add_case_node): Remove.
12892 (bit_test_cluster::is_beneficial): New.
12893 (case_bit_test::cmp): New.
12894 (bit_test_cluster::emit): New.
12895 (expand_switch_as_decision_tree_p): Remove.
12896 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
12897 (fix_phi_operands_for_edge): Likewise.
12898 (switch_decision_tree::analyze_switch_statement): New.
12899 (compute_cases_per_edge): Move ...
12900 (switch_decision_tree::compute_cases_per_edge): ... here.
12901 (try_switch_expansion): Likewise.
12902 (switch_decision_tree::try_switch_expansion): Likewise.
12903 (record_phi_operand_mapping): Likewise.
12904 (switch_decision_tree::record_phi_operand_mapping): Likewise.
12905 (emit_case_decision_tree): Likewise.
12906 (switch_decision_tree::emit): Likewise.
12907 (balance_case_nodes): Likewise.
12908 (switch_decision_tree::balance_case_nodes): Likewise.
12909 (dump_case_nodes): Likewise.
12910 (switch_decision_tree::dump_case_nodes): Likewise.
12911 (emit_jump): Likewise.
12912 (switch_decision_tree::emit_jump): Likewise.
12913 (emit_cmp_and_jump_insns): Likewise.
12914 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
12915 (emit_case_nodes): Likewise.
12916 (switch_decision_tree::emit_case_nodes): Likewise.
12917 (conditional_probability): Remove.
12918 * tree-switch-conversion.h (enum cluster_type): New.
12919 (PRINT_CASE): New.
12920 (struct cluster): Likewise.
12921 (cluster::cluster): Likewise.
12922 (struct simple_cluster): Likewise.
12923 (simple_cluster::simple_cluster): Likewise.
12924 (struct group_cluster): Likewise.
12925 (struct jump_table_cluster): Likewise.
12926 (struct bit_test_cluster): Likewise.
12927 (struct min_cluster_item): Likewise.
12928 (struct case_tree_node): Likewise.
12929 (case_tree_node::case_tree_node): Likewise.
12930 (jump_table_cluster::case_values_threshold): Likewise.
12931 (struct case_bit_test): Likewise.
12932 (struct switch_decision_tree): Likewise.
12933 (struct switch_conversion): Likewise.
12934 (switch_decision_tree::reset_out_edges_aux): Likewise.
12935
12936 2018-06-20 Martin Liska <mliska@suse.cz>
12937
12938 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
12939 (hoist_edge_and_branch_if_true): Likewise.
12940 (expand_switch_using_bit_tests_p): Likewise.
12941 (struct case_bit_test): Likewise.
12942 (case_bit_test_cmp): Likewise.
12943 (emit_case_bit_tests): Likewise.
12944 (switch_conversion::switch_conversion): New class.
12945 (struct switch_conv_info): Remove old struct.
12946 (collect_switch_conv_info): More to ...
12947 (switch_conversion::collect): ... this.
12948 (check_range): Likewise.
12949 (switch_conversion::check_range): Likewise.
12950 (check_all_empty_except_final): Likewise.
12951 (switch_conversion::check_all_empty_except_final): Likewise.
12952 (check_final_bb): Likewise.
12953 (switch_conversion::check_final_bb): Likewise.
12954 (create_temp_arrays): Likewise.
12955 (switch_conversion::create_temp_arrays): Likewise.
12956 (free_temp_arrays): Likewise.
12957 (gather_default_values): Likewise.
12958 (switch_conversion::gather_default_values): Likewise.
12959 (build_constructors): Likewise.
12960 (switch_conversion::build_constructors): Likewise.
12961 (constructor_contains_same_values_p): Likewise.
12962 (switch_conversion::contains_same_values_p): Likewise.
12963 (array_value_type): Likewise.
12964 (switch_conversion::array_value_type): Likewise.
12965 (build_one_array): Likewise.
12966 (switch_conversion::build_one_array): Likewise.
12967 (build_arrays): Likewise.
12968 (switch_conversion::build_arrays): Likewise.
12969 (gen_def_assigns): Likewise.
12970 (switch_conversion::gen_def_assigns): Likewise.
12971 (prune_bbs): Likewise.
12972 (switch_conversion::prune_bbs): Likewise.
12973 (fix_phi_nodes): Likewise.
12974 (switch_conversion::fix_phi_nodes): Likewise.
12975 (gen_inbound_check): Likewise.
12976 (switch_conversion::gen_inbound_check): Likewise.
12977 (process_switch): Use the newly created class.
12978 (switch_conversion::expand): New.
12979 (switch_conversion::~switch_conversion): New.
12980 * tree-switch-conversion.h: New file.
12981
12982 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12983
12984 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
12985 tree-vect-patterns.c.
12986 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
12987 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
12988 (vect_recog_sad_pattern): Likewise.
12989 (vect_recog_widen_sum_pattern): Likewise.
12990 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
12991 (vect_recog_widen_shift_pattern): Remove the type_in argument.
12992 (vect_recog_rotate_pattern): Likewise.
12993 (vect_recog_mult_pattern): Likewise.
12994 (vect_recog_vector_vector_shift_pattern): Likewise.
12995 (vect_recog_divmod_pattern): Likewise.
12996 (vect_recog_mixed_size_cond_pattern): Likewise.
12997 (vect_recog_bool_pattern): Likewise.
12998 (vect_recog_mask_conversion_pattern): Likewise.
12999 (vect_try_gather_scatter_pattern): Likewise.
13000 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
13001 (vect_recog_over_widening_pattern): Likewise.
13002 (vect_recog_gather_scatter_pattern): Likewise.
13003 (vect_recog_func_ptr): Move from tree-vectorizer.h
13004 (vect_vect_recog_func_ptrs): Move further down the file.
13005 (vect_recog_func): Likewise. Remove the third argument.
13006 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
13007 (vect_pattern_recog_1): Expect the pattern function to do any
13008 necessary target tests. Also expect it to provide a vector type.
13009 Remove the type_in handling.
13010
13011 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13012
13013 * tree-vect-patterns.c (vect_pattern_detected): New function.
13014 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
13015 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
13016 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
13017 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
13018 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
13019 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
13020 (vect_recog_mask_conversion_pattern)
13021 (vect_try_gather_scatter_pattern): Likewise.
13022
13023 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13024
13025 * tree-vect-patterns.c (vect_get_internal_def): New function.
13026 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
13027 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
13028 (search_type_for_mask_1): Use it.
13029
13030 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13031
13032 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
13033 redundant WIDEN_SUM_EXPR handling.
13034 (vect_recog_sad_pattern): Likewise.
13035
13036 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13037
13038 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
13039 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
13040 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
13041 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
13042 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
13043
13044 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13045
13046 * tree-vect-stmts.c (vectorizable_call): Make sure that we
13047 use the stmt_vec_info of the original bb statement for the
13048 new zero assignment, even if the call is part of a pattern.
13049
13050 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13051
13052 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
13053 that the sequence is attached to the original statement rather
13054 than the pattern statement.
13055 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
13056 PATTERN_DEF_SEQ from the original statement rather than
13057 the main pattern statement.
13058 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
13059 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
13060 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
13061
13062 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
13063
13064 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
13065 definition statements before the early exit for statements that aren't
13066 live or relevant.
13067 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
13068 split out from...
13069 (vect_transform_loop): ...here. Process pattern definition
13070 statements without first checking whether the main pattern
13071 statement is live or relevant.
13072
13073 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
13074
13075 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
13076 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
13077
13078 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
13079
13080 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
13081 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
13082 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
13083 (expand_block_compare): Change select_block_compare_mode call.
13084 (expand_strncmp_align_check): Use new functions, fix comment.
13085 (emit_final_str_compare_gpr): New function.
13086 (expand_strn_compare): Refactor and clean up code.
13087 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
13088
13089 2018-06-19 Tony Reix <tony.reix@atos.com>
13090 Damien Bergamini <damien.bergamini@atos.com>
13091 David Edelsohn <dje.gcc@gmail.com>
13092
13093 * collect2.c (static_obj): New variable.
13094 (static_libs): New variable.
13095 (is_in_list): Uncomment declaration.
13096 (main): Track AIX libraries linked statically.
13097 (is_in_list): Uncomment definition.
13098 (scan_prog_file): Don't add AIX shared libraries initializer
13099 to constructor list if linking statically.
13100
13101 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
13102
13103 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
13104 constant.
13105 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
13106
13107 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
13108
13109 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
13110 blocks.
13111
13112 2018-06-19 Martin Liska <mliska@suse.cz>
13113
13114 * config/i386/i386.c (ix86_can_inline_p): Do not use
13115 ipa_fn_summaries::get_create.
13116 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
13117 get.
13118 (devirtualization_time_bonus): Likewise.
13119 (ipcp_propagate_stage): Likewise.
13120 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
13121 (edge_set_predicate): Likewise.
13122 (evaluate_conditions_for_known_args): Likewise.
13123 (evaluate_properties_for_edge): Likewise.
13124 (ipa_call_summary::reset): Tranform to ...
13125 (ipa_call_summary::~ipa_call_summary): ... this.
13126 (ipa_fn_summary::reset): Transform to ...
13127 (ipa_fn_summary::~ipa_fn_summary): ... this.
13128 (ipa_fn_summary_t::remove): Rename to ...
13129 (ipa_fn_summary_t::remove_callees): ... this.
13130 (ipa_fn_summary_t::duplicate): Use placement new
13131 instead of memory copy.
13132 (ipa_call_summary_t::duplicate): Likewise.
13133 (ipa_call_summary_t::remove): Remove.
13134 (dump_ipa_call_summary): Change get_create to get.
13135 (ipa_dump_fn_summary): Dump only when summary exists.
13136 (analyze_function_body): Use symbol_summary::get instead
13137 of get_create.
13138 (compute_fn_summary): Likewise.
13139 (estimate_edge_devirt_benefit): Likewise.
13140 (estimate_edge_size_and_time): Likewise.
13141 (inline_update_callee_summaries): Likewise.
13142 (remap_edge_change_prob): Likewise.
13143 (remap_edge_summaries): Likewise.
13144 (ipa_merge_fn_summary_after_inlining): Likewise.
13145 (write_ipa_call_summary): Likewise.
13146 (ipa_fn_summary_write): Likewise.
13147 (ipa_free_fn_summary): Likewise.
13148 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
13149 (struct ipa_call_summary): Likewise.
13150 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
13151 of get_create.
13152 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
13153 (estimate_size_after_inlining): Likewise.
13154 (estimate_growth): Likewise.
13155 (growth_likely_positive): Likewise.
13156 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
13157 (inline_call): Likewise.
13158 * ipa-inline.c (caller_growth_limits): Likewise.
13159 (can_inline_edge_p): Likewise.
13160 (can_inline_edge_by_limits_p): Likewise.
13161 (compute_uninlined_call_time): Likewise.
13162 (compute_inlined_call_time): Likewise.
13163 (want_inline_small_function_p): Likewise.
13164 (edge_badness): Likewise.
13165 (update_caller_keys): Likewise.
13166 (update_callee_keys): Likewise.
13167 (inline_small_functions): Likewise.
13168 (inline_to_all_callers_1): Likewise.
13169 (dump_overall_stats): Likewise.
13170 (early_inline_small_functions): Likewise.
13171 (early_inliner): Likewise.
13172 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13173 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
13174 * ipa-pure-const.c (malloc_candidate_p): Likewise.
13175 * ipa-split.c (execute_split_functions): Likewise.
13176 * symbol-summary.h: Likewise.
13177 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
13178
13179 2018-06-19 Richard Biener <rguenther@suse.de>
13180
13181 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
13182 (vectorize_loops): ... here. Fix dbgcnt handling.
13183 (try_vectorize_loop): Wrap try_vectorize_loop_1.
13184
13185 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
13186
13187 PR target/86197
13188 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
13189 ieee128 argument takes up only one (vector) register, not two (floating
13190 point) registers.
13191
13192 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
13193
13194 * gimplify.c (gimplify_init_constructor): Really never clear for an
13195 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
13196
13197 2018-06-19 Richard Biener <rguenther@suse.de>
13198
13199 PR tree-optimization/86179
13200 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
13201 after failed recognition.
13202
13203 2018-06-18 Martin Sebor <msebor@redhat.com>
13204
13205 PR middle-end/85602
13206 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
13207 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
13208 Handle integer subtraction.
13209 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
13210 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
13211
13212 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13213
13214 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
13215 param from rtx to rtx_insn *.
13216 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
13217 param.
13218 (frv_ifcvt_modify_insn): Likwise.
13219 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
13220 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
13221 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
13222 as_a <rtx_insn *> cast to local "unprotected_region" once
13223 it's been established that it's not NULL or pc_rtx.
13224 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
13225 param "sethi" from rtx to rtx_insn *.
13226 (nds32_group_float_insns): Likewise for param "insn".
13227 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
13228 param.
13229 (vax_output_int_subtract): Likewise.
13230 * config/vax/vax.c (vax_output_int_add): Likewise for param
13231 "insn".
13232 (vax_output_int_subtract): Likewise.
13233 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
13234 (emit_pattern_after): Likewise for param "after".
13235 (emit_insn_after): Likewise.
13236 (emit_jump_insn_after): Likewise.
13237 (emit_call_insn_after): Likewise.
13238 (emit_debug_insn_after): Likewise.
13239 (emit_pattern_before): Likewise for param "before".
13240 (emit_insn_before): Likewise.
13241 (emit_jump_insn_before): Likewise.
13242 * final.c (get_insn_template): Likewise for param "insn", removing
13243 a cast.
13244 * output.h (get_insn_template): Likewise for 2nd param.
13245 * rtl.h (emit_insn_before): Likewise.
13246 (emit_jump_insn_before): Likewise.
13247 (emit_debug_insn_before_noloc): Likewise.
13248 (emit_insn_after): Likewise.
13249 (emit_jump_insn_after): Likewise.
13250 (emit_call_insn_after): Likewise.
13251 (emit_debug_insn_after): Likewise.
13252 (set_insn_deleted): Likewise for param.
13253
13254 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
13255
13256 PR target/85358
13257 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
13258 floating point modes, so that IFmode is numerically greater than
13259 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
13260 to declare the ordering. This prevents IFmode from being
13261 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
13262 machine. Include rs6000-modes.h to share the fractional values
13263 between genmodes* and the rest of the compiler.
13264 (IFmode): Likewise.
13265 (KFmode): Likewise.
13266 (TFmode): Likewise.
13267 * config/rs6000/rs6000-modes.h: New file.
13268 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
13269 meaning of rs6000_long_double_size so that 126..128 selects an
13270 appropriate 128-bit floating point type.
13271 (rs6000_option_override_internal): Likewise.
13272 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
13273 (TARGET_LONG_DOUBLE_128): Change the meaning of
13274 rs6000_long_double_size so that 126..128 selects an appropriate
13275 128-bit floating point type.
13276 (LONG_DOUBLE_TYPE_SIZE): Update comment.
13277 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
13278 source and destination to match the standard usage.
13279 (truncifkf2): Likewise.
13280 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
13281 ISA 2.07 to use an explicit clobber, instead of passing in a
13282 temporary.
13283 (copysign<mode>3_soft): Likewise.
13284
13285 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13286
13287 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
13288 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
13289 (vect_slp_analyze_instance_dependence): Likewise.
13290 (vect_enhance_data_refs_alignment): Likewise.
13291 (vect_analyze_data_refs_alignment): Likewise.
13292 (vect_slp_analyze_and_verify_instance_alignment
13293 (vect_analyze_data_ref_accesses): Likewise.
13294 (vect_prune_runtime_alias_test_list): Likewise.
13295 (vect_analyze_data_refs): Likewise.
13296 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
13297 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
13298 (vect_analyze_scalar_cycles_1): Likewise.
13299 (vect_get_loop_niters): Likewise.
13300 (vect_analyze_loop_form_1): Likewise.
13301 (vect_update_vf_for_slp): Likewise.
13302 (vect_analyze_loop_operations): Likewise.
13303 (vect_analyze_loop): Likewise.
13304 (vectorizable_induction): Likewise.
13305 (vect_transform_loop): Likewise.
13306 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
13307 * tree-vect-slp.c (vect_analyze_slp): Likewise.
13308 (vect_make_slp_decision): Likewise.
13309 (vect_detect_hybrid_slp): Likewise.
13310 (vect_slp_analyze_operations): Likewise.
13311 (vect_slp_bb): Likewise.
13312 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
13313 (vectorizable_bswap): Likewise.
13314 (vectorizable_call): Likewise.
13315 (vectorizable_simd_clone_call): Likewise.
13316 (vectorizable_conversion): Likewise.
13317 (vectorizable_assignment): Likewise.
13318 (vectorizable_shift): Likewise.
13319 (vectorizable_operation): Likewise.
13320 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
13321
13322 2018-06-18 Martin Sebor <msebor@redhat.com>
13323
13324 PR tree-optimization/81384
13325 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
13326 * builtins.c (expand_builtin_strnlen): New function.
13327 (expand_builtin): Call it.
13328 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
13329 * builtins.def (BUILT_IN_STRNLEN): New.
13330 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
13331 Warn for bounds in excess of maximum object size.
13332 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
13333 single-value ranges. Handle strnlen.
13334 (handle_builtin_strlen): Handle strnlen.
13335 (strlen_check_and_optimize_stmt): Same.
13336 * doc/extend.texi (Other Builtins): Document strnlen.
13337
13338 2018-06-18 Maya Rashish <coypu@sdf.org>
13339
13340 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
13341 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
13342 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
13343
13344 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
13345 here to ...
13346 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
13347
13348 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13349
13350 * tree.c (escaped_string::escape): Replace cast to char * by
13351 const_cast<char *> (unescaped).
13352
13353 2018-06-18 Nick Clifton <nickc@redhat.com>
13354
13355 PR 84195
13356 * tree.c (escaped_string): New class. Converts an unescaped
13357 string into its escaped equivalent.
13358 (warn_deprecated_use): Use the new class to convert the
13359 deprecation message, if present.
13360 (test_escaped_strings): New self test.
13361 (test_c_tests): Add test_escaped_strings.
13362 * doc/extend.texi (deprecated): Add a note that the
13363 deprecation message is affected by the -fmessage-length
13364 option, and that control characters will be escaped.
13365 (#pragma GCC error): Document this pragma.
13366 (#pragma GCC warning): Likewise.
13367 * doc/invoke.texi (-fmessage-length): Document this option's
13368 effect on the #warning and #error preprocessor directives and
13369 the deprecated attribute.
13370
13371 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
13372
13373 * tree.c (decl_value_expr_lookup): Revert latest change.
13374 (decl_value_expr_insert): Likewise.
13375
13376 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
13377
13378 * gimplify.c (nonlocal_vlas): Delete.
13379 (nonlocal_vla_vars): Likewise.
13380 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
13381 referenced VLAs.
13382 (gimplify_body): Do not create and destroy nonlocal_vlas.
13383 * tree-nested.c: Include diagnostic.h.
13384 (use_pointer_in_frame): Tweak.
13385 (lookup_field_for_decl): Add assertion and declare the transformation.
13386 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
13387 internal error when the reference is in a wrong context. Do not
13388 create a debug decl by default.
13389 (note_nonlocal_block_vlas): Delete.
13390 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
13391 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
13392 create a debug decl by default.
13393 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
13394 call is in a wrong context.
13395 (fixup_vla_decls): New function.
13396 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
13397 debug variables were created.
13398 * tree.c (decl_value_expr_lookup): Add checking assertion.
13399 (decl_value_expr_insert): Likewise.
13400
13401 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13402
13403 PR middle-end/82479
13404 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
13405 * tree-scalar-evolution.c (interpret_expr): Likewise.
13406 (expression_expensive_p): Likewise.
13407 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
13408 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
13409 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
13410 (ssa_defined_by_minus_one_stmt_p): New.
13411
13412 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13413
13414 PR middle-end/64946
13415 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
13416 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
13417 * dojump.c (do_jump): Likewise.
13418 * expr.c (expand_expr_real_2): Check operand type's sign.
13419 * fold-const.c (const_unop): Handle ABSU_EXPR.
13420 (fold_abs_const): Likewise.
13421 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
13422 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
13423 (strip_sign_op_1): Likesise.
13424 * match.pd: Add new pattern to generate ABSU_EXPR.
13425 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
13426 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
13427 * tree-eh.c (operation_could_trap_helper_p): Likewise.
13428 * tree-inline.c (estimate_operator_cost): Likewise.
13429 * tree-pretty-print.c (dump_generic_node): Likewise.
13430 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
13431 * tree.def (ABSU_EXPR): New.
13432
13433 2018-06-16 Jakub Jelinek <jakub@redhat.com>
13434
13435 PR middle-end/86095
13436 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
13437 documented as preserved for backward compatibility only.
13438 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
13439
13440 PR rtl-optimization/86108
13441 * bb-reorder.c (create_forwarder_block): Renamed to ...
13442 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
13443 jump from new landing pad to the second part.
13444 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
13445 Adjust callers.
13446
13447 2018-06-15 Jakub Jelinek <jakub@redhat.com>
13448
13449 PR middle-end/85878
13450 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
13451 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
13452 Only call store_expr for halves if the mode is the same.
13453
13454 PR middle-end/86123
13455 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
13456 Fix up comment formatting.
13457
13458 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
13459
13460 * typed-splay-tree.h (typed_splay_tree::remove): New function.
13461 (typed_splay_tree::closure,
13462 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
13463 (typed_splay_tree::typed_splay_tree,
13464 typed_splay_tree::operator =): Declared private.
13465 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
13466 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
13467 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
13468 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
13469 typed_splay_tree::splay_tree_splay,
13470 typed_splay_tree::splay_tree_foreach_helper,
13471 typed_splay_tree::splay_tree_insert,
13472 typed_splay_tree::splay_tree_remove,
13473 typed_splay_tree::splay_tree_lookup,
13474 typed_splay_tree::splay_tree_predecessor,
13475 typed_splay_tree::splay_tree_successor,
13476 typed_splay_tree::splay_tree_min,
13477 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
13478 (typed_splay_tree::root, typed_splay_tree::comp,
13479 typed_splay_tree::delete_key,
13480 typed_splay_tree::delete_value): New data members.
13481 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
13482 typed_splay_tree::remove.
13483
13484 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
13485
13486 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
13487 -mginv and -mno-ginv to the assembler.
13488 * config/mips/mips.opt (-mcrc): New option.
13489 (-mginv): Likewise.
13490 * doc/invoke.text (-mcrc): Document.
13491 (-mginv): Likewise.
13492
13493 2018-06-15 Nick Clifton <nickc@redhat.com>
13494
13495 PR 84195
13496 * tree.c (escaped_string): New class. Converts an unescaped
13497 string into its escaped equivalent.
13498 (warn_deprecated_use): Use the new class to convert the
13499 deprecation message, if present.
13500 (test_escaped_strings): New self test.
13501 (test_c_tests): Add test_escaped_strings.
13502 * doc/extend.texi (deprecated): Add a note that the
13503 deprecation message is affected by the -fmessage-length
13504 option, and that control characters will be escaped.
13505 (#pragma GCC error): Document this pragma.
13506 (#pragma GCC warning): Likewise.
13507 * doc/invoke.texi (-fmessage-length): Document this option's
13508 effect on the #warning and #error preprocessor directives and
13509 the deprecated attribute.
13510
13511 2018-06-15 Richard Biener <rguenther@suse.de>
13512
13513 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
13514 here, also noting vector size used.
13515 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
13516 size used in MSG_OPTIMIZED_LOCATIONS dump.
13517 (pass_slp_vectorize::execute): Adjust.
13518
13519 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
13520
13521 PR target/85968
13522 * config/arc/arc.c (arc_return_address_register): Fix
13523 if-condition.
13524
13525 2018-06-15 Richard Biener <rguenther@suse.de>
13526
13527 PR middle-end/86159
13528 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
13529 leave useless conversion stripping to force_gimple_operand_gsi.
13530 (gimplify_build2): Likewise.
13531 (gimplify_build1): Likewise.
13532
13533 2018-06-15 Richard Biener <rguenther@suse.de>
13534
13535 PR middle-end/86076
13536 * tree-cfg.c (move_stmt_op): unshare invariant addresses
13537 before adjusting their block.
13538
13539 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
13540
13541 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
13542 multilibs for *-*-rtems*.
13543 * config/riscv/t-rtems: New file.
13544
13545 2018-06-14 Jakub Jelinek <jakub@redhat.com>
13546
13547 PR middle-end/86122
13548 * match.pd ((A +- CST1) +- CST2): Punt if last resort
13549 unsigned_type_for returns NULL.
13550
13551 PR target/85945
13552 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
13553 subregs of multi-word pseudos unless the float mode has word size.
13554
13555 2018-06-14 Richard Biener <rguenther@suse.de>
13556
13557 PR middle-end/86139
13558 * tree-vect-generic.c (build_word_mode_vector_type): Remove
13559 duplicate and harmful type_hash_canon.
13560 * tree.c (type_hash_canon): Assert we didn't find ourselves.
13561
13562 2018-06-14 Richard Biener <rguenther@suse.de>
13563
13564 PR ipa/86124
13565 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
13566 NULL cgraph_node.
13567
13568 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
13569
13570 * config/rtems.h (STDINT_LONG32): Define.
13571
13572 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
13573 Prachi Godbole <prachi.godbole@imgtec.com>
13574
13575 * config/mips/mips-cpus.def: Define P6600.
13576 * config/mips/mips-tables.opt: Regenerate.
13577 * config/mips/mips.c (mips_ucbranch_type): New enum.
13578 (mips_rtx_cost_data): Add support for P6600.
13579 (mips_issue_rate): Likewise.
13580 (mips_multipass_dfa_lookahead): Likewise.
13581 (mips_avoid_hazard): Likewise.
13582 (mips_reorg_process_insns): Likewise.
13583 (mips_classify_branch_p6600): New function.
13584 * config/mips/mips.h (TUNE_P6600): New define.
13585 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
13586 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
13587 * config/mips/mips.md: Include p6600.md.
13588 (processor): Add p6600.
13589 * config/mips/p6600.md: New file.
13590 * doc/invoke.texi: Add p6600 to supported architectures.
13591
13592 2018-06-13 Martin Sebor <msebor@redhat.com>
13593
13594 PR tree-optimization/86114
13595 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
13596 of integer types.
13597 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
13598
13599 2018-06-13 Richard Biener <rguenther@suse.de>
13600
13601 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
13602 Properly set vector type of the intermediate stmt.
13603 * tree-vect-stmts.c (vectorizable_operation): The destination
13604 var always has vectype_out type.
13605
13606 2018-06-13 Jeff Law <law@redhat.com>
13607
13608 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
13609 integer 0 for argument to print_rtl_with_bb.
13610 (rl78_reorg): Likewise.
13611
13612 2018-06-13 David Malcolm <dmalcolm@redhat.com>
13613
13614 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
13615 from rtx to rtx_insn *.
13616 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
13617 "label".
13618 (add_sched_insns_for_speculation): Likewise for local "target",
13619 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13620 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
13621 from rtx_insn ** to rtx_code_label **.
13622 (reorg_emit_nops): Likewise.
13623 (c6x_reorg): Likewise for local "call_labels".
13624 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
13625 rtx to rtx_insn *.
13626 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
13627 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
13628 the loops over LABEL_REFS.
13629 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
13630 braf_label.
13631 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13632 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
13633 (split_branches): Strengthen local "olabel" from rtx to
13634 rtx_insn *, adding a safe_as_a cast.
13635 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
13636 to "rtx_insn *".
13637 (add_insn_after): Likewise for first two params.
13638 (add_insn_before): Likewise.
13639 (remove_insn): Likewise for param.
13640 (emit_pattern_before_noloc): Likewise for second and third params.
13641 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
13642 (emit_call_insn_before_noloc): Likewise.
13643 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
13644 to "rtx_insn *".
13645 (emit_barrier_before): Likewise.
13646 (emit_label_before): Strengthen "label" param from "rtx" to
13647 "rtx_code_label *". Strengthen "before" param from "rtx" to
13648 "rtx_insn *".
13649 (emit_insn_after_1): Strengthen "after" param from "rtx" to
13650 "rtx_insn *".
13651 (emit_pattern_after_noloc): Likewise.
13652 (emit_insn_after_noloc): Likewise.
13653 (emit_jump_insn_after_noloc): Likewise.
13654 (emit_call_insn_after_noloc): Likewise.
13655 (emit_debug_insn_after_noloc): Likewise.
13656 (emit_barrier_after): Likewise.
13657 (emit_label_after): Likewise for both params.
13658 (emit_pattern_after_setloc): Likewise for "after" param. Convert
13659 "loc" param from "int" to "location_t".
13660 (emit_insn_after_setloc): Likewise.
13661 (emit_jump_insn_after_setloc): Likewise.
13662 (emit_call_insn_after_setloc): Likewise.
13663 (emit_debug_insn_after_setloc): Likewise.
13664 (emit_pattern_before_setloc): Likewise for "before" param. Convert
13665 "loc" param from "int" to "location_t".
13666 (emit_pattern_before): Convert NULL_RTX to NULL.
13667 (emit_insn_before_setloc): Convert "loc" param from "int" to
13668 "location_t".
13669 (emit_jump_insn_before_setloc): Likewise.
13670 (emit_call_insn_before_setloc): Likewise.
13671 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
13672 rtx_insn *. Convert "loc" param from "int" to "location_t".
13673 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
13674 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
13675 Convert 3rd param from "int" to "location_t".
13676 (emit_barrier_before, emit_barrier_after, next_real_insn):
13677 Strengthen param from rtx to rtx_insn *.
13678 (emit_label_before): Strengthen 1st param from "rtx" to
13679 "rtx_code_label *". Strengthen 2nd param from "rtx" to
13680 "rtx_insn *".
13681 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
13682 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
13683 Strengthen 2nd param from "rtx" to "rtx_insn *".
13684 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
13685 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
13686 Likewise. Convert 3rd param from "int" to "location_t".
13687 (emit_label_after): Strengthen 1st param from "rtx" to
13688 "rtx_code_label *".
13689 (next_real_insn, remove_insn): Strengthen param from "rtx" to
13690 "rtx_insn *".
13691 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
13692 from "rtx" to "rtx_insn *".
13693
13694 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
13695
13696 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
13697 bodies streamed in with -Q.
13698 * dumpfile.c (dump_files): Add lto-stream-out dump file.
13699 * dumpfile.h (tree_dump_index): Add lto_stream_out.
13700 * gimple-streamer-out.c: Include gimple-pretty-print.h
13701 (output_bb): Dump stmts streamed.
13702 * lto-section-out.c: Include print-tree.h
13703 (lto_begin_section): Dump sections created.
13704 (lto_output_decl_index): Dump decl encoded.
13705 * lto-streamer-out.c: Include print-tree.h
13706 (create_output_block): Dump output block created.
13707 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
13708 (output_function): Dump function output.
13709 (output_constructor): Dump constructor streamed.
13710 (write_global_stream): Output indexes encoded.
13711 (produce_asm_for_decls): Dump streams encoded.
13712 * lto-streamer.c (streamer_dump_file): New global var.
13713 * lto-streamer.h (streamer_dump_file): Declare.
13714 * passes.c (ipa_write_summaries): Initialize streamer dump.
13715 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
13716 in.
13717
13718 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
13719
13720 PR target/86048
13721 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
13722 offsets for register save directives. Emit a second batch of save
13723 directives, if need be, when the function accesses prior frames.
13724
13725 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13726
13727 * config/arc/fpu.md (fmasf4): Force operand to register.
13728 (fnmasf4): Likewise.
13729
13730 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13731
13732 * config/arc/arc-protos.h (arc_pad_return): Remove.
13733 * config/arc/arc.c (machine_function): Remove force_short_suffix
13734 and size_reason.
13735 (arc_print_operand): Adjust printing of '&'.
13736 (arc_verify_short): Remove conditional printing of short suffix.
13737 (arc_final_prescan_insn): Remove reference to size_reason.
13738 (pad_return): New function.
13739 (arc_reorg): Call pad_return.
13740 (arc_pad_return): Remove.
13741 (arc_init_machine_status): Remove reference to force_short_suffix.
13742 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
13743 (attr length): When attribute iscompact is true force to 2
13744 regardless; in the case of maybe check if we want to force the
13745 instruction to have 4 bytes length.
13746 (nopv): Change it to generate 4 byte long nop as well.
13747 (blockage): New pattern.
13748 (simple_return): Remove call to arc_pad_return.
13749 (p_return_i): Likewise.
13750
13751 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13752
13753 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
13754
13755 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13756
13757 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
13758 ARC cores.
13759
13760 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13761
13762 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
13763 for ARC700 and ARCv2.
13764
13765 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
13766
13767 PR target/86076
13768 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
13769 operands[2] instead of operands[1].
13770
13771
13772 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13773
13774 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
13775 case, check whether the outer register overlaps an unallocatable
13776 register, not just whether it fits the required class.
13777
13778 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13779
13780 * poly-int.h (can_div_trunc_p): Add new overload in which all values
13781 are poly_ints.
13782 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
13783 (memrefs_conflict_p): Likewise.
13784 (init_alias_analysis): Likewise.
13785 * cfgexpand.c (expand_debug_expr): Likewise.
13786 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
13787 * cse.c (fold_rtx): Likewise.
13788 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
13789 * expr.c (emit_block_move_hints): Likewise.
13790 (clear_storage_hints, push_block, emit_push_insn): Likewise.
13791 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
13792 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
13793 (emit_group_store): Likewise.
13794 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
13795 to read the PRE/POST_MODIFY increment.
13796 * calls.c (store_one_arg): Use strip_offset.
13797 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
13798 poly_int_rtx_p.
13799 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
13800 by a VEC_SELECT.
13801 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
13802 (simplify_binary_operation_1): Extend CONST_INT handling to
13803 poly_int_rtx_p.
13804 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
13805 than a HOST_WIDE_INT.
13806 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
13807 poly_int64.
13808 (adjust_mems, add_stores): Update accodingly.
13809 (vt_canonicalize_addr): Track polynomial offsets.
13810 (emit_note_insn_var_location): Likewise.
13811 (vt_add_function_parameter): Likewise.
13812 (vt_initialize): Likewise.
13813
13814 2018-06-12 Jeff Law <law@redhat.com>
13815
13816 * config.gcc (alpha*-*-freebsd*): Remove.
13817 * config/alpha/freebsd.h: Remove.
13818
13819 2018-06-12 David Malcolm <dmalcolm@redhat.com>
13820
13821 PR other/69968
13822 * spellcheck-tree.c (levenshtein_distance): Rename to...
13823 (get_edit_distance): ...this, and update for underlying renaming.
13824 * spellcheck-tree.h (levenshtein_distance): Rename to...
13825 (get_edit_distance): ...this.
13826 * spellcheck.c (levenshtein_distance): Rename to...
13827 (get_edit_distance): ...this. Convert from Levenshtein distance
13828 to Damerau-Levenshtein distance by supporting transpositions of
13829 adjacent characters. Rename "v1" to "v_next" and "v0" to
13830 "v_one_ago".
13831 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
13832 (selftest::test_edit_distance_unit_test_oneway): ...this, and
13833 update for underlying renaming.
13834 (selftest::levenshtein_distance_unit_test): Rename to...
13835 (selftest::test_get_edit_distance_unit): ...this, and update for
13836 underlying renaming.
13837 (selftest::test_find_closest_string): Add example from PR 69968
13838 where transposition helps
13839 (selftest::test_metric_conditions): Update for renaming.
13840 (selftest::test_metric_conditions): Likewise.
13841 (selftest::spellcheck_c_tests): Likewise.
13842 * spellcheck.h (levenshtein_distance): Rename both overloads to...
13843 (get_edit_distance): ...this.
13844 (best_match::consider): Update for renaming.
13845
13846 2018-06-12 Martin Sebor <msebor@redhat.com>
13847
13848 PR tree-optimization/85259
13849 * builtins.c (compute_objsize): Handle constant offsets.
13850 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
13851 true iff a warning has been issued.
13852 * gimple.h (gimple_nonartificial_location): New function.
13853 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
13854 gimple_nonartificial_location and handle -Wno-system-headers.
13855 (handle_builtin_stxncpy): Same.
13856
13857 2018-06-12 Martin Sebor <msebor@redhat.com>
13858
13859 PR c/85931
13860 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
13861
13862 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
13863
13864 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
13865 BUILTIN_VEC_XST entries for pointer to double and long long.
13866
13867 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
13868
13869 PR target/85990
13870 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13871 Update comments.
13872 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13873 Likewise.
13874
13875 2018-06-12 Martin Liska <mliska@suse.cz>
13876
13877 * doc/options.texi: Document IntegerRange.
13878
13879 2018-06-12 Martin Liska <mliska@suse.cz>
13880
13881 * config/i386/i386.opt: Make MPX-related options as Deprecated.
13882 * opt-functions.awk: Handle Deprecated flag.
13883 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
13884 and report error.
13885 (read_cmdline_option): Report warning for a deprecated option.
13886 * opts.h (struct cl_option): Add new field cl_deprecated.
13887 (CL_ERR_DEPRECATED): New.
13888
13889 2018-06-12 Martin Liska <mliska@suse.cz>
13890
13891 * doc/options.texi: Document Deprecated option flag.
13892
13893 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13894
13895 * config/arc/arc-arch.h (arc_extras): New enum.
13896 (arc_cpu_t):Add field extra.
13897 (arc_cpu_types): Consider the extras.
13898 * config/arc/arc-cpus.def: Add extras info.
13899 * config/arc/arc-opts.h (processor_type): Consider extra field.
13900 * config/arc/arc.c (arc_override_options): Handle extra field.
13901
13902 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13903
13904 * config/arc/arc-arch.h: Update ARC_OPTX macro.
13905 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
13906 field.
13907 * config/arc/arc.c (arc_init): Update pic warning.
13908 (irq_range): Update irq range parsing warnings.
13909 (arc_override_options): Update various warning messages.
13910 (arc_handle_aux_attribute): Likewise.
13911
13912 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
13913
13914 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
13915
13916 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13917
13918 * doc/sourcebuild.texi: Document usage of line number 0 in verify
13919 compiler messages directives.
13920
13921 2018-06-12 Matthew Fortune <mfortune@gmail.com>
13922
13923 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
13924 * config/mips/mips-tables.opt: Regenerate.
13925 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
13926 mips64r6.
13927 * doc/invoke.texi: Document -march=i6500.
13928
13929 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
13930
13931 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
13932 (i6400_gpmul): Add cpu_unit.
13933 (i6400_gpdiv): Likewise.
13934 (i6400_msa_add_d): Update reservations.
13935 (i6400_msa_int_add) Likewise.
13936 (i6400_msa_short_logic3) Likewise.
13937 (i6400_msa_short_logic2) Likewise.
13938 (i6400_msa_short_logic) Likewise.
13939 (i6400_msa_move) Likewise.
13940 (i6400_msa_cmp) Likewise.
13941 (i6400_msa_short_float2) Likewise.
13942 (i6400_msa_div_d) Likewise.
13943 (i6400_msa_long_logic1) Likewise.
13944 (i6400_msa_long_logic2) Likewise.
13945 (i6400_msa_mult) Likewise.
13946 (i6400_msa_long_float2) Likewise.
13947 (i6400_msa_long_float4) Likewise.
13948 (i6400_msa_long_float5) Likewise.
13949 (i6400_msa_long_float8) Likewise.
13950 (i6400_fpu_fadd): Include frint type.
13951 (i6400_fpu_store): New define_insn_reservation.
13952 (i6400_fpu_load): Likewise.
13953 (i6400_fpu_move): Likewise.
13954 (i6400_fpu_fcmp): Likewise.
13955 (i6400_fpu_fmadd): Likewise.
13956 (i6400_int_mult): Include imul3nc type and update reservation.
13957 (i6400_int_div): Include idiv3 type and update reservation.
13958 (i6400_int_load): Update to check type not move_type.
13959 (i6400_int_store): Likewise.
13960 (i6400_int_prefetch): Set zero latency.
13961
13962 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
13963
13964 * gcc.c: Document new %@{...} sequence.
13965 (LINK_COMMAND_SPEC): Use it for the -L switches.
13966 (cpp_unique_options): Use it for the -I switches.
13967 (at_file_argbuf): New global variable.
13968 (in_at_file): Likewise.
13969 (alloc_args): Create at_file_argbuf.
13970 (clear_args): Truncate at_file_argbuf.
13971 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
13972 (open_at_file): New function.
13973 (close_at_file): Likewise.
13974 (create_at_file): Delete.
13975 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
13976 <'o'>: Likewise.
13977 <'@'>: New case.
13978 (validate_switches_from_spec): Deal with %@{...} sequence.
13979 (validate_switches): Likewise.
13980 (driver::finalize): Call clear_args.
13981
13982 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
13983
13984 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
13985
13986 2018-06-11 Martin Sebor <msebor@redhat.com>
13987
13988 * doc/invoke.texi (-Wall): List -Wc++17-compat.
13989 (Wno-class-memaccess): Add @opindex.
13990 (Wno-templates, Wno-multiple-inheritance): Same.
13991 (Wno-virtual-inheritance, Wno-namespaces): Same.
13992 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
13993 (Wno-format-overflow, Wno-format-truncation): Same.
13994 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
13995 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
13996 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
13997 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
13998 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
13999 (Wno-misspelled-isr): Same.
14000
14001 2018-06-11 Martin Sebor <msebor@redhat.com>
14002
14003 * PR tree-optimization/86083
14004 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
14005
14006 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
14007
14008 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
14009
14010 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
14011
14012 PR target/85755
14013 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
14014 on the correct operand.
14015 (*movdi_internal64): Ditto.
14016
14017 2018-06-11 Martin Liska <mliska@suse.cz>
14018
14019 PR tree-optimization/86089
14020 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
14021
14022 2018-06-11 Julia Koval <julia.koval@intel.com>
14023
14024 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
14025 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
14026 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
14027
14028 2018-06-11 Olivier Hainque <hainque@adacore.com>
14029
14030 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
14031 for Ada with strict dwarf2.
14032
14033 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
14034
14035 PR target/85755
14036 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
14037 addresses.
14038
14039 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
14040
14041 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
14042
14043 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
14044
14045 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
14046 TARGET_ELF.
14047
14048 2018-06-08 Martin Liska <mliska@suse.cz>
14049
14050 * tree-cfg.h (debug_function): Fix argument type to match
14051 implementation.
14052
14053 2018-06-08 Martin Liska <mliska@suse.cz>
14054
14055 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
14056 Remove usage of MPX-related (and removed) fields.
14057 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
14058
14059 2018-06-08 David Malcolm <dmalcolm@redhat.com>
14060
14061 * cfg.c (debug): Use TDF_NONE rather than 0.
14062 * cfghooks.c (debug): Likewise.
14063 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
14064 (struct dump_option_value_info): Convert to...
14065 (struct kv_pair): ...this template type.
14066 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
14067 rather than 0.
14068 (optinfo_verbosity_options): Likewise.
14069 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
14070 OPTGROUP_NONE.
14071 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
14072 than int for "optgroup_flags" param.
14073 (dump_generic_expr_loc): Use dump_flags_t rather than int for
14074 "dump_kind" param.
14075 (dump_dec): Likewise.
14076 (dump_finish): Use TDF_NONE rather than 0.
14077 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
14078 rather than int for "optgroup_flags" param. Use TDF_NONE rather
14079 than 0. Update for change to option_ptr.
14080 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
14081 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
14082 0. Update for changes to optinfo_verbosity_options and
14083 optgroup_options.
14084 (opt_info_switch_p): Convert optgroup_flags from int to
14085 optgroup_flags_t.
14086 (dump_basic_block): Use dump_flags_t rather than int
14087 for "dump_kind" param.
14088 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
14089 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
14090 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
14091 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
14092 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
14093 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
14094 TDF_NONE): Convert from macros to...
14095 (enum dump_flag): ...this new enum.
14096 (dump_flags_t): Update to use enum.
14097 (operator|, operator&, operator~, operator|=, operator&=):
14098 Implement for dump_flags_t.
14099 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
14100 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
14101 Convert from macros to...
14102 (enum optgroup_flag): ...this new enum.
14103 (optgroup_flags_t): New typedef.
14104 (operator|, operator|=): Implement for optgroup_flags_t.
14105 (struct dump_file_info): Convert field "alt_flags" to
14106 dump_flags_t. Convert field "optgroup_flags" to
14107 optgroup_flags_t.
14108 (dump_basic_block): Use dump_flags_t rather than int for param.
14109 (dump_generic_expr_loc): Likewise.
14110 (dump_dec): Likewise.
14111 (dump_register): Convert param "optgroup_flags" to
14112 optgroup_flags_t.
14113 (opt_info_enable_passes): Likewise.
14114 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
14115 than 0.
14116 * gimple-pretty-print.c (debug): Likewise.
14117 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
14118 (merged_store_group::apply_stores): Likewise.
14119 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
14120 * gimple.c (verify_gimple_pp): Likewise.
14121 * graphite-poly.c (print_pbb_body): Likewise.
14122 * passes.c (pass_manager::register_one_dump_file): Convert
14123 local "optgroup_flags" to optgroup_flags_t.
14124 * print-tree.c (print_node): Use TDF_NONE rather than 0.
14125 (debug): Likewise.
14126 (debug_body): Likewise.
14127 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
14128 to optgroup_flags_t.
14129 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
14130 than 0.
14131 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
14132 (convert_mult_to_fma): Likewise.
14133 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
14134 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
14135 * tree-vect-data-refs.c (dump_lower_bound): Convert param
14136 "dump_kind" to dump_flags_t.
14137
14138 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14139
14140 * config/rs6000/rs6000.c (min, max): Delete.
14141
14142 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14143
14144 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
14145 -mabi=spe and -mabi=no-spe.
14146
14147 2018-06-08 Martin Liska <mliska@suse.cz>
14148
14149 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
14150 where we expect an existing summary.
14151
14152 2018-06-08 Martin Liska <mliska@suse.cz>
14153
14154 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
14155 * ipa-inline.h (estimate_edge_growth): Likewise.
14156
14157 2018-06-08 Martin Liska <mliska@suse.cz>
14158
14159 * cgraph.c (function_version_hasher::hash): Use
14160 cgraph_node::get_uid ().
14161 (function_version_hasher::equal):
14162 * cgraph.h (cgraph_node::get_uid): New method.
14163 * ipa-inline.c (update_caller_keys): Use
14164 cgraph_node::get_uid ().
14165 (update_callee_keys): Likewise.
14166 * ipa-utils.c (searchc): Likewise.
14167 (ipa_reduced_postorder): Likewise.
14168 * lto-cgraph.c (input_node): Likewise.
14169 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
14170 * symbol-summary.h (symtab_insertion): Likewise.
14171 (symtab_removal): Likewise.
14172 (symtab_duplication): Likewise.
14173 * tree-pretty-print.c (dump_function_header): Likewise.
14174 * tree-sra.c (convert_callers_for_node): Likewise.
14175
14176 2018-06-08 Martin Liska <mliska@suse.cz>
14177
14178 * cgraph.c (symbol_table::create_edge): Always assign a new
14179 unique number.
14180 (symbol_table::free_edge): Do not recycle numbers.
14181 * cgraph.h (cgraph_edge::get): New method.
14182 * symbol-summary.h (symtab_removal): Use it.
14183 (symtab_duplication): Likewise.
14184 (call_summary::hashable_uid): Remove.
14185
14186 2018-06-08 Martin Liska <mliska@suse.cz>
14187
14188 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
14189 (initialize_growth_caches): Remove.
14190 (free_growth_caches): Likewise.
14191 (do_estimate_edge_time): Use edge_growth_cache.
14192 (do_estimate_edge_size): Likewise.
14193 (do_estimate_edge_hints): Likewise.
14194 * ipa-inline.c (reset_edge_caches): Likewise.
14195 (recursive_inlining): Likewise.
14196 (inline_small_functions): Likewise.
14197 * ipa-inline.h (initialize_growth_caches): Remove.
14198 (estimate_edge_size): Likewise.
14199 (estimate_edge_time): Likewise.
14200 (estimate_edge_hints): Likewise.
14201 (reset_edge_growth_cache): Likewise.
14202 * symbol-summary.h (call_summary::remove): New method.
14203
14204 2018-06-08 Martin Liska <mliska@suse.cz>
14205
14206 * ipa-cp.c (class edge_clone_summary): New summary.
14207 (grow_edge_clone_vectors): Remove.
14208 (ipcp_edge_duplication_hook): Remove.
14209 (class edge_clone_summary_t): New call_summary class.
14210 (ipcp_edge_removal_hook): Remove.
14211 (edge_clone_summary_t::duplicate): New function.
14212 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
14213 (create_specialized_node): Likewise.
14214 (ipcp_driver): Initialize edge_clone_summaries and do not
14215 register hooks.
14216
14217 2018-06-08 Martin Liska <mliska@suse.cz>
14218
14219 * symbol-summary.h (get): New function.
14220 (call_summary::m_initialize_when_cloning): New class member.
14221
14222 2018-06-08 Martin Liska <mliska@suse.cz>
14223
14224 * cgraph.c (cgraph_node::remove): Do not recycle uid.
14225 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
14226 (symbol_table::allocate_cgraph_symbol): Do not set uid.
14227 * passes.c (uid_hash_t): Record removed_nodes by their uids.
14228 (remove_cgraph_node_from_order): Use the removed_nodes set.
14229 (do_per_function_toporder): Likwise.
14230 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
14231 instead of summary_uid.
14232 (symtab_removal): Likewise.
14233 (symtab_duplication): Likewise.
14234
14235 2018-06-08 Martin Liska <mliska@suse.cz>
14236
14237 * ipa-cp.c (ipcp_store_bits_results): Use
14238 ipcp_transformation_sum.
14239 (ipcp_store_vr_results): Likewise.
14240 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
14241 to ...
14242 (ipcp_transformation_initialize): ... this.
14243 (ipa_set_node_agg_value_chain):
14244 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
14245 (write_ipcp_transformation_info): Likewise.
14246 (read_ipcp_transformation_info): Likewise.
14247 (ipcp_update_bits): Likewise.
14248 (ipcp_update_vr): Likewise.
14249 (ipcp_transform_function): Likewise.
14250 * ipa-prop.h: Rename ipcp_transformation_summary to
14251 ipcp_transformation.
14252 (class ipcp_transformation_t): New function summary.
14253 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
14254 (ipa_get_agg_replacements_for_node): Likewise.
14255
14256 2018-06-08 Martin Liska <mliska@suse.cz>
14257
14258 * ipa-pure-const.c (struct funct_state_d): Do it class instead
14259 of struct.
14260 (class funct_state_summary_t): New function_summary class.
14261 (has_function_state): Remove.
14262 (get_function_state): Likewise.
14263 (set_function_state): Likewise.
14264 (add_new_function): Likewise.
14265 (funct_state_summary_t::insert): New function.
14266 (duplicate_node_data): Remove.
14267 (remove_node_data): Remove.
14268 (funct_state_summary_t::duplicate): New function.
14269 (register_hooks): Create new funct_state_summaries.
14270 (pure_const_generate_summary): Use it.
14271 (pure_const_write_summary): Likewise.
14272 (pure_const_read_summary): Likewise.
14273 (propagate_pure_const): Likewise.
14274 (propagate_nothrow): Likewise.
14275 (dump_malloc_lattice): Likewise.
14276 (propagate_malloc): Likewise.
14277 (execute): Do not register hooks, just remove summary
14278 instead.
14279 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
14280 constructor.
14281
14282 2018-06-08 Martin Liska <mliska@suse.cz>
14283
14284 * ipa-reference.c (remove_node_data): Remove.
14285 (duplicate_node_data): Likewise.
14286 (class ipa_ref_var_info_summary_t): New class.
14287 (class ipa_ref_opt_summary_t): Likewise.
14288 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
14289 (get_reference_optimization_summary): Use
14290 ipa_ref_opt_sum_summaries.
14291 (set_reference_vars_info): Remove.
14292 (set_reference_optimization_summary): Likewise.
14293 (ipa_init): Create summaries.
14294 (init_function_info): Use function summary.
14295 (ipa_ref_opt_summary_t::duplicate): New function.
14296 (ipa_ref_opt_summary_t::remove): New function.
14297 (get_read_write_all_from_node): Fix GNU coding style.
14298 (propagate): Use function summary.
14299 (write_node_summary_p): Fix GNU coding style.
14300 (stream_out_bitmap): Likewise.
14301 (ipa_reference_read_optimization_summary): Use function summary.
14302 (ipa_reference_c_finalize): Do not release hooks.
14303
14304 2018-06-08 Martin Liska <mliska@suse.cz>
14305
14306 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
14307 (analyze_function_body): Extract multiple calls of get_create.
14308 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14309 * ipa-inline.c (recursive_inlining): Use ::get method.
14310 * ipa-inline.h (estimate_edge_growth): Likewise.
14311
14312 2018-06-08 Martin Liska <mliska@suse.cz>
14313
14314 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
14315 HSA_INVALID.
14316 (hsa_function_summary::hsa_function_summary): Use the new enum
14317 value.
14318 (hsa_gpu_implementation_p): Use hsa_summaries::get.
14319 * hsa-gen.c (hsa_get_host_function): Likewise.
14320 (get_brig_function_name): Likewise.
14321 * ipa-hsa.c (process_hsa_functions): Likewise.
14322 (ipa_hsa_write_summary): Likewise.
14323 * symbol-summary.h (symtab_duplication): Use ::get function/
14324 (get): New function.
14325
14326 2018-06-08 Martin Liska <mliska@suse.cz>
14327
14328 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
14329 of get.
14330 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
14331 (hsa_register_kernel): Likewise.
14332 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
14333 * hsa-gen.c (hsa_get_host_function): Likewise.
14334 (get_brig_function_name): Likewise.
14335 (generate_hsa): Likewise.
14336 (pass_gen_hsail::execute): Likewise.
14337 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
14338 (devirtualization_time_bonus): Likewise.
14339 (ipcp_propagate_stage): Likewise.
14340 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
14341 (edge_set_predicate): Likewise.
14342 (evaluate_conditions_for_known_args): Likewise.
14343 (evaluate_properties_for_edge): Likewise.
14344 (ipa_fn_summary::reset): Likewise.
14345 (ipa_fn_summary_t::duplicate): Likewise.
14346 (dump_ipa_call_summary): Likewise.
14347 (ipa_dump_fn_summary): Likewise.
14348 (analyze_function_body): Likewise.
14349 (compute_fn_summary): Likewise.
14350 (estimate_edge_devirt_benefit): Likewise.
14351 (estimate_edge_size_and_time): Likewise.
14352 (estimate_calls_size_and_time): Likewise.
14353 (estimate_node_size_and_time): Likewise.
14354 (inline_update_callee_summaries): Likewise.
14355 (remap_edge_change_prob): Likewise.
14356 (remap_edge_summaries): Likewise.
14357 (ipa_merge_fn_summary_after_inlining): Likewise.
14358 (ipa_update_overall_fn_summary): Likewise.
14359 (read_ipa_call_summary): Likewise.
14360 (inline_read_section): Likewise.
14361 (write_ipa_call_summary): Likewise.
14362 (ipa_fn_summary_write): Likewise.
14363 (ipa_free_fn_summary): Likewise.
14364 * ipa-hsa.c (process_hsa_functions): Likewise.
14365 (ipa_hsa_write_summary): Likewise.
14366 (ipa_hsa_read_section): Likewise.
14367 * ipa-icf.c (sem_function::merge): Likewise.
14368 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14369 (do_estimate_edge_time): Likewise.
14370 (estimate_size_after_inlining): Likewise.
14371 (estimate_growth): Likewise.
14372 (growth_likely_positive): Likewise.
14373 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
14374 (inline_call): Likewise.
14375 * ipa-inline.c (caller_growth_limits): Likewise.
14376 (can_inline_edge_p): Likewise.
14377 (can_inline_edge_by_limits_p): Likewise.
14378 (compute_uninlined_call_time): Likewise.
14379 (compute_inlined_call_time): Likewise.
14380 (want_inline_small_function_p): Likewise.
14381 (edge_badness): Likewise.
14382 (update_caller_keys): Likewise.
14383 (update_callee_keys): Likewise.
14384 (recursive_inlining): Likewise.
14385 (inline_small_functions): Likewise.
14386 (inline_to_all_callers_1): Likewise.
14387 (dump_overall_stats): Likewise.
14388 (early_inline_small_functions): Likewise.
14389 (early_inliner): Likewise.
14390 * ipa-inline.h (estimate_edge_growth): Likewise.
14391 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
14392 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
14393 * ipa-prop.h (IPA_NODE_REF): Likewise.
14394 (IPA_EDGE_REF): Likewise.
14395 * ipa-pure-const.c (malloc_candidate_p): Likewise.
14396 (propagate_malloc): Likewise.
14397 * ipa-split.c (execute_split_functions): Likewise.
14398 * symbol-summary.h: Rename get to get_create.
14399 (get): Likewise.
14400 (get_create): Likewise.
14401 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
14402
14403 2018-06-08 Martin Liska <mliska@suse.cz>
14404
14405 * symbol-summary.h (release): Move definition out of class
14406 declaration.
14407 (symtab_removal): Likewise.
14408 (symtab_duplication): Likewise.
14409
14410 2018-06-08 Martin Liska <mliska@suse.cz>
14411
14412 * symbol-summary.h (function_summary): Move constructor
14413 implementation out of class declaration.
14414 (release): Likewise.
14415 (symtab_insertion): Likewise.
14416 (symtab_removal): Likewise.
14417 (symtab_duplication): Likewise.
14418 (get): Likewise.
14419
14420 2018-06-08 Martin Liska <mliska@suse.cz>
14421
14422 * Makefile.in: Remove support for MPX (macros, related functions,
14423 fields in cgraph_node, ...).
14424 * builtin-types.def (BT_BND): Likewise.
14425 (BT_FN_BND_CONST_PTR): Likewise.
14426 (BT_FN_CONST_PTR_BND): Likewise.
14427 (BT_FN_VOID_PTR_BND): Likewise.
14428 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
14429 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
14430 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
14431 (expand_builtin_mempcpy_with_bounds): Likewise.
14432 (expand_builtin_memset_with_bounds): Likewise.
14433 (expand_builtin_memset_args): Likewise.
14434 (std_expand_builtin_va_start): Likewise.
14435 (expand_builtin): Likewise.
14436 (expand_builtin_with_bounds): Likewise.
14437 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
14438 (DEF_LIB_BUILTIN_CHKP): Likewise.
14439 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
14440 (DEF_CHKP_BUILTIN): Likewise.
14441 (BUILT_IN_MEMCPY): Likewise.
14442 (BUILT_IN_MEMMOVE): Likewise.
14443 (BUILT_IN_MEMPCPY): Likewise.
14444 (BUILT_IN_MEMSET): Likewise.
14445 (BUILT_IN_STPCPY): Likewise.
14446 (BUILT_IN_STRCAT): Likewise.
14447 (BUILT_IN_STRCHR): Likewise.
14448 (BUILT_IN_STRCPY): Likewise.
14449 (BUILT_IN_STRLEN): Likewise.
14450 (BUILT_IN_MEMCPY_CHK): Likewise.
14451 (BUILT_IN_MEMMOVE_CHK): Likewise.
14452 (BUILT_IN_MEMPCPY_CHK): Likewise.
14453 (BUILT_IN_MEMSET_CHK): Likewise.
14454 (BUILT_IN_STPCPY_CHK): Likewise.
14455 (BUILT_IN_STRCAT_CHK): Likewise.
14456 (BUILT_IN_STRCPY_CHK): Likewise.
14457 * calls.c (store_bounds): Likewise.
14458 (emit_call_1): Likewise.
14459 (special_function_p): Likewise.
14460 (maybe_warn_nonstring_arg): Likewise.
14461 (initialize_argument_information): Likewise.
14462 (finalize_must_preallocate): Likewise.
14463 (compute_argument_addresses): Likewise.
14464 (expand_call): Likewise.
14465 * cfgexpand.c (expand_call_stmt): Likewise.
14466 (expand_return): Likewise.
14467 (expand_gimple_stmt_1): Likewise.
14468 (pass_expand::execute): Likewise.
14469 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
14470 (cgraph_node::remove): Likewise.
14471 (cgraph_node::dump): Likewise.
14472 (cgraph_node::verify_node): Likewise.
14473 * cgraph.h (chkp_function_instrumented_p): Likewise.
14474 (symtab_node::get_alias_target): Likewise.
14475 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
14476 (cgraph_local_p): Likewise.
14477 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
14478 (cgraph_edge::rebuild_references): Likewise.
14479 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
14480 (walk_polymorphic_call_targets): Likewise.
14481 (cgraph_node::expand_thunk): Likewise.
14482 (symbol_table::output_weakrefs): Likewise.
14483 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
14484 (ix86_handle_option): Likewise.
14485 * config/i386/constraints.md: Likewise.
14486 * config/i386/i386-builtin-types.def (BND): Likewise.
14487 (VOID): Likewise.
14488 (PVOID): Likewise.
14489 (ULONG): Likewise.
14490 * config/i386/i386-builtin.def (BDESC_END): Likewise.
14491 (BDESC_FIRST): Likewise.
14492 (BDESC): Likewise.
14493 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
14494 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
14495 * config/i386/i386.c (enum reg_class): Likewise.
14496 (ix86_target_string): Likewise.
14497 (ix86_option_override_internal): Likewise.
14498 (ix86_conditional_register_usage): Likewise.
14499 (ix86_valid_target_attribute_inner_p): Likewise.
14500 (ix86_set_indirect_branch_type): Likewise.
14501 (ix86_set_current_function): Likewise.
14502 (ix86_function_arg_regno_p): Likewise.
14503 (init_cumulative_args): Likewise.
14504 (ix86_function_arg_advance): Likewise.
14505 (ix86_function_arg): Likewise.
14506 (ix86_pass_by_reference): Likewise.
14507 (ix86_function_value_regno_p): Likewise.
14508 (ix86_function_value_1): Likewise.
14509 (ix86_function_value_bounds): Likewise.
14510 (ix86_return_in_memory): Likewise.
14511 (ix86_setup_incoming_vararg_bounds): Likewise.
14512 (ix86_va_start): Likewise.
14513 (indirect_thunk_need_prefix): Likewise.
14514 (print_reg): Likewise.
14515 (ix86_print_operand): Likewise.
14516 (ix86_expand_call): Likewise.
14517 (ix86_output_function_return): Likewise.
14518 (reg_encoded_number): Likewise.
14519 (BDESC_VERIFYS): Likewise.
14520 (ix86_init_mpx_builtins): Likewise.
14521 (ix86_init_builtins): Likewise.
14522 (ix86_emit_cmove): Likewise.
14523 (ix86_emit_move_max): Likewise.
14524 (ix86_expand_builtin): Likewise.
14525 (ix86_builtin_mpx_function): Likewise.
14526 (ix86_get_arg_address_for_bt): Likewise.
14527 (ix86_load_bounds): Likewise.
14528 (ix86_store_bounds): Likewise.
14529 (ix86_load_returned_bounds): Likewise.
14530 (ix86_store_returned_bounds): Likewise.
14531 (ix86_class_likely_spilled_p): Likewise.
14532 (ix86_hard_regno_mode_ok): Likewise.
14533 (x86_order_regs_for_local_alloc): Likewise.
14534 (ix86_mitigate_rop): Likewise.
14535 (ix86_bnd_prefixed_insn_p): Likewise.
14536 (ix86_mpx_bound_mode): Likewise.
14537 (ix86_make_bounds_constant): Likewise.
14538 (ix86_initialize_bounds): Likewise.
14539 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
14540 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
14541 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
14542 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
14543 (TARGET_CHKP_BOUND_MODE): Likewise.
14544 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
14545 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
14546 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
14547 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
14548 * config/i386/i386.h (TARGET_MPX): Likewise.
14549 (TARGET_MPX_P): Likewise.
14550 (VALID_BND_REG_MODE): Likewise.
14551 (FIRST_BND_REG): Likewise.
14552 (LAST_BND_REG): Likewise.
14553 (enum reg_class): Likewise.
14554 (BND_REG_P): Likewise.
14555 (BND_REGNO_P): Likewise.
14556 (BNDmode): Likewise.
14557 (ADJUST_INSN_LENGTH): Likewise.
14558 * config/i386/i386.md: Likewise.
14559 * config/i386/i386.opt: Likewise.
14560 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
14561 (defined): Likewise.
14562 (LINK_MPX): Likewise.
14563 (MPX_SPEC): Likewise.
14564 (LIBMPX_SPEC): Likewise.
14565 (LIBMPXWRAPPERS_SPEC): Likewise.
14566 (CHKP_SPEC): Likewise.
14567 * config/i386/predicates.md: Likewise.
14568 * dbxout.c (dbxout_type): Likewise.
14569 * doc/extend.texi: Likewise.
14570 * doc/invoke.texi: Likewise.
14571 * doc/md.texi: Likewise.
14572 * doc/tm.texi: Likewise.
14573 * doc/tm.texi.in: Likewise.
14574 * dwarf2out.c (is_base_type): Likewise.
14575 (gen_formal_types_die): Likewise.
14576 (gen_subprogram_die): Likewise.
14577 (gen_type_die_with_usage): Likewise.
14578 (gen_decl_die): Likewise.
14579 (dwarf2out_late_global_decl): Likewise.
14580 * expr.c (expand_assignment): Likewise.
14581 (emit_storent_insn): Likewise.
14582 (store_expr_with_bounds): Likewise.
14583 (store_expr): Likewise.
14584 (expand_expr_real_1): Likewise.
14585 * expr.h (store_expr_with_bounds): Likewise.
14586 * function.c (use_register_for_decl): Likewise.
14587 (struct bounds_parm_data): Likewise.
14588 (assign_parms_augmented_arg_list): Likewise.
14589 (assign_parm_find_entry_rtl): Likewise.
14590 (assign_parm_is_stack_parm): Likewise.
14591 (assign_parm_load_bounds): Likewise.
14592 (assign_bounds): Likewise.
14593 (assign_parms): Likewise.
14594 (expand_function_start): Likewise.
14595 * gcc.c (CHKP_SPEC): Likewise.
14596 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
14597 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
14598 (wrestrict_dom_walker::check_call): Likewise.
14599 * gimple.c (gimple_build_call_from_tree): Likewise.
14600 * gimple.h (enum gf_mask): Likewise.
14601 (gimple_call_with_bounds_p): Likewise.
14602 (gimple_call_set_with_bounds): Likewise.
14603 * gimplify.c (gimplify_init_constructor): Likewise.
14604 * ipa-cp.c (initialize_node_lattices): Likewise.
14605 (propagate_constants_across_call): Likewise.
14606 (find_more_scalar_values_for_callers_subset): Likewise.
14607 * ipa-hsa.c (process_hsa_functions): Likewise.
14608 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
14609 * ipa-icf.c (sem_function::merge): Likewise.
14610 * ipa-inline.c (early_inliner): Likewise.
14611 * ipa-pure-const.c (warn_function_noreturn): Likewise.
14612 (warn_function_cold): Likewise.
14613 (propagate_pure_const): Likewise.
14614 * ipa-ref.h (enum GTY): Likewise.
14615 * ipa-split.c (find_retbnd): Likewise.
14616 (consider_split): Likewise.
14617 (split_function): Likewise.
14618 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
14619 * ipa.c (walk_polymorphic_call_targets): Likewise.
14620 (symbol_table::remove_unreachable_nodes): Likewise.
14621 (process_references): Likewise.
14622 (cgraph_build_static_cdtor_1): Likewise.
14623 * lto-cgraph.c (lto_output_node): Likewise.
14624 (output_refs): Likewise.
14625 (compute_ltrans_boundary): Likewise.
14626 (input_overwrite_node): Likewise.
14627 (input_node): Likewise.
14628 (input_cgraph_1): Likewise.
14629 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
14630 * passes.c (pass_manager::execute_early_local_passes): Likewise.
14631 (class pass_chkp_instrumentation_passes): Likewise.
14632 (make_pass_chkp_instrumentation_passes): Likewise.
14633 * passes.def: Likewise.
14634 * rtl.h (struct GTY): Likewise.
14635 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
14636 * stor-layout.c (layout_type): Likewise.
14637 * symtab.c: Likewise.
14638 * target.def: Likewise.
14639 * targhooks.c (default_chkp_bound_type): Likewise.
14640 (default_chkp_bound_mode): Likewise.
14641 (default_builtin_chkp_function): Likewise.
14642 (default_chkp_function_value_bounds): Likewise.
14643 (default_chkp_make_bounds_constant): Likewise.
14644 (default_chkp_initialize_bounds): Likewise.
14645 * targhooks.h (default_chkp_bound_type): Likewise.
14646 (default_chkp_bound_mode): Likewise.
14647 (default_builtin_chkp_function): Likewise.
14648 (default_chkp_function_value_bounds): Likewise.
14649 (default_chkp_make_bounds_constant): Likewise.
14650 (default_chkp_initialize_bounds): Likewise.
14651 * toplev.c (compile_file): Likewise.
14652 (process_options): Likewise.
14653 * tree-core.h (DEF_BUILTIN): Likewise.
14654 (DEF_BUILTIN_CHKP): Likewise.
14655 * tree-inline.c (declare_return_variable): Likewise.
14656 (remap_gimple_stmt): Likewise.
14657 (copy_bb): Likewise.
14658 (initialize_inlined_parameters): Likewise.
14659 (expand_call_inline): Likewise.
14660 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
14661 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
14662 (make_pass_ipa_chkp_produce_thunks): Likewise.
14663 (make_pass_chkp): Likewise.
14664 (make_pass_chkp_opt): Likewise.
14665 (make_pass_chkp_instrumentation_passes): Likewise.
14666 * tree-pretty-print.c (dump_generic_node): Likewise.
14667 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
14668 * tree-ssa-dce.c (propagate_necessity): Likewise.
14669 (eliminate_unnecessary_stmts): Likewise.
14670 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
14671 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
14672 * tree-ssa-sccvn.h: Likewise.
14673 * tree-ssa-strlen.c (get_string_length): Likewise.
14674 (valid_builtin_call): Likewise.
14675 (adjust_last_stmt): Likewise.
14676 (handle_builtin_strchr): Likewise.
14677 (handle_builtin_strcpy): Likewise.
14678 (handle_builtin_stxncpy): Likewise.
14679 (handle_builtin_memcpy): Likewise.
14680 (handle_builtin_strcat): Likewise.
14681 (strlen_check_and_optimize_stmt): Likewise.
14682 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
14683 * tree-streamer-in.c: Likewise.
14684 * tree-streamer.c (record_common_node): Likewise.
14685 * tree.c (tree_code_size): Likewise.
14686 (wide_int_to_tree_1): Likewise.
14687 (type_contains_placeholder_1): Likewise.
14688 (build_common_tree_nodes): Likewise.
14689 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
14690 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
14691 (POINTER_BOUNDS_P): Likewise.
14692 (BOUNDED_TYPE_P): Likewise.
14693 (BOUNDED_P): Likewise.
14694 (CALL_WITH_BOUNDS_P): Likewise.
14695 (pointer_bounds_type_node): Likewise.
14696 * value-prof.c (gimple_ic): Likewise.
14697 * var-tracking.c (vt_add_function_parameters): Likewise.
14698 * varasm.c (make_decl_rtl): Likewise.
14699 (assemble_start_function): Likewise.
14700 (output_constant): Likewise.
14701 (maybe_assemble_visibility): Likewise.
14702 * varpool.c (ctor_for_folding): Likewise.
14703 * chkp-builtins.def: Remove.
14704 * ipa-chkp.c: Remove.
14705 * ipa-chkp.h: Remove.
14706 * rtl-chkp.c: Remove.
14707 * rtl-chkp.h: Remove.
14708 * tree-chkp-opt.c: Remove.
14709 * tree-chkp.c: Remove.
14710 * tree-chkp.h: Remove.
14711
14712 2018-06-07 Carl Love <cel@us.ibm.com>
14713
14714 * config/rs6000/vsx.md (vextract_fp_from_shorth,
14715 vextract_fp_from_shortl): Add BE support.
14716
14717 2018-06-07 Paul Koning <ni1d@arrl.net>
14718
14719 * compare-elim.c (try_merge_compare): Don't merge compare if
14720 address contains a side effect.
14721 (try_eliminate_compare): Likewise.
14722
14723 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
14724
14725 * config.gcc: Support "tremont".
14726 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
14727 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14728 PROCESSOR_TREMONT.
14729 * config/i386/i386.c (m_TREMONT): Define.
14730 (processor_target_table): Add "tremont".
14731 (PTA_TREMONT): Define.
14732 (ix86_lea_outperforms): Add TARGET_TREMONT.
14733 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
14734 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
14735 and M_INTEL_GOLDMONT_PLUS.
14736 (fold_builtin_cpu): Add "tremont".
14737 (ix86_add_stmt_cost): Add TARGET_TREMONT.
14738 (ix86_option_override_internal): Add "tremont".
14739 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
14740 (processor_type): Add PROCESSOR_TREMONT.
14741 * config/i386/x86-tune.def: Add m_TREMONT.
14742 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
14743
14744 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14745
14746 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
14747 symbol defined for msp430i* devices to be lower case.
14748
14749 2018-06-07 Richard Biener <rguenther@suse.de>
14750
14751 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
14752 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
14753 Properly wrap signed arithmetic if overflow wraps.
14754
14755 2018-06-07 Jakub Jelinek <jakub@redhat.com>
14756
14757 PR tree-optimization/69615
14758 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
14759 of a cast from a same precision integral SSA_NAME in a bb dominated
14760 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
14761 cast to utype if rhs2 has already a compatible type.
14762
14763 2018-06-07 Richard Biener <rguenther@suse.de>
14764
14765 PR tree-optimization/85935
14766 * graphite-scop-detection.c (find_params_in_bb): Analyze
14767 condition operands with respect to the correct loop. Assert
14768 the analysis doesn't fail.
14769
14770 2018-06-04 Carl Love <cel@us.ibm.com>
14771
14772 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
14773 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
14774 as it is slightly cheaper.
14775 (first_match_or_eos_index_<mode>):
14776 Calculate index using natural element order.
14777 (first_match_index_<mode>):
14778 Calculate index using natural element order.
14779 (first_match_or_eos_index_<mode>):
14780 Calculate index using natural order.
14781 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
14782 for BE and LE modes.
14783 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
14784 P9V_BUILTIN_VCLZLSBB_V16QI.
14785 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
14786 specific.
14787
14788 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14789
14790 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
14791 indentation and line wrap for many prototypes. Add missing
14792 @smallexample directives around block of prototypes for vec_xl and
14793 vec_xst.
14794
14795 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
14796
14797 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
14798 track if we pass or return IEEE 128-bit floating point.
14799 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
14800 C++ mangling that is compatible with GCC 8.1.
14801 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
14802 (init_cumulative_args): Note if we pass or return IEEE 128-bit
14803 floating point types.
14804 (rs6000_function_arg_advance_1): Likewise.
14805 (rs6000_mangle_type): Optionally generate mangled names that match
14806 what GCC 8.1 generated for IEEE 128-bit floating point types.
14807 (rs6000_globalize_decl_name): If we have an external function that
14808 passes or returns IEEE 128-bit types, generate a weak reference
14809 from the mangled name used in GCC 8.1 to the current mangled
14810 name.
14811 (rs6000_init_builtins): Make __ibm128 use the long double type if
14812 long double is IBM extended double. Make __float128 use the long
14813 double type if long double is IEEE 128-bit.
14814
14815 PR target/85657
14816 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
14817 macro for __ibm128 built-in functions.
14818 (PACK_IF): Add __ibm128 pack/unpack functions.
14819 (UNPACK_IF): Likewise.
14820 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
14821 enable long double built-in functions if long double is IEEE
14822 128-bit floating point.
14823 (rs6000_invalid_builtin): Update long double built-in function
14824 error message.
14825 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
14826 functions, adjust the built-in function to use the long double
14827 built-in function if __ibm128 and long double are the same type.
14828 * doc/extend.texi (PowerPC builtins): Update documention for
14829 __builtin_{,un}pack_longdouble. Add documentation for
14830 __builtin_{,un}pack_ibm128.
14831
14832 2018-06-06 Jim Wilson <jimw@sifive.com>
14833
14834 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
14835 (struct machine_function): New field interrupt_mode.
14836 (riscv_handle_type_attribute): New function. Add forward declaration.
14837 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
14838 (riscv_expand_epilogue): Check interrupt_mode field.
14839 (riscv_set_current_function): Check interrupt attribute args and
14840 set interrupt_mode field.
14841 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
14842 (riscv_sret, riscv_uret): New.
14843 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
14844 new arguments to interrupt attribute.
14845
14846 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
14847
14848 PR target/63177
14849 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
14850 Don't handle -mcpu=power8 if -mpower9-vector is also used.
14851
14852 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14853
14854 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
14855 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
14856 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
14857 several redundant entries.
14858
14859 2018-06-06 David Malcolm <dmalcolm@redhat.com>
14860
14861 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
14862 type from "rtx" to "rtx_insn *".
14863 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
14864 for local "call_insn", removing cast.
14865 (ix86_expand_call): Likewise, introducing a "call_insn" local.
14866
14867 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
14868
14869 PR tree-optimization/86066
14870 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
14871 for BIT_INSERT_EXPR stores.
14872
14873 2018-06-06 Richard Biener <rguenther@suse.de>
14874
14875 PR tree-optimization/86062
14876 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
14877 component refs ontop
14878 of to be offsetted base.
14879
14880 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14881
14882 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
14883 to be static and remove check on interrupt attribute name.
14884
14885 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
14886
14887 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
14888 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
14889
14890 2018-06-05 Steve Ellcey <sellcey@cavium.com>
14891
14892 PR target/79924
14893 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
14894 second argument.
14895 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
14896 Remove second argument, change how error is called.
14897 (aarch64_layout_arg): Remove second argument from
14898 aarch64_err_no_fpadvsimd call.
14899 (aarch64_init_cumulative_args): Ditto.
14900 (aarch64_gimplify_va_arg_expr): Ditto.
14901 * config/aarch64/aarch64.md (mov<mode>): Ditto.
14902
14903 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
14904
14905 * config/i386/i386.md (simple_return_indirect_internal): New expander.
14906 (*simple_return_indirect_internal<mode>): Rename from
14907 simple_return_indirect_internal. Use W mode iterator.
14908 (rstorssp): New expander.
14909 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
14910 (clrssbsy): New expander.
14911 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
14912
14913 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
14914
14915 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
14916 __typeof__.
14917 (cmse_check_pointed_object): Likewise.
14918
14919 2018-06-05 Martin Liska <mliska@suse.cz>
14920
14921 PR gcov-profile/47618
14922 * doc/invoke.texi: Document how -fprofile-dir format
14923 is extended.
14924
14925 2018-06-05 Richard Biener <rguenther@suse.de>
14926
14927 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
14928 removal pretend DOM info isn't available so we do not update
14929 it and only remove edges, not dominated blocks. Actually free
14930 DOM info in case we removed something. Remove unreachable blocks.
14931 (mfb_keep_latches): Work with either DOM info or marked backedges.
14932 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
14933 first. Mark backedges if DOM info isn't available.
14934 (Re-)compute DOM info after cleanup_control_flow_pre.
14935
14936 2018-06-05 Richard Biener <rguenther@suse.de>
14937
14938 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
14939 (locus_discrim_hasher::hash): Adjust.
14940 (locus_discrim_hasher::equal): Likewise.
14941 (next_discriminator_for_locus): Work on line directly.
14942 (same_line_p): Pass in expanded locus1 as well.
14943 (assign_discriminators): Avoid redundant location expansions.
14944
14945 2018-06-05 Richard Biener <rguenther@suse.de>
14946
14947 PR tree-optimization/86046
14948 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
14949 if required after clearing TREE_ADDRESSABLE.
14950
14951 2018-06-05 Richard Biener <rguenther@suse.de>
14952
14953 PR tree-optimization/86047
14954 * tree-ssa-loop.c (for_each_index): Glob handling of all
14955 decls and constants and really handle all of them.
14956
14957 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14958
14959 PR target/81497
14960 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
14961 qualifier_void_pointer and qualifier_const_void_pointer.
14962 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
14963 (arm_init_builtins): Handle the above.
14964 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
14965 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
14966 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
14967 void intrinsics.
14968
14969 2018-06-05 Martin Liska <mliska@suse.cz>
14970
14971 * auto-profile.c (read_autofdo_file): Do not use
14972 gcov_ctr_summary struct.
14973 (afdo_callsite_hot_enough_for_early_inline): Likewise.
14974 * coverage.c (struct counts_entry): Likewise.
14975 (read_counts_file): Read just single summary entry.
14976 (get_coverage_counts): Use gcov_summary struct.
14977 * coverage.h (get_coverage_counts): Likewise.
14978 * gcov-dump.c (dump_working_sets): Likewise.
14979 (tag_summary): Dump just single summary.
14980 * gcov-io.c (gcov_write_summary): Write just histogram
14981 summary.
14982 (gcov_read_summary): Read just single summary.
14983 (compute_working_sets): Use gcov_summary struct.
14984 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
14985 of GCOV_COUNTERS_SUMMABLE.
14986 (GCOV_COUNTERS_SUMMABLE): Remove.
14987 (GCOV_FIRST_VALUE_COUNTER): Replace with
14988 GCOV_COUNTER_V_INTERVAL.
14989 (struct gcov_ctr_summary): Remove.
14990 (struct gcov_summary): Directly use fields of former
14991 gcov_ctr_summary.
14992 (compute_working_sets): Use gcov_summary struct.
14993 * gcov.c (read_count_file): Do not use ctrs fields.
14994 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
14995 struct.
14996 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
14997 struct.
14998 * profile.c: Likewise.
14999 * profile.h: Likewise.
15000
15001 2018-06-05 Martin Liska <mliska@suse.cz>
15002
15003 PR gcov-profile/84846
15004 * gcov.c (output_lines): Print working directory only
15005 in intermediate format.
15006
15007 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
15008
15009 * config/s390/s390-builtin-types.def: Add void function type.
15010 * config/s390/s390-builtins.def: Use the function type for the
15011 tbeginc builtin.
15012
15013 2018-06-04 Jim Wilson <jimw@sifive.com>
15014
15015 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
15016 to int.
15017 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
15018 and maybe_eh_return. Change regno to unsigned int. Use new args to
15019 handle EH_RETURN_DATA_REGNO registers properly.
15020 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
15021 (riscv_expand_epilogue): Update comment. Change argument name and
15022 type. Update code to use new name and type. Pass new args to
15023 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
15024 EXCEPTION_RETURN.
15025 * config/riscv/riscv.md (NORMAL_RETURN): New.
15026 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
15027 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
15028 (eh_return): Call gen_eh_return_internal and emit barrier.
15029 (eh_return_internal): Call riscv_expand_epilogue.
15030
15031 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
15032
15033 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
15034 bit_insertion field and declare can_be_merged_into method.
15035 (merged_store_group::can_be_merged_into): New method.
15036 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
15037 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
15038 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
15039
15040 2018-06-04 Richard Biener <rguenther@suse.de>
15041
15042 PR tree-optimization/85955
15043 * builtins.c (fold_builtin_sincos): Convert pointers to
15044 destination to appropriate type before dereferencing.
15045
15046 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
15047
15048 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
15049
15050 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
15051
15052 * expr.c (expand_expr_real_1): Force the operand into memory if
15053 its TYPE_MODE is BLKmode and if there is no integer mode for
15054 the number of bits being extracted.
15055
15056 2018-06-04 Jakub Jelinek <jakub@redhat.com>
15057
15058 PR target/85832
15059 PR target/86036
15060 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
15061 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
15062
15063 2018-06-04 Richard Biener <rguenther@suse.de>
15064
15065 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
15066 (cleanup_tree_cfg_noloop): ... single caller. Do
15067 start_recording_case_labels later.
15068
15069 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
15070
15071 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
15072 to _IMMINTRIN_H_INCLUDED.
15073 * config/i386/pconfigintrin.h: Ditto.
15074 * config/i386/waitpkgintrin.h: Ditto.
15075 * config/i386/immintrin.h: Add includes for sgxintrin.h,
15076 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
15077 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
15078 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
15079 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
15080 waitpkgintrin.h and cldemoteintrin.h.
15081
15082 2018-06-04 Richard Biener <rguenther@suse.de>
15083
15084 PR tree-optimization/86038
15085 * tracer.c (find_best_successor): Check probability for
15086 being initialized, bail out if not.
15087
15088 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
15089
15090 PR target/86003
15091 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
15092 of bits to ignore when comparing architectures.
15093
15094 2018-06-04 Jakub Jelinek <jakub@redhat.com>
15095
15096 PR tree-optimization/69615
15097 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
15098 maximum or minimum of the type, try to merge it also as if
15099 range1 is + [-, x - 1] or + [x + 1, -].
15100
15101 PR c++/86025
15102 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
15103
15104 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
15105
15106 PR tree-optimization/86034
15107 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
15108 the unsigned bitfield type in a bit insertion sequence if it does not
15109 have a larger precision than the bitfield size.
15110 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
15111
15112 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
15113
15114 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
15115
15116 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
15117
15118 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
15119 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
15120 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
15121 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
15122
15123 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
15124
15125 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
15126 Disable -fdelete-null-pointer-checks for ELF toolchain.
15127
15128 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
15129 Kito Cheng <kito.cheng@gmail.com>
15130
15131 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
15132 (nds32le-*-*, nds32be-*-*): Integrate checking process.
15133 (nds32*-*-*): Add glibc and uclibc conditions.
15134 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
15135 (TARGET_EXCEPT_UNWIND_INFO): Define.
15136 * config/nds32/elf.h: New file.
15137 * config/nds32/linux.h: New file.
15138 * config/nds32/nds32-elf.opt: New file.
15139 * config/nds32/nds32-linux.opt: New file.
15140 * config/nds32/nds32-fp-as-gp.c
15141 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
15142 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
15143 TARGET_LINUX_ABI.
15144 (nds32_asm_file_end): Ditto.
15145 (nds32_print_operand): Ditto.
15146 (nds32_insert_attributes): Ditto.
15147 (nds32_init_libfuncs): New function.
15148 (TARGET_HAVE_TLS): Define.
15149 (TARGET_INIT_LIBFUNCS): Define.
15150 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
15151 spec content.
15152 (TARGET_ELF): Apply different mcmodel setting.
15153 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
15154 been migrated into elf.h and linux.h files.
15155 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
15156 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
15157 (mcmodel): The content has been migrated into nds32-elf.opt and
15158 nds32-linux.opt files.
15159 * config/nds32/t-elf: New file.
15160 * config/nds32/t-linux: New file.
15161
15162 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
15163 Shiva Chen <shiva0217@gmail.com>
15164
15165 * config/nds32/constants.md (unspec_volatile_element): Add
15166 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
15167 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
15168 optimization.
15169 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
15170 (make_pass_nds32_fp_as_gp): Declare.
15171 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
15172 optmization pass.
15173 (nds32_asm_function_end_prologue): Remove unused asm output.
15174 (nds32_asm_function_begin_epilogue): Remove unused asm output.
15175 (nds32_asm_file_start): Output necessary fp_as_gp information.
15176 (nds32_option_override): Adjust register usage.
15177 (nds32_expand_prologue): Consider fp_as_gp situation.
15178 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
15179 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
15180 (epilogue): Ditto.
15181 (return): Ditto.
15182 (simple_return): Ditto.
15183 (omit_fp_begin): Output special directive for fp_as_gp.
15184 (omit_fp_end): Output special directive for fp_as_gp.
15185 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
15186 mforbid-fp-as-gp): New options.
15187
15188 2018-06-01 Mark Wielaard <mark@klomp.org>
15189
15190 * dwarf2out.c (dwarf2out_finish): Remove generation of
15191 DW_AT_loclists_base.
15192
15193 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
15194
15195 * gimple-ssa-store-merging.c: Include gimple-fold.h.
15196 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
15197 (struct merged_store_group): Add bit_insertion field.
15198 (dump_char_array): Use standard hexadecimal format.
15199 (merged_store_group::merged_store_group): Set bit_insertion to false.
15200 (merged_store_group::apply_stores): Use optimal buffer size. Deal
15201 with BIT_INSERT_EXPR stores. Move up code updating the mask and
15202 also print the mask in the dump file.
15203 (pass_store_merging::gate): Minor tweak.
15204 (imm_store_chain_info::coalesce_immediate): Fix wrong association
15205 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
15206 stores with INTEGER_CST stores.
15207 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
15208 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
15209 and use it throughout. Generate bit insertion sequences if need be.
15210 (pass_store_merging::process_store): Remove redundant condition.
15211 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
15212
15213 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
15214
15215 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
15216 the 128-bit floating point types. Fix function comment.
15217
15218 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15219
15220 * config/aarch64/aarch64-simd.md
15221 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
15222 mnemonics.
15223 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
15224 mnemonics.
15225
15226 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15227
15228 PR tree-optimization/85989
15229 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
15230 variable.
15231 (backprop::intersect_uses): Check it when deciding whether this
15232 is a backedge reference.
15233 (backprop::process_block): Add each phi to m_visited_phis
15234 after visiting it, then clear it at the end.
15235
15236 2018-06-01 Richard Biener <rguenther@suse.de>
15237
15238 * tree-vectorizer.h (vect_dr_stmt): New function.
15239 (vect_get_load_cost): Adjust.
15240 (vect_get_store_cost): Likewise.
15241 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
15242 Use vect_dr_stmt instead of DR_SMTT.
15243 (vect_record_base_alignments): Likewise.
15244 (vect_calculate_target_alignment): Likewise.
15245 (vect_compute_data_ref_alignment): Likewise and make static.
15246 (vect_update_misalignment_for_peel): Likewise.
15247 (vect_verify_datarefs_alignment): Likewise.
15248 (vector_alignment_reachable_p): Likewise.
15249 (vect_get_data_access_cost): Likewise. Pass down
15250 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
15251 (vect_get_peeling_costs_all_drs): Likewise.
15252 (vect_peeling_hash_get_lowest_cost): Likewise.
15253 (vect_enhance_data_refs_alignment): Likewise.
15254 (vect_find_same_alignment_drs): Likewise.
15255 (vect_analyze_data_refs_alignment): Likewise.
15256 (vect_analyze_group_access_1): Likewise.
15257 (vect_analyze_group_access): Likewise.
15258 (vect_analyze_data_ref_access): Likewise.
15259 (vect_analyze_data_ref_accesses): Likewise.
15260 (vect_vfa_segment_size): Likewise.
15261 (vect_small_gap_p): Likewise.
15262 (vectorizable_with_step_bound_p): Likewise.
15263 (vect_prune_runtime_alias_test_list): Likewise.
15264 (vect_analyze_data_refs): Likewise.
15265 (vect_supportable_dr_alignment): Likewise.
15266 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
15267 (vect_gen_prolog_loop_niters): Likewise.
15268 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
15269 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
15270 modify DR_STMT.
15271 (vect_recog_mask_conversion_pattern): Likewise.
15272 (vect_try_gather_scatter_pattern): Likewise.
15273 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
15274 to vect_get_store_cost.
15275 (vect_get_store_cost): Get stmt_info instead of DR.
15276 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
15277 (vect_get_load_cost): Get stmt_info instead of DR.
15278
15279 2018-06-01 Richard Biener <rguenther@suse.de>
15280
15281 PR middle-end/86017
15282 * gimple-fold.c (var_decl_component_p): Also allow offsetted
15283 vars wrapped in MEM_REFs.
15284
15285 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15286
15287 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15288 Fix subreg tests so that we only return a choice between
15289 GENERAL_REGS and FP_REGS if the original classes included both.
15290
15291 2018-06-01 Richard Biener <rguenther@suse.de>
15292
15293 PR ipa/85960
15294 * tree-ssa-structalias.c (get_function_part_constraint):
15295 Handle NULL fi->decl.
15296 (find_func_aliases_for_call): Properly handle indirect
15297 fi from direct call.
15298 (find_func_clobbers): Likewise.
15299 (ipa_pta_execute): Likewise.
15300 (create_variable_info_for): For functions that are ifunc_resolver
15301 resolve to a varinfo that contains the result of the resolver call.
15302 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
15303 aliases.
15304
15305 2018-05-31 Michael Collison <michael.collison@arm.com>
15306
15307 * config/aarch64/aarch64.md:
15308 (*fix_to_zero_extenddfdi2): New pattern.
15309 * gcc.target/aarch64/fix_extend1.c: New testcase.
15310
15311 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
15312
15313 PR middle-end/78809
15314 PR middle-end/83026
15315 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
15316 and BUILT_IN_STRNCMP_EQ.
15317 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
15318 BUILT_IN_STRNCMP_EQ.
15319 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
15320 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15321 (gimple_fold_builtin): Likewise.
15322 * tree-ssa-strlen.c (compute_string_length): New function.
15323 (determine_min_obsize): New function.
15324 (handle_builtin_string_cmp): New function to handle calls to
15325 string compare functions.
15326 (strlen_optimize_stmt): Add handling to builtin string compare
15327 calls.
15328 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
15329 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15330 * tree.c (build_common_builtin_nodes): Add new defines of
15331 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
15332
15333 2018-05-31 Jakub Jelinek <jakub@redhat.com>
15334
15335 PR target/85984
15336 * bb-reorder.c (pass_partition_blocks::gate): Return false for
15337 functions with naked attribute.
15338
15339 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
15340
15341 * config/i386/sse.md (avx_vec_concat<mode>):
15342 Substitute concat_tg_mode mode attribute with xtg_mode.
15343 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
15344 (concat_tg_mode): Remove mode attribute.
15345
15346 2018-05-31 Martin Sebor <msebor@redhat.com>
15347
15348 PR c/82063
15349 * calls.c (alloc_max_size): Correct a logic error/typo.
15350 Treat excessive arguments as infinite. Warn for invalid arguments.
15351 * doc/invoke.texi (-Walloc-size-larger-than): Update.
15352
15353 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
15354
15355 PR target/85829
15356 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
15357 and movx for Haswell.
15358
15359 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
15360 Cesar Philippidis <cesar@codesourcery.com>
15361
15362 PR middle-end/85879
15363 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
15364 when emitting error on private/firstprivate reductions.
15365 * omp-low.c (lower_omp_target): Avoid reference-type processing
15366 on pointers for firstprivate clause.
15367
15368 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15369
15370 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
15371 (st1x2): Likewise.
15372 (st1x3): Likewise.
15373 * config/aarch64/aarch64-simd.md
15374 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
15375 (aarch64_ld1_x3_<mode>): Likewise
15376 (aarch64_st1x2<VALLDIF:mode>): Likewise
15377 (aarch64_st1_x2_<mode>): Likewise
15378 (aarch64_st1x3<VALLDIF:mode>): Likewise
15379 (aarch64_st1_x3_<mode>): Likewise
15380 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
15381 (vld1_s8_x3): Likewise.
15382 (vld1_u16_x3): Likewise.
15383 (vld1_s16_x3): Likewise.
15384 (vld1_u32_x3): Likewise.
15385 (vld1_s32_x3): Likewise.
15386 (vld1_u64_x3): Likewise.
15387 (vld1_s64_x3): Likewise.
15388 (vld1_f16_x3): Likewise.
15389 (vld1_f32_x3): Likewise.
15390 (vld1_f64_x3): Likewise.
15391 (vld1_p8_x3): Likewise.
15392 (vld1_p16_x3): Likewise.
15393 (vld1_p64_x3): Likewise.
15394 (vld1q_u8_x3): Likewise.
15395 (vld1q_s8_x3): Likewise.
15396 (vld1q_u16_x3): Likewise.
15397 (vld1q_s16_x3): Likewise.
15398 (vld1q_u32_x3): Likewise.
15399 (vld1q_s32_x3): Likewise.
15400 (vld1q_u64_x3): Likewise.
15401 (vld1q_s64_x3): Likewise.
15402 (vld1q_f16_x3): Likewise.
15403 (vld1q_f32_x3): Likewise.
15404 (vld1q_f64_x3): Likewise.
15405 (vld1q_p8_x3): Likewise.
15406 (vld1q_p16_x3): Likewise.
15407 (vld1q_p64_x3): Likewise.
15408 (vst1_s64_x2): Likewise.
15409 (vst1_u64_x2): Likewise.
15410 (vst1_f64_x2): Likewise.
15411 (vst1_s8_x2): Likewise.
15412 (vst1_p8_x2): Likewise.
15413 (vst1_s16_x2): Likewise.
15414 (vst1_p16_x2): Likewise.
15415 (vst1_s32_x2): Likewise.
15416 (vst1_u8_x2): Likewise.
15417 (vst1_u16_x2): Likewise.
15418 (vst1_u32_x2): Likewise.
15419 (vst1_f16_x2): Likewise.
15420 (vst1_f32_x2): Likewise.
15421 (vst1_p64_x2): Likewise.
15422 (vst1q_s8_x2): Likewise.
15423 (vst1q_p8_x2): Likewise.
15424 (vst1q_s16_x2): Likewise.
15425 (vst1q_p16_x2): Likewise.
15426 (vst1q_s32_x2): Likewise.
15427 (vst1q_s64_x2): Likewise.
15428 (vst1q_u8_x2): Likewise.
15429 (vst1q_u16_x2): Likewise.
15430 (vst1q_u32_x2): Likewise.
15431 (vst1q_u64_x2): Likewise.
15432 (vst1q_f16_x2): Likewise.
15433 (vst1q_f32_x2): Likewise.
15434 (vst1q_f64_x2): Likewise.
15435 (vst1q_p64_x2): Likewise.
15436 (vst1_s64_x3): Likewise.
15437 (vst1_u64_x3): Likewise.
15438 (vst1_f64_x3): Likewise.
15439 (vst1_s8_x3): Likewise.
15440 (vst1_p8_x3): Likewise.
15441 (vst1_s16_x3): Likewise.
15442 (vst1_p16_x3): Likewise.
15443 (vst1_s32_x3): Likewise.
15444 (vst1_u8_x3): Likewise.
15445 (vst1_u16_x3): Likewise.
15446 (vst1_u32_x3): Likewise.
15447 (vst1_f16_x3): Likewise.
15448 (vst1_f32_x3): Likewise.
15449 (vst1_p64_x3): Likewise.
15450 (vst1q_s8_x3): Likewise.
15451 (vst1q_p8_x3): Likewise.
15452 (vst1q_s16_x3): Likewise.
15453 (vst1q_p16_x3): Likewise.
15454 (vst1q_s32_x3): Likewise.
15455 (vst1q_s64_x3): Likewise.
15456 (vst1q_u8_x3): Likewise.
15457 (vst1q_u16_x3): Likewise.
15458 (vst1q_u32_x3): Likewise.
15459 (vst1q_u64_x3): Likewise.
15460 (vst1q_f16_x3): Likewise.
15461 (vst1q_f32_x3): Likewise.
15462 (vst1q_f64_x3): Likewise.
15463 (vst1q_p64_x3): Likewise.
15464
15465 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
15466
15467 * config/msp430/msp430.c (msp430_output_labelref): Prepend
15468 user_label_prefix to name.
15469
15470 * tree-core.h: Update comment about the format of NAME string
15471 passed to handler in attribute_spec.
15472
15473 * config/msp430/msp430.md: Remove erroneous subreg expression from
15474 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
15475 zero_extend{q,h}isi2.
15476
15477 2018-05-30 Borislav Petkov <bp@suse.de>
15478
15479 * doc/extend.texi: Document some architecture specific
15480 constraints and sort entries.
15481
15482 2018-05-30 Martin Sebor <msebor@redhat.com>
15483
15484 PR middle-end/85369
15485 * builtins.c (expand_builtin_stpcpy_1): New function.
15486 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
15487 only if the former succeeds.
15488
15489 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15490
15491 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
15492 in saphira.
15493
15494 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15495
15496 * doc/invoke.texi (-flinker-output): Document
15497
15498 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15499
15500 * passes.c (ipa_write_summaries): Only modify statements if body
15501 is in memory.
15502 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
15503 incrementally linking.
15504 (ipa_passes): Likewise.
15505 * lto-cgraph.c (lto_output_node): When incrementally linking do not
15506 pass down resolution info.
15507 * common.opt (flag_incremental_link): Update info.
15508 * gcc.c (plugin specs): Turn flinker-output=* to
15509 -plugin-opt=-linker-output-known
15510 * toplev.c (compile_file): Also cut compilation when doing incremental
15511 link.
15512 * flag-types. (enum lto_partition_model): Add
15513 LTO_LINKER_OUTPUT_NOLTOREL.
15514 (invoke.texi): Add -flinker-output docs.
15515 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
15516 link same way as WPA; do not stream in dead initializers.
15517
15518 * dwarf2out.c (dwarf2out_die_ref_for_decl,
15519 darf2out_register_external_decl): Support incremental link.
15520
15521 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15522
15523 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
15524
15525 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15526
15527 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
15528 it down to simple_object_copy_lto_debug_sections.
15529 (run_gcc): Determine incremental LTO link time and configure
15530 lto1 into non-wpa mode, disable renaming of debug sections.
15531
15532 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
15533
15534 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
15535 descriptions of various incorrectly documented functions.
15536
15537 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
15538
15539 Revert:
15540 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15541 address check not strict.
15542
15543 2018-05-30 Richard Biener <rguenther@suse.de>
15544
15545 PR tree-optimization/85964
15546 * tracer.c (better_p): Drop initialized count check, we only
15547 call the function with initialized counts now.
15548 (find_best_successor): Do find a best edge if one
15549 has uninitialized count.
15550 (find_best_predecessor): Likewise. Do BB frequency check only
15551 if count is initialized.
15552
15553 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
15554
15555 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
15556 (aarch64_ldrstr_offset_compare): New.
15557 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
15558 load/store orderings.
15559 (aarch64_gen_adjusted_ldpstp): Likewise.
15560
15561 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
15562
15563 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15564 Check for subset of GENERAL_REGS and FP_REGS.
15565 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
15566 r=w alternative.
15567
15568 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
15569
15570 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
15571 and wi::to_poly_offset. Add the current offset and then check
15572 whether the sum fits, rather than using an unchecked addition of
15573 a checked term. Check for a shwi rather than a uhwi.
15574 * expr.c (get_bit_range): Use tree_to_poly_uint64.
15575 (store_constructor): Use poly_int_tree_p.
15576 (expand_expr_real_1): Likewise.
15577 * function.c (assign_temp): Likewise.
15578 * fold-const.c (const_binop): Use poly_int_tree_p and
15579 wi::to_poly_offset.
15580 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
15581 division.
15582 * ipa-icf-gimple.c (func_checker::compare_operand): Use
15583 to_poly_offset for MEM offsets.
15584 * ipa-icf.c (sem_variable::equals): Likewise.
15585 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
15586 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
15587 wi::to_poly_offset for BIT_FIELD_REF offsets.
15588 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
15589 wi::to_poly_offset.
15590 * var-tracking.c (emit_note_insn_var_location): Use
15591 tree_to_poly_uint64.
15592
15593 2018-05-29 Jim Wilson <jimw@sifive.com>
15594
15595 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
15596
15597 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
15598
15599 PR target/85950
15600 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
15601 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
15602 sequence.
15603 (sse4_1_round<mode>2): Use nonimmediate_operand
15604 for operand 1 predicate.
15605
15606 2018-05-29 Martin Sebor <msebor@redhat.com>
15607 Richard Biener <rguenther@suse.de>
15608
15609 PR testsuite/85888
15610 * calls.c (get_size_range): Call determine_value_range instead
15611 of get_value_range..
15612 * tree-vrp.h (determine_value_range): Declared new function.
15613 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
15614
15615 2018-05-29 Richard Biener <rguenther@suse.de>
15616
15617 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
15618 sure to use non-pattern stmts for get_earlier_stmt arguments.
15619 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
15620 called on pattern stmts.
15621 (get_later_stmt): Likewise.
15622
15623 2018-05-29 Martin Liska <mliska@suse.cz>
15624
15625 PR gcov-profile/85759
15626 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
15627 env variables.
15628
15629 2018-05-29 Jakub Jelinek <jakub@redhat.com>
15630
15631 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
15632 VEC_UNPACK_*_EXPR.
15633 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
15634 VEC_PACK_*_EXPR.
15635
15636 PR target/85918
15637 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15638 VEC_PACK_FLOAT_EXPR): New tree codes.
15639 * tree-pretty-print.c (op_code_prio): Handle
15640 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15641 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15642 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15643 * tree-inline.c (estimate_operator_cost): Likewise.
15644 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
15645 * fold-const.c (const_binop): Likewise.
15646 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
15647 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15648 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
15649 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
15650 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15651 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15652 * expr.c (expand_expr_real_2): Likewise.
15653 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
15654 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
15655 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
15656 optabs.
15657 * optabs.c (expand_widen_pattern_expr): For
15658 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
15659 sign from result type rather than operand's type.
15660 (expand_binop_directly): For vec_packu_float_optab and
15661 vec_packs_float_optab allow result type to be different from operand's
15662 type.
15663 * optabs-tree.c (optab_for_tree_code): Handle
15664 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15665 VEC_PACK_FLOAT_EXPR. Formatting fixes.
15666 * tree-vect-generic.c (expand_vector_operations_1): Handle
15667 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15668 VEC_PACK_FLOAT_EXPR.
15669 * tree-vect-stmts.c (supportable_widening_operation): Handle
15670 FIX_TRUNC_EXPR.
15671 (supportable_narrowing_operation): Handle FLOAT_EXPR.
15672 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
15673 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
15674 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
15675 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
15676 mode attributes.
15677 (vec_pack<floatprefix>_float_<mode>): New expander.
15678 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
15679 attributes.
15680 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
15681 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
15682 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
15683 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
15684 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
15685 Document.
15686 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
15687 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
15688 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15689 VEC_PACK_FLOAT_EXPR): Document.
15690
15691 2018-05-29 Richard Biener <rguenther@suse.de>
15692
15693 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
15694 member.
15695 (stmt_vec_info_vec): Make pointer.
15696 (init_stmt_vec_info_vec): Remove.
15697 (free_stmt_vec_info_vec): Likewise.
15698 (set_stmt_vec_info_vec): New function.
15699 (free_stmt_vec_infos): Likewise.
15700 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
15701 (set_vinfo_for_stmt): Likewise.
15702 (get_earlier_stmt): Likewise.
15703 (get_later_stmt): Likewise.
15704 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
15705 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
15706 (vec_info::~vec_info): Free stmt_vec_infos.
15707 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
15708 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
15709 (pass_slp_vectorize::execute): Likewise.
15710 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
15711 (free_stmt_vec_info_vec): Likewise.
15712 (set_stmt_vec_info_vec): New function.
15713 (free_stmt_vec_infos): Likewise.
15714 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
15715 the global stmt_vec_info_vec.
15716 * tree-parloops.c (gather_scalar_reductions): Use
15717 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
15718 vector.
15719
15720 2018-05-29 Richard Biener <rguenther@suse.de>
15721
15722 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
15723
15724 2018-05-29 Martin Liska <mliska@suse.cz>
15725 David Malcolm <dmalcolm@redhat.com>
15726
15727 * vec.c (test_reverse): New.
15728 (vec_c_tests): Add new test.
15729 * vec.h (vl_ptr>::reverse): New function.
15730
15731 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
15732
15733 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
15734
15735 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
15736 and later.
15737
15738 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
15739
15740 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
15741
15742 2018-05-28 Richard Biener <rguenther@suse.de>
15743
15744 PR tree-optimization/85933
15745 * tree-vect-data-refs.c (vect_record_base_alignments): Only
15746 look at stmts marked as vectorizable.
15747
15748 2018-05-28 Richard Biener <rguenther@suse.de>
15749
15750 PR tree-optimization/85934
15751 * tree-vect-generic.c (expand_vector_operations_1): Hoist
15752 vector boolean check before scalar optimization.
15753
15754 2018-05-28 Jakub Jelinek <jakub@redhat.com>
15755
15756 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
15757 for armv5te.
15758
15759 2018-05-28 Mark Wielaard <mark@klomp.org>
15760
15761 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
15762 if it is an expression containing a minus sign.
15763
15764 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
15765
15766 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
15767
15768 2018-05-27 Paul Koning <ni1d@arrl.net>
15769
15770 * config/pdp11/pdp11.md (truncsihi2): Remove.
15771
15772 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
15773 Chung-Ju Wu <jasonwucj@gmail.com>
15774
15775 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
15776 implementation.
15777 (unaligned_store_dw): Ditto.
15778 * config/nds32/nds32-memory-manipulation.c
15779 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
15780 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
15781 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
15782 (emit_setmem_word_loop): Rename to ...
15783 (emit_setmem_doubleword_loop): ... this.
15784 (nds32_gen_dup_4_byte_to_word_value): New function.
15785 (nds32_gen_dup_8_byte_to_double_word_value): New function.
15786 (nds32_expand_setmem_loop): Refine implementation.
15787 (nds32_expand_setmem_loop_v3m): Ditto.
15788 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
15789 pattern.
15790
15791 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15792
15793 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
15794
15795 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15796
15797 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
15798 (nds32_init_machine_status): Initialize machine->attr_naked_p and
15799 machine->attr_no_prologue_p.
15800 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
15801 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
15802 (nds32_expand_epilogue): Consider attr_naked_p.
15803 (nds32_expand_epilogue_v3pop): Likewise.
15804 (nds32_can_use_return_insn): Likewise.
15805 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
15806 attr_no_prologue_p fields.
15807 * config/nds32/nds32.opt (mret-in-naked-func): New option.
15808
15809 2018-05-27 Jakub Jelinek <jakub@redhat.com>
15810
15811 PR target/85918
15812 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
15813 attributes.
15814 * config/i386/sse.md
15815 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
15816 Rename to ...
15817 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
15818 ... this.
15819 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
15820 Rename to ...
15821 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
15822 ... this.
15823 (*<floatsuffix>floatv2div2sf2): Rename to ...
15824 (*float<floatunssuffix>v2div2sf2): ... this.
15825 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
15826 (float<floatunssuffix>v2div2sf2_mask): ... this.
15827 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
15828 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
15829 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
15830 to ...
15831 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
15832 ... this.
15833 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15834 Rename to ...
15835 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15836 ... this.
15837 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15838 Rename to ...
15839 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15840 ... this.
15841 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
15842 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
15843 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
15844 gen_ufix_truncv8dfv8si2.
15845 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
15846 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
15847 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
15848 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
15849 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
15850 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
15851 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
15852 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
15853
15854 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
15855
15856 PR target/85900
15857 PR target/85345
15858 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
15859
15860 2018-05-25 Jim Wilson <jimw@sifive.com>
15861
15862 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
15863 * config/riscv/riscv.c (struct machine_function): Add
15864 interrupt_handler_p and attribute_checked_p fields.
15865 (riscv_attribute_table): Add interrupt.
15866 (riscv_interrupt_type_p): New.
15867 (riscv_save_reg_p): Save extra regs for interrupt handler.
15868 (riscv_use_save_libcall): Return false for interrupt handler.
15869 (riscv_first_stack_step): Add forward declaration.
15870 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
15871 for interrupt handler with large frame. Use it for saved reg list.
15872 (riscv_expand_prologue): Move flag_stack_usage_info support to
15873 eliminate duplication.
15874 (riscv_expand_epilogue): Generate mret for interrupt handler.
15875 (riscv_epilogue_uses): New.
15876 (riscv_can_use_return_insn): Return false for interrupt handler.
15877 (riscv_function_ok_for_sibcall): Likewise.
15878 (riscv_set_current_function): Add interrupt handler support.
15879 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
15880 * config/riscv/riscv.md (UNSPECV_MRET): New.
15881 (GP_REGNUM): New.
15882 (riscv_frflags, riscv_fsflags): Use tab after opcode.
15883 (riscv_mret): New.
15884 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
15885
15886 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
15887
15888 PR tree-optimization/85712
15889 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
15890 this candidate has already been replaced in-situ by a copy.
15891
15892 2018-05-25 Jason Merrill <jason@redhat.com>
15893
15894 PR c++/80485 - inline function non-zero address.
15895 * symtab.c (nonzero_address): Check DECL_COMDAT.
15896
15897 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
15898
15899 PR target/83628
15900 * config/alpha/alpha.md (ashlsi3): New insn pattern.
15901 (*ashlsi_se): Rename from *ashldi_se. Define as sign
15902 extension of SImode operation. Use const123_operand predicate.
15903 (*saddsi_1): Remove.
15904 (*saddl_se_1): Ditto.
15905 (*ssubsi_1): Ditto.
15906 (*ssubl_se_1): Ditto.
15907 * config/alpha/predicates.md (const123_operand): New predicate.
15908 * config/alpha/constraints.md (P): Use IN_RANGE.
15909
15910 2018-05-25 Richard Biener <rguenther@suse.de>
15911
15912 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
15913 defaulted to true.
15914 (ref_maybe_used_by_stmt_p): Likewise.
15915 (stmt_may_clobber_ref_p): Likewise.
15916 (stmt_may_clobber_ref_p_1): Likewise.
15917 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
15918 and pass it along.
15919 (ref_maybe_used_by_stmt_p): Likewise.
15920 (stmt_may_clobber_ref_p): Likewise.
15921 (stmt_may_clobber_ref_p_1): Likewise.
15922 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
15923 the alias oracle to disambiguate DRs with stmts DR analysis
15924 couldn't handle.
15925 (vect_analyze_data_refs): Do not give up on not analyzable
15926 DRs for BB vectorization. Remove code truncating the dataref
15927 vector.
15928
15929 2018-05-25 Jakub Jelinek <jakub@redhat.com>
15930
15931 PR target/85832
15932 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
15933 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
15934 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
15935
15936 2018-05-25 Richard Biener <rguenther@suse.de>
15937
15938 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
15939 function, combining stmt data ref gathering and fatal analysis
15940 parts.
15941 (vect_analyze_data_refs): Remove now redudnant code and simplify.
15942 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
15943 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
15944 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
15945 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
15946
15947 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15948
15949 PR tree-optimization/85720
15950 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
15951 SCC if all partitions are builtins.
15952 (version_loop_by_alias_check): New parameter. Generate cancelable
15953 runtime alias check if all partitions are builtins.
15954 (distribute_loop): Update call to above function.
15955
15956 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15957
15958 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
15959 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
15960 (parm_default_def_partition_arg): Ditto.
15961 (set_parm_default_def_partition): Ditto.
15962 (get_parm_default_def_partitions): Ditto and make it static.
15963 (get_undefined_value_partitions): Ditto and make it static.
15964 (remove_ssa_form): Refactor call to init_var_map here.
15965 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
15966 computation for loop region.
15967 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
15968 (register_default_def): Delete.
15969 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
15970 (parm_default_def_partition_arg): Ditto.
15971 (set_parm_default_def_partition): Ditto.
15972 (get_parm_default_def_partitions): Ditto and make it static.
15973 (get_undefined_value_partitions): Ditto and make it static.
15974 (coalesce_with_default, coalesce_with_default): Update comment.
15975 (create_coalesce_list_for_region): New func factored out from
15976 create_outofssa_var_map.
15977 (populate_coalesce_list_for_outofssa): New func factored out from
15978 create_outofssa_var_map and coalesce_ssa_name.
15979 (create_outofssa_var_map): Delete.
15980 (coalesce_ssa_name): Refactor to support live range computation.
15981 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
15982 (get_parm_default_def_partitions): Delete.
15983 (get_undefined_value_partitions): Ditto.
15984 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
15985 computation for loop region.
15986 (new_tree_live_info, loe_visit_block): Ditto.
15987 (live_worklist, set_var_live_on_entry): Ditto.
15988 (calculate_live_on_exit, verify_live_on_entry): Ditto.
15989 * tree-ssa-live.h (struct _var_map): New fields.
15990 (init_var_map): Change decl.
15991 (region_contains_p): New.
15992
15993 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15994
15995 * tree-ssa-live.h (live_merge_and_clear): Delete.
15996
15997 2018-05-25 Richard Biener <rguenther@suse.de>
15998
15999 PR c++/85912
16000 * tree-dump.c (dequeue_and_dump): Remove access to removed
16001 operand 2 of a SWITCH_EXPR.
16002
16003 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16004
16005 * doc/sourcebuild.texi (vect_double_cond_arith): Include
16006 multiplication and division.
16007 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
16008 (cond_udiv@var{m}, cond_umod@var{m}): Document.
16009 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
16010 (cond_udiv_optab, cond_umod_optab): New optabs.
16011 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
16012 (IFN_COND_RDIV): New internal functions.
16013 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
16014 TRUNC_MOD_EXPR and RDIV_EXPR.
16015 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
16016 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
16017 New unspecs.
16018 (SVE_INT_BINARY): Include mult.
16019 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
16020 (optab, sve_int_op): Handle mult.
16021 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
16022 UNSPEC_COND_DIV.
16023 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
16024 for SVE_INT_BINARY_SD.
16025
16026 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16027
16028 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
16029 (optab, sve_int_op): Handle div and udiv.
16030 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
16031 for SVE_INT_BINARY_SD.
16032 (*<optab><mode>3): New insn for the same.
16033
16034 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16035
16036 * tree-vect-patterns.c: Include predict.h.
16037 (vect_recog_divmod_pattern): Restrict check for division support
16038 to when optimizing for size.
16039
16040 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16041
16042 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
16043 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
16044 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
16045 (gimple_match_op::set_op): Likewise.
16046 (gimple_resimplify4): Declare.
16047 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
16048 (expr::gen_transform): Likewise.
16049 (decision_tree::gen): Generate a simplification routine for 4 operands.
16050 * gimple-match-head.c (gimple_simplify): Add an overload for
16051 4 operands. In the top-level function, handle up to 4 call
16052 arguments and call gimple_resimplify4.
16053 (gimple_resimplify4): New function.
16054 (build_call_internal): Pass a fourth operand.
16055 (maybe_push_to_seq): Likewise.
16056 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
16057 Fold VEC_COND_EXPRs of an operation and a default value into
16058 an IFN_COND_* function if possible.
16059 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
16060 New unspecs.
16061 (SVE_COND_FP_BINARY): Include them.
16062 (optab, sve_fp_op): Handle them.
16063 (SVE_INT_BINARY_REV): New code iterator.
16064 (SVE_COND_FP_BINARY_REV): New int iterator.
16065 (commutative): New int attribute.
16066 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
16067 Declare.
16068 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
16069 function.
16070 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
16071 (*cond_<optab><mode>): New patterns for reversed operands.
16072
16073 2018-05-25 Richard Biener <rguenther@suse.de>
16074
16075 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
16076 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
16077 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
16078 (STMT_VINFO_GROUPED_ACCESS): Adjust.
16079 * tree-vect-data-refs.c (everywhere): Adjust users.
16080 * tree-vect-loop.c (everywhere): Likewise.
16081 * tree-vect-slp.c (everywhere): Likewise.
16082 * tree-vect-stmts.c (everywhere): Likewise.
16083 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
16084
16085 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16086
16087 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
16088 Rename to...
16089 (gcc_cv_as_section_exclude): ... this.
16090 Try Solaris as #exclude syntax.
16091 * configure: Regenerate.
16092 * config.in: Regenerate.
16093 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
16094 SECTION_EXCLUDE.
16095 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
16096 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
16097
16098 * varasm.c (default_elf_asm_named_section): Don't check if
16099 HAVE_GAS_SECTION_EXCLUDE is defined.
16100
16101 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16102
16103 * doc/md.texi: Update the documentation of the cond_* optabs
16104 to mention the new final operand. Fix GET_MODE_NUNITS call.
16105 Describe the scalar case too.
16106 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
16107 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
16108 instead of 2.
16109 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
16110 (get_conditional_internal_fn): Update comment.
16111 * tree-vect-loop.c (vectorizable_reduction): Pass the original
16112 accumulator value as a final argument to conditional functions.
16113 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
16114 a define_expand and add an "else" operand. Assert for now that
16115 the else operand is equal to operand 2. Use SVE_INT_BINARY and
16116 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
16117 (*cond_<optab><mode>): New patterns.
16118 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
16119 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
16120 (UNSPEC_COND_EOR): Delete.
16121 (optab): Remove associated mappings.
16122 (SVE_INT_BINARY): New code iterator.
16123 (sve_int_op): Remove int attribute and add "minus" to the code
16124 attribute.
16125 (SVE_COND_INT_OP): Delete.
16126 (SVE_COND_FP_OP): Rename to...
16127 (SVE_COND_FP_BINARY): ...this.
16128
16129 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16130
16131 * optabs.c (can_reuse_operands_p): New function.
16132 (maybe_legitimize_operands): Try to reuse the results for
16133 earlier operands.
16134
16135 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16136
16137 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
16138 Add {q} suffix to insn mnemonic.
16139
16140 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
16141
16142 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
16143 (msp430_warn_func_return): New.
16144
16145 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
16146
16147 * fold-const.c (tree_nonzero_bits): New function.
16148 * fold-const.h (tree_nonzero_bits): Likewise.
16149 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
16150 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
16151
16152 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
16153
16154 PR target/85900
16155 PR target/85345
16156 * varasm.c (assemble_alias): Check ifunc_resolver only on
16157 FUNCTION_DECL.
16158
16159 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16160
16161 PR target/85903
16162 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
16163 when memory input operand is handled.
16164
16165 2018-05-24 Luis Machado <luis.machado@linaro.org>
16166
16167 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
16168 global.
16169 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
16170
16171 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16172
16173 * match.pd: Delay FMA folds until after vectorization.
16174
16175 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
16176
16177 PR target/83009
16178 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
16179 address check not strict.
16180
16181 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16182
16183 * gimple-match.h (gimple_match_op): New class.
16184 (mprts_hook): Replace parameters with a gimple_match_op *.
16185 (maybe_build_generic_op): Likewise.
16186 (gimple_simplified_result_is_gimple_val): Replace parameters with
16187 a const gimple_match_op *.
16188 (gimple_simplify): Replace code_helper * and tree * parameters with
16189 a gimple_match_op * parameter.
16190 (gimple_resimplify1): Replace code_helper *, tree and tree *
16191 parameters with a gimple_match_op * parameter.
16192 (gimple_resimplify2): Likewise.
16193 (gimple_resimplify3): Likewise.
16194 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
16195 parameters with a gimple_match_op * parameter.
16196 * gimple-match-head.c (gimple_simplify): Change prototypes of
16197 auto-generated functions to take a gimple_match_op * instead of
16198 separate code_helper * and tree * parameters. Make the same
16199 change in the top-level overload and update calls to the
16200 gimple_resimplify routines. Update calls to the auto-generated
16201 functions and to maybe_push_res_to_seq in the publicly-facing
16202 operation-specific gimple_simplify overloads.
16203 (gimple_match_op::MAX_NUM_OPS): Define.
16204 (gimple_resimplify1): Replace rcode and ops with a single res_op
16205 parameter. Update call to gimple_simplify.
16206 (gimple_resimplify2): Likewise.
16207 (gimple_resimplify3): Likewise.
16208 (mprts_hook): Replace parameters with a gimple_match_op *.
16209 (maybe_build_generic_op): Likewise.
16210 (build_call_internal): Replace type, nargs and ops with
16211 a gimple_match_op *.
16212 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
16213 with a single gimple_match_op *. Update calls to mprts_hook,
16214 build_call_internal and gimple_simplified_result_is_gimple_val.
16215 Factor out code that is common to the tree_code and combined_fn cases.
16216 * genmatch.c (expr::gen_transform): Replace tem_code and
16217 tem_ops with a gimple_match_op called tem_op. Update calls
16218 to the gimple_resimplify functions and maybe_push_res_to_seq.
16219 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
16220 res_ops. Update call to the gimple_resimplify functions.
16221 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
16222 (decision_tree::gen): Make the functions take a gimple_match_op *
16223 called res_op instead of separate res_code and res_ops parameters.
16224 Update call accordingly.
16225 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
16226 and ops with a single res_op parameter. Update calls to
16227 maybe_build_generic_op and maybe_push_res_to_seq.
16228 (fold_stmt_1): Update calls to gimple_simplify and
16229 replace_stmt_with_simplification.
16230 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
16231 and gimple_simplified_result_is_gimple_val.
16232 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
16233 gimple_simplify.
16234 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
16235 with a gimple_match_op *.
16236 (vn_nary_build_or_lookup): Likewise. Update call to
16237 vn_nary_build_or_lookup_1.
16238 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
16239 gimple_match_op *. Update calls to the gimple_resimplify routines
16240 and to gimple_simplified_result_is_gimple_val.
16241 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
16242 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
16243 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
16244 (visit_nary_op): Likewise.
16245 (visit_reference_op_load): Likewise.
16246
16247 2018-05-23 Luis Machado <luis.machado@linaro.org>
16248
16249 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
16250 modifier for printing the step amount.
16251
16252 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
16253
16254 PR target/78849
16255 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
16256 types.
16257
16258 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
16259
16260 * doc/sourcebuild.texi (Endianness): New subsubsection.
16261
16262 2018-05-23 Luis Machado <luis.machado@linaro.org>
16263
16264 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16265 <prefetch_dynamic_strides>: New const bool field.
16266 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16267 prefetch_dynamic_strides.
16268 (exynosm1_prefetch_tune): Likewise.
16269 (thunderxt88_prefetch_tune): Likewise.
16270 (thunderx_prefetch_tune): Likewise.
16271 (thunderx2t99_prefetch_tune): Likewise.
16272 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
16273 false.
16274 (aarch64_override_options_internal): Update to set
16275 PARAM_PREFETCH_DYNAMIC_STRIDES.
16276 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
16277 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
16278 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
16279 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
16280 prefetch-dynamic-strides setting.
16281
16282 2018-05-23 Luis Machado <luis.machado@linaro.org>
16283
16284 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16285 <minimum_stride>: New const int field.
16286 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16287 minimum_stride field defaulting to -1.
16288 (exynosm1_prefetch_tune): Likewise.
16289 (thunderxt88_prefetch_tune): Likewise.
16290 (thunderx_prefetch_tune): Likewise.
16291 (thunderx2t99_prefetch_tune): Likewise.
16292 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
16293 <default_opt_level>: Set to 3.
16294 (aarch64_override_options_internal): Update to set
16295 PARAM_PREFETCH_MINIMUM_STRIDE.
16296 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
16297 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
16298 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
16299 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
16300 stride is constant and is below the minimum stride threshold.
16301
16302 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16303
16304 * config/arm/arm-cpus.in (mode26): Delete.
16305 (armv4): Delete mode26 reference.
16306 * config/arm/arm.c (arm_configure_build_target): Delete use of
16307 isa_bit_mode26.
16308
16309 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16310
16311 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
16312 New insn pattern.
16313 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
16314 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
16315 for non-SSE modes.
16316 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
16317 (floatunsdidf2): Ditto.
16318
16319 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16320
16321 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
16322 (fixuns_trunc<mode>si2_avx512f): Ditto.
16323 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
16324 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
16325 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
16326
16327 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16328
16329 PR rtl-optimization/79985
16330 * df-scan.c (df_insn_refs_collect): Remove special case for
16331 global registers and asm statements.
16332
16333 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16334
16335 * extend.texi (Global Register Variables): Rewrite the bullet list.
16336 Note that the register is available for allocation. Note that access
16337 via inline asm must use constraints. Add note about async-signal
16338 handlers. Remove paragraph about automagic register selection.
16339
16340 2018-05-23 Richard Biener <rguenther@suse.de>
16341
16342 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
16343 of fixed offset from memset VN.
16344
16345 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
16346
16347 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
16348 first_interp field.
16349 (alloc_cand_and_find_basis): Initialize first_interp field.
16350 (slsr_process_mul): Modify first_interp field.
16351 (slsr_process_add): Likewise.
16352 (slsr_process_cast): Modify first_interp field for each new
16353 interpretation.
16354 (slsr_process_copy): Likewise.
16355 (dump_candidate): Dump first_interp field.
16356 (replace_mult_candidate): Process all interpretations, not just
16357 subsequent ones.
16358 (replace_rhs_if_not_dup): Likewise.
16359 (replace_one_candidate): Likewise.
16360
16361 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
16362
16363 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
16364 Add new boolean.
16365 (aarch64_needs_frame_chain): New function.
16366 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
16367
16368 2018-05-23 Sudakshina Das <sudi.das@arm.com>
16369
16370 PR target/84882
16371 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
16372 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
16373 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
16374 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
16375 as true for strict-align.
16376 (aarch64_can_inline_p): Perform checks even when callee has no
16377 attributes to check for strict alignment.
16378 * doc/extend.texi (AArch64 Function Attributes): Document
16379 no-strict-align.
16380 * doc/invoke.texi: (AArch64 Options): Likewise.
16381
16382 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
16383
16384 PR tree-optimization/85853
16385 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
16386 the handling of the root of the node to...
16387 (vect_slp_analyze_node_operations_1): ...this new function,
16388 and run the whole thing with the child nodes' def types
16389 set according to their SLP node's def type.
16390
16391 2018-05-23 Richard Biener <rguenther@suse.de>
16392
16393 PR middle-end/85874
16394 * tree-data-ref.c (create_runtime_alias_checks): Defer
16395 and ignore overflow warnings.
16396
16397 2018-05-23 Yury Gribov <tetra2005@gmail.com>
16398
16399 PR tree-optimization/85822
16400 * tree-vrp.c (is_masked_range_test): Fix handling of negative
16401 constants.
16402
16403 2018-05-23 Richard Biener <rguenther@suse.de>
16404
16405 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
16406 memset constants via native_interpret_expr.
16407
16408 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
16409
16410 PR target/85345
16411 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
16412 attribute.
16413 (cgraph_node::create_alias): Likewise.
16414 (cgraph_node::get_availability): Check ifunc_resolver instead
16415 of looking up ifunc attribute.
16416 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
16417 * varasm.c (do_assemble_alias): Likewise.
16418 (assemble_alias): Likewise.
16419 (default_binds_local_p_3): Likewise.
16420 * cgraph.h (cgraph_node): Add ifunc_resolver.
16421 (cgraph_node::only_called_directly_or_aliased_p): Return false
16422 for IFUNC resolver.
16423 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
16424 attribute.
16425 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
16426 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
16427 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
16428 instead of looking up ifunc attribute.
16429
16430 2018-05-22 Luis Machado <luis.machado@linaro.org>
16431
16432 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
16433
16434 2018-05-22 Martin Sebor <msebor@redhat.com>
16435
16436 PR middle-end/85359
16437 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
16438 only when expasion succeeds.
16439 (expand_builtin_strcmp): Same.
16440 (expand_builtin_strncmp): Same.
16441
16442 2018-05-22 Martin Sebor <msebor@redhat.com>
16443
16444 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
16445
16446 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16447 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16448
16449 * config/aarch64/aarch64-ldpstp.md: Replace uses of
16450 aarch64_mem_pair_operand with memory_operand and delete operand swapping
16451 code.
16452 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16453 Add check for legitimate_address.
16454 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
16455 (aarch64_swap_ldrstr_operands): New.
16456 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
16457 Define prototype.
16458
16459 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16460 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16461
16462 * config/aarch64/aarch64.md: New patterns to generate stp
16463 and ldp.
16464 (store_pair_sw, store_pair_dw): New patterns to generate stp for
16465 single words and double words.
16466 (load_pair_sw, load_pair_dw): Likewise.
16467 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
16468 Delete.
16469 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
16470 Delete.
16471 * config/aarch64/aarch64-ldpstp.md: Modify peephole
16472 for different mode ldpstp and add peephole for merged zero stores.
16473 Likewise for loads.
16474 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16475 Add size check.
16476 (aarch64_gen_store_pair): Rename calls to match new patterns.
16477 (aarch64_gen_load_pair): Rename calls to match new patterns.
16478 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
16479 (load_pair<DREG:mode><DREG2:mode>): ... This.
16480 (store_pair<mode>): Rename to...
16481 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
16482 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
16483 New mode iterators.
16484 (V_INT_EQUIV): Handle SImode.
16485 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
16486 New predicate.
16487
16488 2018-05-22 Martin Sebor <msebor@redhat.com>
16489
16490 PR c/85623
16491 * calls.c (maybe_warn_nonstring_arg): Use string length to set
16492 or ajust the presumed bound on an operation to avoid unnecessary
16493 warnings.
16494
16495 2018-05-22 Martin Sebor <msebor@redhat.com>
16496
16497 PR tree-optimization/85826
16498 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
16499 assuming that a DECL necesarily has a constant size.
16500
16501 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
16502
16503 PR middle-end/85862
16504 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
16505
16506 2018-05-22 Richard Biener <rguenther@suse.de>
16507
16508 PR tree-optimization/85834
16509 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
16510 non-constant and non-zero memset arguments.
16511
16512 2018-05-22 Martin Liska <mliska@suse.cz>
16513
16514 PR ipa/85607
16515 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
16516
16517 2018-05-22 Richard Biener <rguenther@suse.de>
16518
16519 PR tree-optimization/85863
16520 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
16521 comparisons when vectype is specified.
16522 (vectorizable_condition): Do not specify vectype for
16523 vect_is_simple_cond when SLP vectorizing.
16524
16525 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
16526
16527 PR target/85657
16528 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
16529 define __ibm128 as long double.
16530 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
16531 as a distinct type when IEEE 128-bit support is enabled.
16532 (init_float128_ieee): Fix up conversions between IFmode and IEEE
16533 128-bit types to use the correct functions.
16534 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
16535 convert between 128-bit floating point types that have different
16536 modes but the same representation, instead of using gen_lowpart to
16537 makean alias.
16538 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
16539 KFmode.
16540 (IFKF_reg): New attributes to give the register constraints for
16541 IFmode and KFmode.
16542 (extend<mode>tf2_internal): New insns to mark an explicit
16543 conversion between 128-bit floating point types that have a
16544 different mode but share the same representation.
16545
16546 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
16547
16548 PR tree-optimization/85814
16549 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
16550 a null return from get_strinfo when unsharing the next
16551 strinfo in the chain.
16552
16553 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
16554
16555 PR gcc/84923
16556 * varasm.c (weak_finish): Clean up weak_decls.
16557
16558 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16559
16560 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
16561 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
16562 UNSPEC_UADALP values.
16563 * config/aarch64/iterators.md (ABAL): New int iterator.
16564 (ABDL2): Likewise.
16565 (ADALP): Likewise.
16566 (sur): Add mappings for the above.
16567 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
16568 New define_insn.
16569 (aarch64_<sur>abal<mode>_4): Likewise.
16570 (aarch64_<sur>adalp<mode>_3): Likewise.
16571 (<sur>sadv16qi): New define_expand.
16572
16573 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
16574
16575 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
16576 (*movdf_internal): Ditto.
16577 (*rcpsf2_sse): Ditto.
16578 (*rsqrtsf2_sse): Ditto.
16579 (*sqrt<mode>2_sse): Ditto.
16580
16581 2018-05-21 Tamar Christina <tamar.christina@arm.com>
16582
16583 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
16584 eor3q<mode>4.
16585 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
16586 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
16587 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
16588 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
16589 vbcaxq_s64): New.
16590 * config/aarch64/arm_neon.h: Likewise.
16591 * config/aarch64/iterators.md (VQ_I): New.
16592
16593 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
16594
16595 * config.gcc: Add arc/t-multilib-linux to tmake_file for
16596 arc*-*-linux*.
16597 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
16598 MULTILIB_DIRNAMES
16599
16600 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16601
16602 * config/nds32/constraints.md (S): New constraint.
16603 * config/nds32/nds32.md (call_internal): Use constraint S.
16604 (call_value_internal): Likewise.
16605 (sibcall_internal): Likewise.
16606 (sibcall_value_internal): Likewise.
16607
16608 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16609 Chung-Ju Wu <jasonwucj@gmail.com>
16610
16611 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
16612 into consideration.
16613
16614 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16615 Chung-Ju Wu <jasonwucj@gmail.com>
16616
16617 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
16618 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
16619 (nds32_rtx_costs_impl): Simplify.
16620 (nds32_address_cost_impl): Simplify.
16621 (nds32_init_rtx_costs): New function.
16622 (nds32_rtx_costs_speed_prefer): Likewise.
16623 (nds32_rtx_costs_size_prefer): Likewise.
16624 (nds32_address_cost_speed_prefer): Likewise.
16625 (nds32_address_cost_speed_fwprop): Likewise.
16626 (nds32_address_cost_size_prefer): Likewise.
16627 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
16628 * config/nds32/nds32.c (nds32_option_override): Use
16629 nds32_init_rtx_costs function.
16630
16631 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16632
16633 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
16634 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
16635 (TARGET_PIPELINE_N8): Likewise.
16636 (TARGET_PIPELINE_N10): Likewise.
16637 (TARGET_PIPELINE_N13): Likewise.
16638 (TARGET_PIPELINE_GRAYWOLF): Likewise.
16639
16640 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
16641
16642 * config/nds32/nds32-fpu.md: Update copyright year.
16643
16644 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16645
16646 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
16647
16648 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16649
16650 * config/nds32/nds32.c
16651 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
16652 * config/nds32/nds32.opt (minline-asm-r15): New option.
16653
16654 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16655
16656 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
16657 MASK_HW_ABS.
16658 * config/nds32/nds32.md (abssi2): New pattern.
16659
16660 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
16661
16662 * config/i386/i386.md (rex64namesuffix): New mode attribute.
16663 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
16664 Merge insn pattern from sse_cvtsi2ss<round_name> and
16665 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
16666 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
16667 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
16668 using SWI48 mode iterator.
16669 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
16670 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
16671 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
16672 pattern from sse_cvttss2si<round_saeonly_name>
16673 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
16674 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
16675 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
16676 using SWI48 mode iterator.
16677 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
16678 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
16679 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
16680 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
16681 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
16682 using SWI48 mode iterator.
16683 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
16684 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
16685 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
16686 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
16687 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
16688 SWI48 mode iterator.
16689 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
16690 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
16691 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
16692 pattern from sse_cvttsd2si<round_saeonly_name>
16693 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
16694
16695 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16696
16697 * config/nds32/nds32-md-auxiliary.c
16698 (nds32_valid_smw_lwm_base_p): Refine.
16699 (nds32_output_smw_single_word): Refine.
16700 (nds32_output_smw_double_word): New.
16701 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
16702
16703 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16704
16705 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
16706 (nds32_output_stack_pop): Refine.
16707 (nds32_expand_unaligned_load): Refine.
16708 (nds32_expand_unaligned_store): Refine.
16709
16710 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16711 Chung-Ju Wu <jasonwucj@gmail.com>
16712
16713 * config/nds32/constants.md: Add TP_REGNUM constant.
16714 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
16715 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
16716 UNSPEC_ADD32.
16717 * config/nds32/nds32-doubleword.md: Consider flag_pic.
16718 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
16719 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
16720 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
16721 and PIC code generation.
16722 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
16723 code generation.
16724 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
16725 optimization.
16726 * config/nds32/nds32.md: Support TLS and PIC.
16727 * config/nds32/nds32.c: Support TLS and PIC.
16728 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
16729 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
16730 predicate.
16731
16732 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16733
16734 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
16735 mode with E_ prefix.
16736
16737 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16738 Chung-Ju Wu <jasonwucj@gmail.com>
16739
16740 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
16741 * config/nds32/nds32-md-auxiliary.c
16742 (symbolic_reference_mentioned_p): New.
16743 (nds32_legitimize_ict_address): New.
16744 (nds32_expand_ict_move): New.
16745 (nds32_indirect_call_referenced_p): New.
16746 (nds32_symbol_binds_local_p): Delete.
16747 (nds32_long_call_p): Modify.
16748 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
16749 * config/nds32/nds32-protos.h
16750 (symbolic_reference_mentioned_p): Declare.
16751 (nds32_legitimize_ict_address): Declare.
16752 (nds32_expand_ict_move): Declare.
16753 (nds32_indirect_call_referenced_p): Declare.
16754 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
16755 (nds32_relax_group): Use nds32_ict_const_p as condition.
16756 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
16757 (nds32_asm_file_start): Output ict_model directive in asm code.
16758 (nds32_legitimate_address_p): Consider indirect call.
16759 (nds32_print_operand): Consider indirect call.
16760 (nds32_print_operand_address): Consider indirect call.
16761 (nds32_insert_attributes): Handle "indirect_call" attribute.
16762 (TARGET_LEGITIMATE_ADDRESS_P): Define.
16763 (TARGET_LEGITIMATE_CONSTANT_P): Define.
16764 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
16765 (TARGET_DELEGITIMIZE_ADDRESS): Define.
16766 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
16767 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
16768 (TARGET_ICT_MODEL_SMALL): Define.
16769 (TARGET_ICT_MODEL_LARGE): Define.
16770 * config/nds32/nds32.md (movsi): Consider ict model.
16771 (call, call_value): Consider ict model.
16772 (sibcall, sibcall_value): Consider ict model.
16773 * config/nds32/nds32.opt (mict-model): New option.
16774 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
16775 model.
16776
16777 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
16778 Monk Chiang <sh.chiang04@gmail.com>
16779 Jim Wilson <jimw@sifive.com>
16780
16781 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
16782 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
16783 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
16784 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
16785 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
16786 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
16787 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
16788 compute save_libcall_adjustment properly.
16789 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
16790 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
16791 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
16792 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
16793 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
16794 (ABI_SPEC): Handle mabi=ilp32e.
16795 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
16796 (RVE): Add RVE mask.
16797 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
16798 <-march>: Add rv32e as an example.
16799
16800 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
16801
16802 PR c++/82899
16803 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
16804 (intra_create_variable_infos): Handle C++ constructors.
16805
16806 2018-05-18 Martin Liska <mliska@suse.cz>
16807
16808 * passes.def: Remove a redundant pass.
16809
16810 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
16811
16812 PR bootstrap/85838
16813 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
16814
16815 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16816
16817 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
16818 (ARMv4): Update.
16819 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
16820 (ARMv6m): Update.
16821 (armv2, armv2a, armv3, armv3m): Delete architectures.
16822 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
16823 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
16824 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
16825 Delete cpus.
16826 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
16827 (*mulsidi3adddi): Likewise.
16828 (mulsidi3): Likewise.
16829 (*mulsidi3_nov6): Likewise.
16830 (umulsidi3): Likewise.
16831 (umulsidi3_nov6): Likewise.
16832 (umaddsidi4): Likewise.
16833 (*umulsidi3adddi): Likewise.
16834 (smulsi3_highpart): Likewise.
16835 (*smulsi3_highpart_nov6): Likewise.
16836 (umulsi3_highpart): Likewise.
16837 (*umulsi3_highpart_nov6): Likewise.
16838 * config/arm/arm.h (arm_arch3m): Delete.
16839 * config/arm/arm.c (arm_arch3m): Delete.
16840 (arm_option_override_internal): Update armv3-related comment.
16841 (arm_configure_build_target): Delete use of isa_bit_mode32.
16842 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
16843 (arm_rtx_costs_internal): Delete check of arm_arch3m.
16844 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
16845 (mulsa3): Likewise.
16846 (mulusa3): Likewise.
16847 * config/arm/arm-protos.h (arm_arch3m): Delete.
16848 * config/arm/arm-tables.opt: Regenerate.
16849 * config/arm/arm-tune.md: Likewise.
16850 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
16851 deleted architectures.
16852
16853 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16854
16855 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
16856 (armv5t, armv5te): New features.
16857 (ARMv5, ARMv5e): Delete fgroups.
16858 (ARMv5t, ARMv5te): Adjust for above changes.
16859 (ARMv6m): Likewise.
16860 (armv5, armv5e): Delete arches.
16861 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
16862 arm_arch5.
16863 (*call_reg_arm): Likewise.
16864 (*call_value_reg_armv5): Likewise.
16865 (*call_value_reg_arm): Likewise.
16866 (*call_symbol): Likewise.
16867 (*call_value_symbol): Likewise.
16868 (*sibcall_insn): Likewise.
16869 (*sibcall_value_insn): Likewise.
16870 (clzsi2): Likewise.
16871 (prefetch): Likewise.
16872 (define_split and define_peephole2 dependent on arm_arch5):
16873 Likewise.
16874 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
16875 arm_arch5e.
16876 (TARGET_ARM_QBIT): Likewise.
16877 (TARGET_DSP_MULTIPLY): Likewise.
16878 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
16879 (arm_arch5, arm_arch5e): Delete.
16880 (arm_arch5t, arm_arch5te): Declare.
16881 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
16882 (arm_arch5t): Declare.
16883 (arm_option_reconfigure_globals): Update for the above.
16884 (arm_options_perform_arch_sanity_checks): Update comment, replace
16885 use of arm_arch5 with arm_arch5t.
16886 (use_return_insn): Likewise.
16887 (arm_emit_call_insn): Likewise.
16888 (output_return_instruction): Likewise.
16889 (arm_final_prescan_insn): Likewise.
16890 (arm_coproc_builtin_available): Likewise.
16891 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
16892 arm_arch5e with arm_arch5t and arm_arch5te.
16893 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
16894 (arm_arch5t, arm_arch5te): Declare.
16895 * config/arm/arm-tables.opt: Regenerate.
16896 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
16897 * config/arm/t-multilib: Likewise.
16898 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
16899 instead of arm_arch5.
16900 (*call_reg_thumb1): Likewise.
16901 (*call_value_reg_thumb1_v5): Likewise.
16902 (*call_value_reg_thumb1): Likewise.
16903 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
16904 unreachable path.
16905 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
16906
16907 2018-05-18 Martin Liska <mliska@suse.cz>
16908
16909 PR gcov-profile/84846
16910 * doc/gcov.texi: Document -t option of gcov tool.
16911
16912 2018-05-18 Martin Liska <mliska@suse.cz>
16913
16914 PR gcov-profile/84846
16915 * gcov.c (print_usage): Add new -t option.
16916 (process_args): Handle the option.
16917 (generate_results): Use stdout as output when requested by
16918 the option.
16919
16920 2018-05-18 Martin Liska <mliska@suse.cz>
16921
16922 PR gcov-profile/84846
16923 * coverage.c (coverage_init): Write PWD to .gcno file.
16924 * doc/gcov.texi: Document how working directory is printed.
16925 * gcov-dump.c (dump_gcov_file): Print PWD.
16926 * gcov.c (output_intermediate_file): Likewise.
16927 (read_graph_file): Read PWD string.
16928 (output_lines): Print PWD.
16929
16930 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
16931
16932 PR middle-end/85817
16933 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
16934 for retval and return false if all args to phi are zero.
16935
16936 2018-05-18 Richard Biener <rguenther@suse.de>
16937
16938 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
16939 method.
16940 (evrp_dom_walker::before_dom_children): Call it.
16941
16942 2018-05-18 Richard Biener <rguenther@suse.de>
16943
16944 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
16945 results when processing array refs with variable index.
16946
16947 2018-05-18 Toon Moene <toon@moene.org>
16948
16949 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
16950 directly after that of -floop-interchange. Indicate that both
16951 options are enabled by default when specifying -O3.
16952
16953 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16954
16955 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
16956 iterator. Delete separate integer-mode vec_set<mode> expander.
16957 (aarch64_simd_vec_setv2di): Delete.
16958 (vec_setv2di): Delete.
16959 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
16960 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
16961 the "w, r" alternative.
16962
16963 2018-05-18 Martin Liska <mliska@suse.cz>
16964
16965 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
16966 * tree-pass.h (make_pass_lower_switch_O0): New function.
16967 * tree-switch-conversion.c (node_has_low_bound): Remove.
16968 (node_has_high_bound): Likewise.
16969 (node_is_bounded): Likewise.
16970 (class pass_lower_switch): Make it a template type and create
16971 two instances.
16972 (pass_lower_switch::execute): Add template argument.
16973 (make_pass_lower_switch): New function.
16974 (make_pass_lower_switch_O0): New function.
16975 (do_jump_if_equal): Remove.
16976 (emit_case_nodes): Simplify to just handle all 3 cases and leave
16977 all the hard work to tree optimization passes.
16978
16979 2018-05-18 Martin Liska <mliska@suse.cz>
16980
16981 * dbgcnt.c (limit_low): Renamed from limit.
16982 (limit_high): New variable.
16983 (dbg_cnt_is_enabled): Check for upper limit.
16984 (dbg_cnt): Adjust dumping.
16985 (dbg_cnt_set_limit_by_index): Add new argument for high
16986 value.
16987 (dbg_cnt_set_limit_by_name): Likewise.
16988 (dbg_cnt_process_single_pair): Parse new format.
16989 (dbg_cnt_process_opt): Use strtok.
16990 (dbg_cnt_list_all_counters): Remove 'value' and add
16991 'limit_high'.
16992 * doc/invoke.texi: Document changes.
16993
16994 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
16995
16996 * doc/sourcebuild.texi (scalar_all_fma): Document.
16997 * tree.def (FMA_EXPR): Delete.
16998 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
16999 * internal-fn.c (ternary_direct): New macro.
17000 (expand_ternary_optab_fn): Likewise.
17001 (direct_ternary_optab_supported_p): Likewise.
17002 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
17003 * builtins.c (fold_builtin_fma): Delete.
17004 (fold_builtin_3): Don't call it.
17005 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
17006 * expr.c (expand_expr_real_2): Likewise.
17007 * fold-const.c (operand_equal_p): Likewise.
17008 (fold_ternary_loc): Likewise.
17009 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
17010 * gimple.c (DEFTREECODE): Likewise.
17011 * gimplify.c (gimplify_expr): Likewise.
17012 * optabs-tree.c (optab_for_tree_code): Likewise.
17013 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
17014 * tree-eh.c (operation_could_trap_p): Likewise.
17015 (stmt_could_throw_1_p): Likewise.
17016 * tree-inline.c (estimate_operator_cost): Likewise.
17017 * tree-pretty-print.c (dump_generic_node): Likewise.
17018 (op_code_prio): Likewise.
17019 * tree-ssa-loop-im.c (stmt_cost): Likewise.
17020 * tree-ssa-operands.c (get_expr_operands): Likewise.
17021 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
17022 * fold-const-call.h (fold_fma): Delete.
17023 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
17024 CFN_FNMA and CFN_FNMS.
17025 (fold_fma): Delete.
17026 * genmatch.c (combined_fn): New enum.
17027 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
17028 (commutative_op): New function.
17029 (commutate): Use it. Handle more than 2 operands.
17030 (dt_operand::gen_gimple_expr): Use commutative_op.
17031 (parser::parse_expr): Allow :c to be used with non-binary
17032 operators if the commutative operand is known.
17033 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
17034 CFN_FMS, CFN_FNMA and CFN_FNMS.
17035 (backprop::process_assign_use): Remove FMA_EXPR handling.
17036 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
17037 (gen_hsa_fma): New function.
17038 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
17039 IFN_FNMA and IFN_FNMS.
17040 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
17041 * gimple-fold.h (follow_all_ssa_edges): Declare.
17042 * gimple-fold.c (follow_all_ssa_edges): New function.
17043 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
17044 gimple_build interface and use follow_all_ssa_edges to fold the result.
17045 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
17046 instead of checking for optabs directly.
17047 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
17048 rather than FMA_EXPRs.
17049 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
17050 call to IFN_FMA instead of an FMA_EXPR.
17051
17052 2018-05-17 Jim Wilson <jimw@sifive.com>
17053
17054 * expr.c (do_tablejump): When converting index to Pmode, if we have a
17055 sign extended promoted subreg, and the range does not have the sign bit
17056 set, then do a sign extend.
17057
17058 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
17059 test, check for sign extended subreg and/or constant operands, and
17060 do a sign extend in that case.
17061
17062 2018-05-17 Steve Ellcey <sellcey@cavium.com>
17063
17064 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
17065 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
17066 Add untyped.
17067 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
17068 Change logics_shift_reg to logics_shift_imm.
17069 (thunderx2t99_fp_loadpair_basic): Delete.
17070 (thunderx2t99_fp_storepair_basic): Delete.
17071 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
17072 (thunderx2t99_asimd_polynomial): Delete.
17073 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
17074 and neon_fp_mul_d_scalar_q.
17075 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
17076 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
17077 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
17078 (thunderx2t99_asimd_lut): Add missing tbl types.
17079 (thunderx2t99_asimd_ext): Delete.
17080 (thunderx2t99_asimd_load1_1_mult): Delete.
17081 (thunderx2t99_asimd_load1_2_mult): Delete.
17082 (thunderx2t99_asimd_load1_ldp): New.
17083 (thunderx2t99_asimd_load1): New.
17084 (thunderx2t99_asimd_load2): Add missing *load2* types.
17085 (thunderx2t99_asimd_load3): New.
17086 (thunderx2t99_asimd_load4): New.
17087 (thunderx2t99_asimd_store1_1_mult): Delete.
17088 (thunderx2t99_asimd_store1_2_mult): Delete.
17089 (thunderx2t99_asimd_store2_mult): Delete.
17090 (thunderx2t99_asimd_store2_onelane): Delete.
17091 (thunderx2t99_asimd_store_stp): New.
17092 (thunderx2t99_asimd_store1): New.
17093 (thunderx2t99_asimd_store2): New.
17094 (thunderx2t99_asimd_store3): New.
17095 (thunderx2t99_asimd_store4): New.
17096
17097 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
17098
17099 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
17100 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
17101
17102 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
17103 Segher Boessenkool <segher@kernel.crashing.org>
17104
17105 PR target/85698
17106 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
17107 operand.
17108
17109 2018-05-17 Richard Biener <rguenther@suse.de>
17110
17111 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
17112 for pruning loop and prune defs feeding only already visited PHIs.
17113
17114 2018-05-17 Richard Biener <rguenther@suse.de>
17115
17116 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
17117
17118 2018-05-17 Bin Cheng <bin.cheng@arm.com>
17119 Richard Biener <rguenther@suse.de>
17120
17121 PR tree-optimization/85793
17122 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
17123 for VMAT_ELEMENTWISE.
17124
17125 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
17126
17127 * internal-fn.h (lookup_internal_fn): Declare
17128 * internal-fn.c (lookup_internal_fn): New function.
17129 * gimple.c (gimple_build_call_from_tree): Handle calls to
17130 internal functions.
17131 * gimple-pretty-print.c (dump_gimple_call): Print "." before
17132 internal function names.
17133 * tree-pretty-print.c (dump_generic_node): Likewise.
17134 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
17135
17136 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
17137
17138 * gimple-fold.h (gimple_build): Make the function forms take
17139 combined_fn rather than built_in_function.
17140 (gimple_simplify): Likewise.
17141 * gimple-match-head.c (gimple_simplify): Likewise.
17142 * gimple-fold.c (gimple_build): Likewise.
17143 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
17144 rather than gimple_build_call_internal.
17145 (get_initial_defs_for_reduction): Likewise.
17146 (vect_create_epilog_for_reduction): Likewise.
17147 (vectorizable_live_operation): Likewise.
17148
17149 2018-05-17 Martin Liska <mliska@suse.cz>
17150
17151 * gimple-ssa-sprintf.c (format_directive): Do not use
17152 space in between 'G_' and '('.
17153
17154 2018-05-17 Jakub Jelinek <jakub@redhat.com>
17155
17156 PR target/85323
17157 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
17158 even if the mask is not all ones.
17159
17160 PR target/85323
17161 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
17162 vector.
17163 (ix86_gimple_fold_builtin): Likewise.
17164
17165 PR target/85323
17166 * config/i386/i386.c: Include tree-vector-builder.h.
17167 (ix86_vector_shift_count): New function.
17168 (ix86_fold_builtin): Fold shift builtins by scalar count.
17169 (ix86_gimple_fold_builtin): Likewise.
17170
17171 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
17172 _mm512_setzero): New intrinsics.
17173
17174 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
17175 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17176
17177 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
17178 code generation for cases where splatting a value is not useful.
17179 * simplify-rtx.c (simplify_ternary_operation): Simplify
17180 vec_merge across a vec_duplicate and a paradoxical subreg forming
17181 a vector mode to a vec_concat.
17182
17183 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
17184
17185 * config.gcc: Support "goldmont-plus".
17186 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17187 "goldmont-plus".
17188 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17189 PROCESSOR_GOLDMONT_PLUS.
17190 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
17191 (processor_target_table): Add "goldmont-plus".
17192 (PTA_GOLDMONT_PLUS): Define.
17193 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
17194 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
17195 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
17196 (fold_builtin_cpu): Add "goldmont-plus".
17197 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
17198 (ix86_option_override_internal): Add "goldmont-plus".
17199 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
17200 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
17201 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
17202 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
17203
17204 2018-05-17 Richard Biener <rguenther@suse.de>
17205
17206 PR tree-optimization/85757
17207 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
17208 remove defs that only feed that PHI from further processing.
17209
17210 2018-05-16 Jim Wilson <jimw@sifive.com>
17211
17212 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
17213 asterisk to name.
17214 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
17215
17216 2018-05-16 Mark Wielaard <mark@klomp.org>
17217
17218 * dwarf2out.c (count_index_strings): New function.
17219 (output_indirect_strings): Call count_index_strings and generate
17220 header for dwarf_version >= 5.
17221
17222 2018-05-16 Mark Wielaard <mark@klomp.org>
17223
17224 * dwarf2out.c (dwarf_FORM): New function.
17225 (set_indirect_string): Use dwarf_FORM.
17226 (reset_indirect_string): Likewise.
17227 (size_of_die): Likewise.
17228 (value_format): Likewise.
17229 (output_die): Likewise.
17230 (add_skeleton_AT_string): Likewise.
17231 (output_macinfo_op): Likewise.
17232 (index_string): Likewise.
17233 (output_index_string_offset): Likewise.
17234 (output_index_string): Likewise.
17235 (count_index_strings): Likewise.
17236
17237 2018-05-16 Carl Love <cel@us.ibm.com>
17238
17239 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17240 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
17241
17242 2018-05-16 Martin Jambor <mjambor@suse.cz>
17243
17244 * ipa-prop.c (ipa_free_all_edge_args): Remove.
17245 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
17246
17247 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
17248
17249 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
17250 (fnma<mode>4): Likewise.
17251 (fms<mode>4): Likewise.
17252 (fnms<mode>4): Likewise.
17253 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
17254 (aarch64_fnma<mode>4): Likewise.
17255 (aarch64_fms<mode>4): Likewise.
17256 (aarch64_fnms<mode>4): Likewise.
17257 (aarch64_fnmadd<mode>4): Likewise.
17258
17259 2018-05-16 Jason Merrill <jason@redhat.com>
17260
17261 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
17262
17263 2018-05-16 Richard Biener <rguenther@suse.de>
17264
17265 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
17266 (dump_stmt_cost): Declare.
17267 (add_stmt_cost): Dump cost we add.
17268 (add_stmt_costs): New function.
17269 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
17270 No longer exported.
17271 (vect_analyze_stmt): Adjust prototype.
17272 (vectorizable_condition): Likewise.
17273 (vectorizable_live_operation): Likewise.
17274 (vectorizable_reduction): Likewise.
17275 (vectorizable_induction): Likewise.
17276 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
17277 cost vector to pass to vectorizable_ and record afterwards.
17278 (vect_model_reduction_cost): Take cost vector argument and adjust.
17279 (vect_model_induction_cost): Likewise.
17280 (vectorizable_reduction): Likewise.
17281 (vectorizable_induction): Likewise.
17282 (vectorizable_live_operation): Likewise.
17283 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
17284 SLP_TREE_NUMBER_OF_VEC_STMTS.
17285 (vect_analyze_slp_cost_1): Remove.
17286 (vect_analyze_slp_cost): Likewise.
17287 (vect_slp_analyze_node_operations): Take visited args and
17288 a target cost vector. Avoid processing already visited stmt sets.
17289 (vect_slp_analyze_operations): Use a local cost vector to gather
17290 costs and register those of non-discarded instances.
17291 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
17292 (vect_schedule_slp_instance): Remove copying of
17293 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
17294 zero.
17295 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
17296 adding cost. Record cost entry location.
17297 (vect_prologue_cost_for_slp_op): Function to compute cost of
17298 a constant or invariant generated for SLP vect in the prologue,
17299 split out from vect_analyze_slp_cost_1.
17300 (vect_model_simple_cost): Make static. Adjust for SLP costing.
17301 (vect_model_promotion_demotion_cost): Likewise.
17302 (vect_model_store_cost): Likewise, make static.
17303 (vect_model_load_cost): Likewise.
17304 (vectorizable_bswap): Add cost vector arg and adjust.
17305 (vectorizable_call): Likewise.
17306 (vectorizable_simd_clone_call): Likewise.
17307 (vectorizable_conversion): Likewise.
17308 (vectorizable_assignment): Likewise.
17309 (vectorizable_shift): Likewise.
17310 (vectorizable_operation): Likewise.
17311 (vectorizable_store): Likewise.
17312 (vectorizable_load): Likewise.
17313 (vectorizable_condition): Likewise.
17314 (vectorizable_comparison): Likewise.
17315 (can_vectorize_live_stmts): Likewise.
17316 (vect_analyze_stmt): Likewise.
17317 (vect_transform_stmt): Adjust calls to vectorizable_*.
17318 * tree-vectorizer.c: Include gimple-pretty-print.h.
17319 (dump_stmt_cost): New function.
17320
17321 2018-05-16 Richard Biener <rguenther@suse.de>
17322
17323 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
17324 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
17325 * tree-ssa-dse.c: Include tree-ssa-loop.h.
17326 (check_name): New callback.
17327 (dse_classify_store): Track cycles via a visited bitmap of PHI
17328 defs and simplify handling of in-loop and across loop dead stores
17329 and properly fail for loop-variant refs. Handle byte-tracking with
17330 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
17331 limiting the walk.
17332
17333 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
17334
17335 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
17336 (vect_get_mask_type_for_stmt): Likewise.
17337 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
17338 split out from...
17339 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
17340 to determine the statement's vector type and the vector type that
17341 should be used for calculating nunits. Deal with cases in which
17342 the type has to be deferred.
17343 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
17344 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
17345 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
17346 (vect_determine_vf_for_stmt): New functions, split out from...
17347 (vect_determine_vectorization_factor): ...here.
17348 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
17349 (vect_get_mask_type_for_stmt): New functions, split out from
17350 vect_determine_vectorization_factor.
17351
17352 2018-05-16 Richard Biener <rguenther@suse.de>
17353
17354 * tree-cfg.c (verify_gimple_assign_ternary): Properly
17355 verify the [VEC_]COND_EXPR embedded comparison.
17356
17357 2018-05-15 Martin Sebor <msebor@redhat.com>
17358
17359 PR tree-optimization/85753
17360 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
17361 RECORD_TYPE in addition to ARRAY_TYPE.
17362
17363 2018-05-15 Martin Sebor <msebor@redhat.com>
17364
17365 PR middle-end/85643
17366 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
17367
17368 2018-05-15 Richard Biener <rguenther@suse.de>
17369
17370 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
17371 add by_clobber_p one. Change algorithm to collect all defs
17372 representing uses we need to walk and try reducing them to
17373 a single one before failing.
17374 (dse_dom_walker::dse_optimize_stmt): Adjust.
17375
17376 2018-05-13 Mark Wielaard <mark@klomp.org>
17377
17378 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
17379 (size_of_loc_descr): Likewise.
17380 (output_loc_operands): Likewise.
17381 (output_loc_operands_raw): Likewise.
17382 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
17383 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
17384 (hash_loc_operands): Likewise.
17385 (compare_loc_operands): Likewise.
17386
17387 2018-05-14 Mark Wielaard <mark@klomp.org>
17388
17389 * dwarf2out.c (count_index_addrs): New function.
17390 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
17391
17392 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17393
17394 PR tree-optimization/83648
17395 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
17396 return value as malloc candidate.
17397
17398 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17399
17400 PR ipa/85734
17401 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
17402 param as true in call to suggest_attribute.
17403
17404 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
17405
17406 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
17407 -mreadonly-in-sdata.
17408
17409 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17410
17411 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
17412 New pattern.
17413 (aarch64_crypto_aesd_fused): Likewise.
17414
17415 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
17416
17417 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
17418 (movsi_aarch64): Likewise.
17419 (load_pairsi): Likewise.
17420 (load_pairdi): Likewise.
17421 (store_pairsi): Likewise.
17422 (store_pairdi): Likewise.
17423 (load_pairsf): Likewise.
17424 (load_pairdf): Likewise.
17425 (store_pairsf): Likewise.
17426 (store_pairdf): Likewise.
17427 (zero_extend): Likewise.
17428 (trunc): Swap alternatives.
17429 (fcvt_target): Add '?' to prefer w over r.
17430
17431 2018-05-14 Jakub Jelinek <jakub@redhat.com>
17432
17433 PR target/85756
17434 * config/i386/i386.md: Disallow non-commutative arithmetics in
17435 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
17436 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
17437 in the peephole2 before it.
17438
17439 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
17440
17441 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
17442 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
17443 (ix86_handle_option): Handle -mcldemote.
17444 * config.gcc: New header.
17445 * config/i386/cldemoteintrin.h: New file.
17446 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
17447 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17448 -mcldemote.
17449 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17450 OPTION_MASK_ISA_CLDEMOTE.
17451 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
17452 (ix86_valid_target_attribute_inner_p): Ditto.
17453 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
17454 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
17455 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
17456 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
17457 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
17458 (cldemote): New.
17459 * config/i386/i386.opt: Add -mcldemote.
17460 * config/i386/x86intrin.h: New header.
17461 * doc/invoke.texi: Add -mcldemote.
17462
17463 2018-05-14 Richard Biener <rguenther@suse.de>
17464
17465 * doc/match-and-simplify.texi: Adjust :s documentation.
17466
17467 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
17468
17469 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
17470 intended memcpy size.
17471 (REORDER_45): Likewise.
17472
17473 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
17474
17475 * sort.cc: New file.
17476 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
17477 * vec.c (qsort_chk): Use gcc_qsort.
17478 * Makefile.in (OBJS-libcommon): Add sort.o.
17479 (build/sort.o): New target. Use it...
17480 (BUILD_RTL): ... here, and...
17481 (build/gencfn-macros): ... here, and...
17482 (build/genmatch): ... here.
17483
17484 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17485 Chung-Ju Wu <jasonwucj@gmail.com>
17486
17487 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
17488 * config/nds32/nds32-graywolf.md: New file.
17489 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
17490 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
17491 pipeline.
17492 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
17493 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
17494 * config/nds32/nds32.md (pipeline_model): Add graywolf.
17495 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
17496 * config/nds32/pipelines.md: Include n15 settings.
17497
17498 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17499 Chung-Ju Wu <jasonwucj@gmail.com>
17500
17501 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
17502 * config/nds32/nds32-n13.md: New file.
17503 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
17504 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
17505 pipeline.
17506 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
17507 * config/nds32/nds32.md (pipeline_model): Add n13.
17508 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
17509 * config/nds32/pipelines.md: Include n13 settings.
17510
17511 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17512 Chung-Ju Wu <jasonwucj@gmail.com>
17513
17514 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
17515 * config/nds32/nds32-n10.md: New file.
17516 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
17517 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
17518 pipeline.
17519 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
17520 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
17521 * config/nds32/nds32.md (pipeline_model): Add n10.
17522 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
17523 * config/nds32/pipelines.md: Include n10 settings.
17524
17525 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
17526 Kito Cheng <kito.cheng@gmail.com>
17527 Chung-Ju Wu <jasonwucj@gmail.com>
17528
17529 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
17530 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
17531 Add enum values for DSP extension instructions.
17532 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
17533 New constraints.
17534 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
17535 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
17536 New code iterators.
17537 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
17538 * config/nds32/nds32-dspext.md: New file for DSP implementation.
17539 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
17540 * config/nds32/nds32-intrinsic.md: Likewise.
17541 * config/nds32/nds32_intrinsic.h: Likewise.
17542 * config/nds32/nds32-md-auxiliary.c: Likewise.
17543 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
17544 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
17545 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
17546 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
17547 * config/nds32/nds32-protos.h: New declarations for DSP extension.
17548 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
17549 TYPE_DMAC in switch statement.
17550 * config/nds32/nds32.c: New checking and implementation for DSP
17551 extension instructions.
17552 * config/nds32/nds32.h: Likewise.
17553 * config/nds32/nds32.md: Likewise.
17554 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
17555 * config/nds32/predicates.md: Implement new predicates for DSP
17556 extension.
17557
17558 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
17559
17560 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
17561 Reformat alternatives and attributes so it is easier to identify
17562 which constraints/attributes go with which instruction.
17563 (mov<mode>_hardfloat32, FMOVE64): Likewise.
17564 (mov<mode>_softfloat32, FMOVE64): Likewise.
17565 (mov<mode>_hardfloat64, FMOVE64): Likewise.
17566 (mov<mode>_softfloat64, FMOVE64): Likewise.
17567
17568 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
17569
17570 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17571 subsection.
17572 (Basic PowerPC Built-in Functions): The new name of the
17573 subsection previously known as "PowerPC Built-in Functions".
17574 (Basic PowerPC Built-in Functions Available on all Configurations):
17575 New subsubsection.
17576 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
17577 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
17578 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
17579 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
17580
17581 2018-05-11 Martin Jambor <mjambor@suse.cz>
17582
17583 PR ipa/85655
17584 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
17585 single const.
17586
17587 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17588
17589 PR target/85733
17590 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
17591
17592 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
17593
17594 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
17595 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
17596 (ix86_handle_option): Handle -mwaitpkg.
17597 * config.gcc: New header.
17598 * config/i386/cpuid.h (bit_WAITPKG): New bit.
17599 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
17600 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
17601 function type.
17602 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17603 OPTION_MASK_ISA_WAITPKG.
17604 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
17605 (ix86_option_override_internal): Add PTA_WAITPKG.
17606 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
17607 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
17608 IX86_BUILTIN_TPAUSE.
17609 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
17610 __builtin_ia32_umwait and __builtin_ia32_tpause.
17611 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
17612 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
17613 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
17614 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
17615 UNSPECV_TPAUSE): New.
17616 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
17617 * config/i386/i386.opt: Add -mwaitpkg.
17618 * config/i386/waitpkgintrin.h: New file.
17619 * config/i386/x86intrin.h: New header.
17620 * doc/invoke.texi: Add -mwaitpkg.
17621
17622 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17623
17624 PR target/85606
17625 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
17626 equivalent.
17627 (cortex-m0): Use armv6s-m isa.
17628 (cortex-m0plus): Likewise.
17629 (cortex-m1): Likewise.
17630 (cortex-m0.small-multiply): Likewise.
17631 (cortex-m0plus.small-multiply): Likewise.
17632 (cortex-m1.small-multiply): Likewise.
17633
17634 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
17635 Jakub Jelinek <jakub@redhat.com>
17636
17637 PR tree-optimization/85692
17638 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
17639 source permute as well.
17640
17641 2018-05-11 Martin Liska <mliska@suse.cz>
17642
17643 PR sanitizer/85556
17644 * doc/extend.texi: Document LLVM style format for no_sanitize
17645 attribute.
17646
17647 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
17648
17649 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
17650 mode_supports_vsx_dform_quad to mode_supports_dq_form.
17651 (mode_supports_vsx_dform_quad): Likewise.
17652 (mode_supports_vmx_dform): Move these functions to be next to the
17653 other mode_supports functions.
17654 (mode_supports_dq_form): Likewise.
17655 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
17656 mode_supports_dq_form.
17657 (reg_offset_addressing_ok_p): Likewise.
17658 (offsettable_ok_by_alignment): Likewise.
17659 (rs6000_legitimate_offset_address_p): Likewise.
17660 (legitimate_lo_sum_address_p): Likewise.
17661 (rs6000_legitimize_address): Likewise.
17662 (rs6000_legitimize_reload_address): Likewise.
17663 (rs6000_secondary_reload_inner): Likewise.
17664 (rs6000_preferred_reload_class): Likewise.
17665 (rs6000_output_move_128bit): Likewise.
17666
17667 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17668
17669 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
17670 Generate SImode target register for null target.
17671 <case IX86_BUILTIN_XGETBV>: Ditto.
17672 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
17673 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
17674
17675 2018-05-10 Carl Love <cel@us.ibm.com>
17676
17677 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17678 dcbtt and dcbtstt if operands[2] is 0.
17679
17680 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17681
17682 PR target/85693
17683 * config/i386/sse.md (usadv64qi): New expander.
17684
17685 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
17686
17687 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
17688 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
17689 -maltivec=be support.
17690 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
17691 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
17692 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
17693 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
17694 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
17695 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
17696 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
17697 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
17698 altivec_vsumsws): Adjust.
17699 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
17700 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
17701 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
17702 support.
17703 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
17704 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
17705 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
17706 (altivec_lve<VI_char>x): Delete expand.
17707 (*altivec_lve<VI_char>x_internal): Rename to...
17708 (altivec_lve<VI_char>x): ... this.
17709 (altivec_lvxl_<mode>): Delete expand.
17710 (*altivec_lvxl_<mode>_internal): Rename to ...
17711 (altivec_lvxl_<mode>): ... this.
17712 (altivec_stvxl_<mode>): Delete expand.
17713 (*altivec_stvxl_<mode>_internal): Rename to ...
17714 (altivec_stvxl_<mode>): ... this.
17715 (altivec_stve<VI_char>x): Delete expand.
17716 (*altivec_stve<VI_char>x_internal): Rename to ...
17717 (altivec_stve<VI_char>x): ... this.
17718 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
17719 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
17720 reduc_plus_scal_<mode>): Adjust.
17721 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
17722 comment.
17723 (rs6000_cpu_cpp_builtins): Adjust.
17724 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
17725 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
17726 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
17727 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
17728 -maltivec=be support.
17729 (rs6000_split_vec_extract_var): Adjust.
17730 (rs6000_split_v4si_init): Adjust.
17731 (swap_selector_for_mode): Delete.
17732 (altivec_expand_lvx_be, altivec_expand_stvx_be,
17733 altivec_expand_stvex_be): Delete.
17734 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
17735 -maltivec=be support.
17736 (rs6000_gimple_fold_builtin): Ditto.
17737 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
17738 Adjust.
17739 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
17740 (TARGET_DIRECT_MOVE_64BIT): Adjust.
17741 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
17742 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
17743 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
17744 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
17745 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
17746 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
17747 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
17748 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
17749 anonymous split): Adjust.
17750 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
17751 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
17752
17753 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
17754
17755 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
17756 when --with-gxx-include-dir is also specified.
17757 * configure: Regenerate.
17758
17759 2018-05-09 Jim Wilson <jimw@sifive.com>
17760
17761 PR target/84797
17762 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
17763 * config/riscv/t-withmultilib: New.
17764 * config/riscv/withmultilib.h: New.
17765 * doc/install.texi: Document RISC-V --with-multilib-list support.
17766
17767 2018-05-09 Richard Biener <rguenther@suse.de>
17768
17769 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
17770 vector.
17771 (vect_bb_vectorization_profitable_p): Adjust. Compute
17772 actual scalar cost using the cost vector and the add_stmt_cost
17773 machinery.
17774
17775 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17776
17777 PR rtl-optimization/85645
17778 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
17779 in the REG_CFA_REGISTER note for LR, don't leave it empty.
17780
17781 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17782
17783 PR rtl-optimization/85645
17784 * shrink-wrap.c (spread_components): Return a boolean saying if
17785 anything was changed.
17786 (try_shrink_wrapping_separate): Iterate spread_components until
17787 nothing changes anymore.
17788
17789 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17790
17791 PR rtl-optimization/85645
17792 * regrename.c (build_def_use): Also kill the chains that include the
17793 destination of a REG_CFA_REGISTER note.
17794
17795 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17796
17797 PR rtl-optimization/85645
17798 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
17799 insn that has a REG_CFA_REGISTER note.
17800
17801 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
17802
17803 * cfgexpand.c (expand_clobber): New function.
17804 (expand_gimple_stmt_1): Use it.
17805 * tree-vect-stmts.c (vect_clobber_variable): New function,
17806 split out from...
17807 (vectorizable_simd_clone_call): ...here.
17808 (vectorizable_store): Emit a clobber either side of an
17809 IFN_STORE_LANES sequence.
17810 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
17811
17812 2018-05-09 Tom de Vries <tom@codesourcery.com>
17813
17814 PR target/85626
17815 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
17816 (define_insn "trap_if_false"): Add exit after trap.
17817
17818 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
17819
17820 PR rtl-optimization/85638
17821 * bb-reorder.c: Include common/common-target.h.
17822 (create_forwarder_block): New function extracted from...
17823 (fix_up_crossing_landing_pad): ...here. Rename into...
17824 (dw2_fix_up_crossing_landing_pad): ...this.
17825 (sjlj_fix_up_crossing_landing_pad): New function.
17826 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
17827 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
17828 from both partitions and exit the loop after one iteration.
17829
17830 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17831
17832 Revert:
17833 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17834 subsection.
17835 (Basic PowerPC Built-in Functions): The new name of the
17836 subsection previously known as "PowerPC Built-in Functions".
17837 (Basic PowerPC Built-in Functions Available on all Configurations):
17838 New subsubsection.
17839 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17840 subsubsection.
17841 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17842 subsubsection.
17843 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17844 subsubsection.
17845 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17846 subsubsection.
17847
17848 2018-05-08 Jim Wilson <jimw@sifive.com>
17849
17850 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
17851 (LD_EMUL_SUFFIX): New.
17852 (LINK_SPEC): Use it.
17853
17854 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17855
17856 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17857 subsection.
17858 (Basic PowerPC Built-in Functions): The new name of the
17859 subsection previously known as "PowerPC Built-in Functions".
17860 (Basic PowerPC Built-in Functions Available on all Configurations):
17861 New subsubsection.
17862 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17863 subsubsection.
17864 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17865 subsubsection.
17866 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17867 subsubsection.
17868 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17869 subsubsection.
17870
17871 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17872
17873 PR target/85683
17874 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
17875 after cmpelim optimization.
17876
17877 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
17878
17879 * config.gcc: Support "goldmont".
17880 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
17881 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17882 PROCESSOR_GOLDMONT.
17883 * config/i386/i386.c (m_GOLDMONT): Define.
17884 (processor_target_table): Add "goldmont".
17885 (PTA_GOLDMONT): Define.
17886 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
17887 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
17888 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
17889 (fold_builtin_cpu): Add "goldmont".
17890 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
17891 (ix86_option_override_internal): Add "goldmont".
17892 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
17893 (processor_type): Add PROCESSOR_GOLDMONT.
17894 * config/i386/i386.md: Add CPU "glm".
17895 * config/i386/glm.md: New file.
17896 * config/i386/x86-tune.def: Add m_GOLDMONT.
17897 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
17898
17899 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17900
17901 PR target/85572
17902 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
17903 E_V4DImode.
17904 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
17905 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
17906 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
17907
17908 PR target/85317
17909 * config/i386/i386.c (ix86_fold_builtin): Handle
17910 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
17911
17912 PR target/85480
17913 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
17914 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
17915
17916 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
17917
17918 PR target/85658
17919 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
17920 (check_arch): Likewise.
17921 (check_fpu): Return the result rather than printing it.
17922 (end arch): Fix operator precedence.
17923 (end cpu): Likewise.
17924 (END): Print the result from check_fpu.
17925
17926 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17927 Alan Hayward <alan.hayward@arm.com>
17928 David Sherwood <david.sherwood@arm.com>
17929
17930 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
17931 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
17932 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
17933 (*fcmuo<mode>_and): New patterns.
17934
17935 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17936
17937 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
17938 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
17939 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
17940 (cmp_op, sve_imm_con): New code attributes.
17941 (SVE_COND_INT_CMP, imm_con): Delete.
17942 (cmp_op): Remove above unspecs from int attribute.
17943 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
17944 to...
17945 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
17946 comparison-specific unspecs.
17947 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
17948 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
17949 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
17950 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
17951 (*vec_fcm<cmp_op><mode>): Rename to...
17952 (*fcm<cmp_op><mode>): ...this and adjust likewise.
17953 (*vec_fcmuo<mode>): Rename to...
17954 (*fcmuo<mode>): ...this and adjust likewise.
17955 (*pred_fcm<cmp_op><mode>): New pattern.
17956 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
17957 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
17958 functions.
17959 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
17960 and UNORDERED.
17961 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
17962 (aarch64_emit_sve_predicated_cond): New function.
17963 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
17964 (aarch64_emit_unspec_cond_or): Replace with...
17965 (aarch64_emit_sve_or_conds): ...this new function. Use
17966 aarch64_emit_sve_ptrue_op for the individual comparisons and
17967 aarch64_emit_binop to OR them together.
17968 (aarch64_emit_inverted_unspec_cond): Replace with...
17969 (aarch64_emit_sve_inverted_cond): ...this new function. Use
17970 aarch64_emit_sve_ptrue_op for the comparison and
17971 aarch64_emit_unop to invert the result.
17972 (aarch64_expand_sve_vec_cmp_float): Update after the above
17973 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
17974
17975 2018-05-07 Nathan Sidwell <nathan@acm.org>
17976
17977 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
17978 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
17979 (Backwards Compatibility): Likewise.
17980
17981 2018-05-07 Luis Machado <luis.machado@linaro.org>
17982
17983 PR bootstrap/85681
17984 Revert:
17985 2018-05-07 Luis Machado <luis.machado@linaro.org>
17986
17987 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17988 <prefetch_dynamic_strides>: New const bool field.
17989 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17990 prefetch_dynamic_strides.
17991 (exynosm1_prefetch_tune): Likewise.
17992 (thunderxt88_prefetch_tune): Likewise.
17993 (thunderx_prefetch_tune): Likewise.
17994 (thunderx2t99_prefetch_tune): Likewise.
17995 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
17996 to false.
17997 (aarch64_override_options_internal): Update to set
17998 PARAM_PREFETCH_DYNAMIC_STRIDES.
17999 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
18000 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
18001 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
18002 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
18003 prefetch-dynamic-strides setting.
18004
18005 2018-05-07 Luis Machado <luis.machado@linaro.org>
18006
18007 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
18008 <minimum_stride>: New const int field.
18009 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
18010 minimum_stride field.
18011 (exynosm1_prefetch_tune): Likewise.
18012 (thunderxt88_prefetch_tune): Likewise.
18013 (thunderx_prefetch_tune): Likewise.
18014 (thunderx2t99_prefetch_tune): Likewise.
18015 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
18016 (aarch64_override_options_internal): Update to set
18017 PARAM_PREFETCH_MINIMUM_STRIDE.
18018 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
18019 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
18020 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
18021 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
18022 stride is constant and is below the minimum stride threshold.
18023
18024 2018-05-07 Luis Machado <luis.machado@linaro.org>
18025
18026 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
18027 to 512.
18028
18029 2018-05-07 Luis Machado <luis.machado@linaro.org>
18030
18031 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
18032 <prefetch_dynamic_strides>: New const bool field.
18033 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
18034 prefetch_dynamic_strides.
18035 (exynosm1_prefetch_tune): Likewise.
18036 (thunderxt88_prefetch_tune): Likewise.
18037 (thunderx_prefetch_tune): Likewise.
18038 (thunderx2t99_prefetch_tune): Likewise.
18039 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
18040 to false.
18041 (aarch64_override_options_internal): Update to set
18042 PARAM_PREFETCH_DYNAMIC_STRIDES.
18043 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
18044 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
18045 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
18046 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
18047 prefetch-dynamic-strides setting.
18048
18049 2018-05-07 Luis Machado <luis.machado@linaro.org>
18050
18051 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
18052 <minimum_stride>: New const int field.
18053 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
18054 minimum_stride field.
18055 (exynosm1_prefetch_tune): Likewise.
18056 (thunderxt88_prefetch_tune): Likewise.
18057 (thunderx_prefetch_tune): Likewise.
18058 (thunderx2t99_prefetch_tune): Likewise.
18059 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
18060 (aarch64_override_options_internal): Update to set
18061 PARAM_PREFETCH_MINIMUM_STRIDE.
18062 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
18063 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
18064 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
18065 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
18066 stride is constant and is below the minimum stride threshold.
18067
18068 2018-05-06 Jakub Jelinek <jakub@redhat.com>
18069
18070 PR c++/85659
18071 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
18072 the type is addressable. Don't force op into register if it has
18073 BLKmode.
18074
18075 2018-05-05 Roland McGrath <mcgrathr@google.com>
18076
18077 PR other/77609
18078 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
18079 any section for which we don't know a specific type it should have,
18080 regardless of name. Previously this was done only for the exact
18081 names ".init_array", ".fini_array", and ".preinit_array".
18082 (default_elf_asm_named_section): Add comment about
18083 relationship with default_section_type_flags and SECTION_NOTYPE.
18084 (get_section): Don't consider it a type conflict if one side has
18085 SECTION_NOTYPE and the other doesn't, as long as neither has the
18086 SECTION_BSS et al used in the default_section_type_flags logic.
18087
18088 2018-05-05 Tom de Vries <tom@codesourcery.com>
18089
18090 PR target/85653
18091 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
18092 (workaround_barsyncs): New function.
18093 (nvptx_reorg): Use workaround_barsyncs.
18094 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
18095 (define_expand "nvptx_membar_cta"): New define_expand.
18096 (define_insn "*nvptx_membar_cta"): New insn.
18097
18098 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
18099
18100 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
18101 To improve optimization opportunities.
18102 * builtin-types.def: The new needed builtin types for the above.
18103
18104 2018-05-04 Richard Biener <rguenther@suse.de>
18105
18106 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
18107 * gimple-ssa-store-merging.c
18108 (imm_store_chain_info::output_merged_store): Remove redundant create,
18109 release split_store vector contents on failure.
18110 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
18111 scalar stmt vector on cache hit.
18112
18113 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
18114
18115 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
18116 Xilinx FP support.
18117 * config.gcc (powerpc-xilinx-eabi*): Remove.
18118 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
18119 support.
18120 (fusion_addis_mem_combo_load): Ditto.
18121 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
18122 FP support.
18123 (rs6000_cpu_cpp_builtins): Ditto.
18124 * config/rs6000/rs6000-linux.c
18125 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
18126 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
18127 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
18128 support.
18129 (rs6000_setup_reg_addr_masks): Ditto.
18130 (rs6000_init_hard_regno_mode_ok): Ditto.
18131 (rs6000_option_override_internal): Ditto.
18132 (legitimate_lo_sum_address_p): Ditto.
18133 (rs6000_legitimize_address): Ditto.
18134 (rs6000_legitimize_reload_address): Ditto.
18135 (rs6000_legitimate_address_p): Ditto.
18136 (abi_v4_pass_in_fpr): Ditto.
18137 (setup_incoming_varargs): Ditto.
18138 (rs6000_gimplify_va_arg): Ditto.
18139 (rs6000_split_multireg_move): Ditto.
18140 (rs6000_savres_strategy): Ditto.
18141 (rs6000_emit_prologue_components): Ditto.
18142 (rs6000_emit_epilogue_components): Ditto.
18143 (rs6000_emit_prologue): Ditto.
18144 (rs6000_emit_epilogue): Ditto.
18145 (rs6000_elf_file_end): Ditto.
18146 (rs6000_function_value): Ditto.
18147 (rs6000_libcall_value): Ditto.
18148 * config/rs6000/rs6000.h: Ditto.
18149 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
18150 (TARGET_MINMAX): ... this. New.
18151 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
18152 * config/rs6000/rs6000.md: Remove Xilinx FP support.
18153 (*movsi_internal1_single): Delete.
18154 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
18155 mfpu=, mxilinx-fpu): Delete.
18156 * config/rs6000/singlefp.h: Delete.
18157 * config/rs6000/sysv4.h: Remove Xilinx FP support.
18158 * config/rs6000/t-rs6000: Ditto.
18159 * config/rs6000/t-xilinx: Delete.
18160 * config/rs6000/titan.md: Adjust for fp_type removal.
18161 * config/rs6000/vsx.md: Remove Xilinx FP support.
18162 (VStype_simple): Delete.
18163 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
18164 * config/rs6000/xfpu.h: Delete.
18165 * config/rs6000/xfpu.md: Delete.
18166 * config/rs6000/xilinx.h: Delete.
18167 * config/rs6000/xilinx.opt: Delete.
18168 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
18169 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
18170
18171 2018-05-04 Tom de Vries <tom@codesourcery.com>
18172
18173 PR libgomp/85639
18174 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
18175 if ignore == 0.
18176
18177 2018-05-04 Richard Biener <rguenther@suse.de>
18178
18179 PR middle-end/85627
18180 * tree-complex.c (update_complex_assignment): We are always in SSA form.
18181 (expand_complex_div_wide): Likewise.
18182 (expand_complex_operations_1): Likewise.
18183 (expand_complex_libcall): Preserve EH info of the original stmt.
18184 (tree_lower_complex): Handle removed blocks.
18185 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
18186 on complex multiplication and division libcall builtins.
18187
18188 2018-05-04 Richard Biener <rguenther@suse.de>
18189
18190 PR middle-end/85574
18191 * fold-const.c (negate_expr_p): Restrict negation of operand
18192 zero of a division to when we know that can happen without
18193 overflow.
18194 (fold_negate_expr_1): Likewise.
18195
18196 2018-05-04 Jakub Jelinek <jakub@redhat.com>
18197
18198 PR libstdc++/85466
18199 * real.h (real_nextafter): Declare.
18200 * real.c (real_nextafter): New function.
18201 * fold-const-call.c (fold_const_nextafter): New function.
18202 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
18203 CASE_CFN_NEXTTOWARD.
18204 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
18205 even when arg1_mode is different from arg0_mode.
18206
18207 2018-05-03 Nathan Sidwell <nathan@acm.org>
18208
18209 * doc/extend.texi (Deprecated Features): Remove
18210 -ffriend-injection.
18211 (Backwards Compatibility): Likewise.
18212 * doc/invoke.texi (C++ Language Options): Likewise.
18213 (C++ Dialect Options): Likewise.
18214
18215 2018-05-03 Jakub Jelinek <jakub@redhat.com>
18216
18217 PR target/85530
18218 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
18219 _mm512_mask_mullox_epi64): New intrinsics.
18220
18221 2018-05-03 Tom de Vries <tom@codesourcery.com>
18222
18223 PR testsuite/85106
18224 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18225 dump files): Add offload-tree.
18226
18227 2018-05-03 Richard Biener <rguenther@suse.de>
18228
18229 PR tree-optimization/85615
18230 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
18231 to loops not nested in BBs loop father to avoid creating multi-entry
18232 loops.
18233
18234 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18235
18236 PR tree-optimization/70291
18237 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
18238 arguments. Change return type to tree. Emit libcall as a new
18239 statement rather than replacing existing one when inplace_p is true.
18240 (expand_complex_multiplication_components): New function.
18241 (expand_complex_multiplication): Expand floating-point complex
18242 multiplication using the above.
18243 (expand_complex_division): Rename inner_type parameter to type.
18244 Update expand_complex_libcall call-site.
18245 (expand_complex_operations_1): Update expand_complex_multiplication
18246 and expand_complex_division call-sites.
18247
18248 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18249
18250 PR target/85582
18251 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18252 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18253 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
18254 the highest significant bit of the shift count mask is clear. In
18255 check whether and[sq]i3 is needed verify that all significant bits
18256 of the shift count other than the highest are set.
18257
18258 2018-05-02 Tom de Vries <tom@codesourcery.com>
18259
18260 PR libgomp/82428
18261 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
18262 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
18263 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
18264 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
18265 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
18266 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
18267 __builtin_goacc_parlevel_size.
18268
18269 2018-05-02 Richard Biener <rguenther@suse.de>
18270
18271 PR tree-optimization/85597
18272 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
18273 do not use split vect_get_vec_defs call but call vect_get_slp_defs
18274 directly.
18275
18276 2018-05-02 Tom de Vries <tom@codesourcery.com>
18277
18278 PR testsuite/85106
18279 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18280 dump files): Add ltrans-tree.
18281
18282 2018-05-02 Tom de Vries <tom@codesourcery.com>
18283
18284 PR testsuite/85106
18285 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18286 dump files): Add wpa-ipa.
18287
18288 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
18289
18290 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
18291 powerpc*-*-linux*paired* target.
18292 * config/rs6000/750cl.h: Delete.
18293 * config/rs6000/paired.h: Delete.
18294 * config/rs6000/paired.md: Delete.
18295 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
18296 float support.
18297 * config/rs6000/rs6000-builtin.def: Remove paired float support.
18298 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
18299 comment. Remove paired float support.
18300 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
18301 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
18302 VECTOR_PAIRED.
18303 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
18304 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
18305 declarations.
18306 * config/rs6000/rs6000.c: Remove paired float support.
18307 (paired_expand_vector_init, paired_expand_vector_move,
18308 paired_emit_vector_compare, paired_emit_vector_cond_expr,
18309 (paired_expand_lv_builtin, paired_expand_stv_builtin,
18310 paired_expand_builtin, paired_expand_predicate_builtin,
18311 paired_init_builtins): Delete.
18312 * config/rs6000/rs6000.h: Remove paired float support.
18313 * config/rs6000/rs6000.md: Remove paired float support.
18314 (move_from_CR_ov_bit): Delete.
18315 * config/rs6000/rs6000.opt (mpaired): Delete.
18316 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
18317 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
18318
18319 2018-05-02 Richard Biener <rguenther@suse.de>
18320
18321 PR middle-end/85567
18322 * gimplify.c (gimplify_save_expr): When in SSA form allow
18323 SAVE_EXPRs to compute to SSA vars.
18324
18325 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18326
18327 PR target/85582
18328 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18329 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18330 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
18331 clobber operands[2], instead use a new pseudo. Formatting fixes.
18332
18333 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
18334
18335 PR tree-optimization/85586
18336 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
18337 exit early for statements in the same group if the accesses are
18338 not strided.
18339
18340 2018-05-02 Tom de Vries <tom@codesourcery.com>
18341
18342 PR lto/85451
18343 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
18344 error message.
18345
18346 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
18347
18348 PR tree-optimization/85143
18349 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
18350
18351 2018-05-01 Tom de Vries <tom@codesourcery.com>
18352
18353 PR lto/85451
18354 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
18355 not found" error message.
18356
18357 2018-05-01 Tom de Vries <tom@codesourcery.com>
18358
18359 PR other/83786
18360 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
18361 * vec.c (test_ordered_remove_if): New function.
18362 (vec_c_tests): Call test_ordered_remove_if.
18363 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
18364 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
18365 * tree-vect-patterns.c (vect_pattern_recog_1): Use
18366 VEC_ORDERED_REMOVE_IF.
18367
18368 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
18369
18370 PR tree-optimization/82665
18371 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
18372 pointer subtraction where arguments come from a memchr call.
18373
18374 2018-05-01 Jakub Jelinek <jakub@redhat.com>
18375
18376 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
18377 --push-state --as-needed and --pop-state instead of --as-needed and
18378 --no-as-needed if ld supports it.
18379 * configure: Regenerated.
18380
18381 PR web/85578
18382 * doc/install.texi2html: Replace _002d with - and _002a with * in
18383 generated html files using sed.
18384
18385 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18386
18387 PR c++/85523
18388 * gcc-rich-location.c (blank_line_before_p): New function.
18389 (use_new_line): New function.
18390 (gcc_rich_location::add_fixit_insert_formatted): New function.
18391 * gcc-rich-location.h
18392 (gcc_rich_location::add_fixit_insert_formatted): New function.
18393
18394 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18395
18396 * selftest.c (assert_streq): Rename "expected" and "actual" to
18397 "val1" and "val2". Extend NULL-handling to cover both inputs
18398 symmetrically, while still requiring both to be non-NULL for a pass.
18399 * selftest.h (assert_streq): Rename "expected" and "actual" to
18400 "val1" and "val2".
18401 (ASSERT_EQ): Likewise.
18402 (ASSERT_EQ_AT): Likewise.
18403 (ASSERT_KNOWN_EQ): Likewise.
18404 (ASSERT_KNOWN_EQ_AT): Likewise.
18405 (ASSERT_NE): Likewise.
18406 (ASSERT_MAYBE_NE): Likewise.
18407 (ASSERT_MAYBE_NE_AT): Likewise.
18408 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
18409 the assertion to pass.
18410 (ASSERT_STREQ_AT): Likewise.
18411
18412 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18413
18414 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
18415 interaction with -pie.
18416
18417 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18418
18419 * selftest.h: Fix alphabetization of per-source-file selftest
18420 declarations.
18421
18422 2018-04-30 Jason Merrill <jason@redhat.com>
18423
18424 PR c++/61982 - dead stores to destroyed objects.
18425 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
18426 of clobber.
18427
18428 2018-04-30 Jason Merrill <jason@redhat.com>
18429
18430 * tree.c (build_clobber): New.
18431 * tree.h: Declare it.
18432 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
18433
18434 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18435
18436 * diagnostic-show-locus.c (layout::layout): Update for
18437 location_get_source_line returning a char_span.
18438 (struct char_span): Move to input.h.
18439 (struct correction): Update for fields in char_span becoming
18440 private.
18441 (struct source_line): Update for location_get_source_line
18442 returning a char_span.
18443 (layout::print_line): Likewise.
18444 * edit-context.c (edited_file::print_content): Likewise.
18445 (edited_file::print_diff_hunk): Likewise.
18446 (edited_file::print_run_of_changed_lines): Likewise.
18447 (edited_file::get_num_lines): Likewise.
18448 (edited_line::edited_line): Likewise.
18449 * final.c (asm_show_source): Likewise.
18450 * input.c (location_get_source_line): Convert return type
18451 from const char * to char_span, losing the final "line_len"
18452 param.
18453 (dump_location_info): Update for the above.
18454 (get_substring_ranges_for_loc): Likewise. Use a char_span
18455 when handling the literal within the line.
18456 (test_reading_source_line): Update for location_get_source_line
18457 returning a char_span.
18458 * input.h (class char_span): Move here from
18459 diagnostic-show-locus.c, converting from a struct to a class.
18460 Make data members private.
18461 (char_span::operator bool): New.
18462 (char_span::length): New.
18463 (char_span::get_buffer): New.
18464 (char_span::operator[]): New.
18465 (char_span::subspan): Make const.
18466 (char_span::xstrdup): New.
18467 (location_get_source_line): Convert return type from const char *
18468 to char_span, losing the final "line_size" param.
18469
18470 2018-04-30 Jan Hubicka <jh@suse.cz>
18471
18472 * lto-wrapper.c (ltrans_priorities): New static var.
18473 (cmp_priority): New.
18474 (run_gcc): Read priorities and if doing parallel build order
18475 the Makefile by them.
18476
18477 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18478
18479 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
18480
18481 2018-04-30 Richard Biener <rguenther@suse.de>
18482
18483 * tree-cfg.c (verify_address): Remove base argument, add
18484 flag whether to check TREE_ADDRESSABLE and do that.
18485 (verify_expr): Remove.
18486 (verify_types_in_gimple_reference): Add pieces from verify_expr.
18487 (verify_gimple_assign_single): Likewise.
18488 (verify_gimple_switch): Likewise.
18489 (verify_expr_location_1): Dereference tp once. Add (disabled)
18490 piece from verify_expr.
18491 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
18492
18493 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18494
18495 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
18496
18497 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18498
18499 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
18500 (small_data_pattern): Likewise.
18501 (arc_rewrite_small_data): Likewise.
18502 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
18503 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
18504 (get_symbol_alignment): New function.
18505 (legitimate_small_data_address_p): Likewise.
18506 (legitimate_scaled_address): Update, call
18507 legitimate_small_data_address_p.
18508 (output_sdata): New static variable.
18509 (arc_print_operand): Update how we handle small data operands.
18510 (arc_print_operand_address): Likewise.
18511 (arc_legitimate_address_p): Update, use
18512 legitimate_small_data_address_p.
18513 (arc_rewrite_small_data_p): Remove.
18514 (arc_rewrite_small_data_1): Likewise.
18515 (arc_rewrite_small_data): Likewise.
18516 (small_data_pattern): Likewise.
18517 (compact_sda_memory_operand): Update to use
18518 legitimate_small_data_address_p and get_symbol_alignment.
18519 (prepare_move_operands): Don't rewite sdata pattern.
18520 (prepare_extend_operands): Remove.
18521 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
18522 pattern.
18523 (zero_extendqisi2): Likewise.
18524 (zero_extendhisi2): Likewise.
18525 (extendqihi2): Likewise.
18526 (extendqisi2): Likewise.
18527 (extendhisi2): Likewise.
18528 (addsi3): Likewise.
18529 (subsi3): Likewise.
18530 (andsi3): Likewise.
18531 * config/arc/constraints.md (Usd): Change it to memory constraint.
18532
18533 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18534
18535 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
18536 as source of std instructions.
18537 * config/arc/arc.md (movsi_insn): Update pattern predicate to
18538 allow 6-bit constants as source for store instructions.
18539 (movdi_insn): Update instruction pattern to allow 6-bit constants
18540 as source for store instructions.
18541
18542 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18543
18544 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
18545
18546 2018-04-30 Nathan Sidwell <nathan@acm.org>
18547 Sandra Loosemore <sandra@codesourcery.com>
18548
18549 * dumpfile.c (dump_open): Allow '-' for stdout.
18550 * doc/invoke.texi (Developer Options): Document dump filename
18551 determination early. Document stdin/stdout selection.
18552
18553 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
18554
18555 Microblaze Target: PIC data text relative
18556
18557 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
18558 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
18559 Add declaration.
18560 * config/microblaze/microblaze.h (microblaze_constant_address_p):
18561 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
18562 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
18563 New addressing mode for data-text relative position indepenedent code.
18564 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
18565 'ADDRESS_SYMBOLIC_TXT_REL'.
18566 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
18567 (microblaze_legitimate_pic_operand): Exclude function calls from
18568 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
18569 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
18570 addresses cases.
18571 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18572 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18573 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
18574 for 'address + offset'.
18575 (microblaze_expand_prologue): Add new function prologue call for
18576 'r20' assignation.
18577 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
18578 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
18579 table in case of TARGET_PIC_DATA_TEXT_REL.
18580 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
18581 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
18582 Add new macros 'UNSPEC_TEXT',
18583 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
18584 + exclude function calls from 'UNSPEC_PLT' in case of data text
18585 relative mode.
18586 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18587 new target hook for generating address diff vector tables in case of
18588 flag_pic.
18589 * doc/tm.texi : Regenerate.
18590 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
18591 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
18592 of addr diff vector generation.
18593 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18594 target hook definition.
18595 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
18596 Add default function for generate_pic_addr_diff_vec -> flag_pic.
18597 * doc/invoke.texi (Add new pic option): Add new microblaze pic
18598 option for data text relative.
18599
18600 2018-04-30 Richard Biener <rguenther@suse.de>
18601
18602 * tree-chrec.h (evolution_function_is_constant_p): Remove
18603 redundant check.
18604 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
18605
18606 2018-04-30 Richard Biener <rguenther@suse.de>
18607
18608 PR bootstrap/85571
18609 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
18610
18611 2018-04-30 Richard Biener <rguenther@suse.de>
18612
18613 PR tree-optimization/28364
18614 PR tree-optimization/85275
18615 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
18616 copying first exit test.
18617
18618 2018-04-28 Mark Wielaard <mark@klomp.org>
18619
18620 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
18621 dwarf_version >= 5.
18622 (dwarf_AT): Handle DW_AT_addr_base.
18623 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
18624
18625 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
18626
18627 PR target/84431
18628 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
18629 (*ashl<dwi>3_doubleword_mask_1): Ditto.
18630 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
18631 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
18632
18633 2018-04-28 Richard Biener <rguenther@suse.de>
18634
18635 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
18636 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
18637 to reflect use. Only add interesting stmts.
18638
18639 2018-04-27 Martin Jambor <mjambor@suse.cz>
18640
18641 PR ipa/85549
18642 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
18643 the jump function allows for passing through aggregate values.
18644
18645 2018-04-27 David Malcolm <dmalcolm@redhat.com>
18646
18647 * input.h (in_system_header_at): Convert from macro to inline
18648 function.
18649 (from_macro_expansion_at): Likewise.
18650 (from_macro_definition_at): Likewise.
18651
18652 2018-04-27 Jeff Law <law@redhat.com>
18653
18654 * config.gcc: Mark tile* targets as deprecated/obsolete.
18655
18656 2018-04-27 Richard Biener <rguenther@suse.de>
18657
18658 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
18659 fix for ILP32.
18660
18661 2018-04-27 Richard Biener <rguenther@suse.de>
18662
18663 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
18664
18665 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
18666
18667 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
18668 with Yd constraint. Set "preferred_for_speed" attribute from
18669 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
18670 with Yd constraint.
18671 (*movdi_internal): Ditto.
18672 (movti_interunit splitters): Remove
18673 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
18674 (movdi_interunit splitters): Ditto.
18675 * config/i386/constraints.md (Ye): Remove.
18676 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
18677
18678 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18679
18680 PR target/85512
18681 * config/aarch64/constraints.md (Usg): Limit to 31.
18682 (Usj): Limit to 63.
18683
18684 2018-04-27 Jakub Jelinek <jakub@redhat.com>
18685
18686 PR tree-optimization/85529
18687 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
18688 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
18689 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
18690 zero extension or masking of the MSB bit.
18691 (optimize_range_tests): Add FIRST_BB argument, pass it through
18692 to optimize_range_tests_var_bound.
18693 (maybe_optimize_range_tests, reassociate_bb): Adjust
18694 optimize_range_tests callers.
18695
18696 2018-04-26 Richard Biener <rguenther@suse.de>
18697 Jakub Jelinek <jakub@redhat.com>
18698
18699 * cgraph.h (symbol_table): Just declare debug method here.
18700 * symtab.c (symbol_table::debug): Define.
18701
18702 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
18703
18704 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
18705
18706 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
18707
18708 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
18709 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
18710 (*movdi_internal): Substitute Yi and Yj constraint with x
18711 and Ym and Yn constraint with y constraint. Update "isa"
18712 attribute and set "preferred_for_speed" attribute from
18713 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
18714 (*movsi_internal): Ditto.
18715 (*movdf_internal): Ditto.
18716 (*movsf_internal): Ditto.
18717 (*zero_extendsidi2): Ditto.
18718 * config/i386/sse.md (vec_set<mode>_0): Ditto.
18719 (sse2_loadld): Ditto.
18720 (*vec_extract<ssevecmodelower>_0): Ditto.
18721 (*vec_extractv4si_0_zext_sse4): Ditto.
18722 (vec_concatv2di): Ditto.
18723 (*vec_dup<mode>): Ditto.
18724 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
18725 * config/i386/constraints.md (Yi): Remove.
18726 (Yj): Remove.
18727 (Ym): Remove.
18728 (Yn): Remove.
18729
18730 2018-04-26 Nathan Sidwell <nathan@acm.org>
18731
18732 * dumpfile.c (dump_open): New.
18733 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
18734 (dump_finish): Detect stdio/stderr by value not name.
18735
18736 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
18737
18738 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
18739
18740 2018-04-26 Tom de Vries <tom@codesourcery.com>
18741
18742 PR target/84952
18743 * config/nvptx/nvptx.c (verify_neutering_jumps)
18744 (verify_neutering_labels): New function
18745 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
18746
18747 2018-04-26 Tom de Vries <tom@codesourcery.com>
18748
18749 PR target/84025
18750 * config/nvptx/nvptx.c (needs_neutering_p): New function.
18751 (nvptx_single): Use needs_neutering_p to skip over insns that do not
18752 need neutering.
18753
18754 2018-04-26 Richard Biener <rguenther@suse.de>
18755 Tom de Vries <tom@codesourcery.com>
18756
18757 PR lto/85422
18758 * lto-streamer-out.c (output_function): Fixup loops if required to match
18759 discovery done in the reader.
18760
18761 2018-04-26 Richard Biener <rguenther@suse.de>
18762
18763 PR tree-optimization/85116
18764 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
18765 have a loop exit from the single latch predecessor. Remove
18766 case of header with just condition.
18767 (ch_base::copy_headers): Exclude infinite loops from any
18768 processing.
18769 (pass_ch::execute): Record exits.
18770
18771 2018-04-26 Richard Biener <rguenther@suse.de>
18772
18773 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
18774 prologue cost vector and pass it to vect_get_load_cost.
18775 (vect_get_peeling_costs_all_drs): Likewise.
18776 (vect_peeling_hash_get_lowest_cost): Likewise.
18777 (vect_enhance_data_refs_alignment): Likewise.
18778
18779 2018-04-26 Richard Biener <rguenther@suse.de>
18780
18781 PR middle-end/85450
18782 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
18783 checking of integer<->pointer conversions.
18784 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
18785 sign-/zero-extending pointer types.
18786 (expand_omp_for_static_chunk): Likewise.
18787
18788 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
18789 Jean Lee <xiaoyur347@gmail.com>
18790
18791 * config/mips/mips.c (mips_asan_shadow_offset): New function.
18792 (TARGET_ASAN_SHADOW_OFFSET): Define.
18793 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
18794 true for -fsanitize=address.
18795
18796 2018-04-25 Mark Wielaard <mark@klomp.org>
18797
18798 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
18799 shorter ones.
18800
18801 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18802
18803 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
18804 than "alu", remove explicit "memory" and "imm_disp" attributes.
18805 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
18806
18807 PR middle-end/85414
18808 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
18809 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
18810 gen_lowpart_no_emit.
18811
18812 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
18813
18814 PR target/85473
18815 * config/i386/i386.c (ix86_expand_builtin): Change memory
18816 operand to XI, extend p0 to Pmode.
18817 * config/i386/i386.md: Change unspec volatile and operand
18818 1 mode to XI, change operand 0 mode to P.
18819
18820 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18821
18822 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
18823 GET_MODE_MASK before any checking.
18824 (nds32_can_use_bset_p): Likewise.
18825 (nds32_can_use_btgl_p): Likewise.
18826
18827 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18828
18829 * config/nds32/nds32-doubleword.md: New define_split pattern for
18830 illegal register number.
18831
18832 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18833
18834 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
18835
18836 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18837
18838 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
18839
18840 2018-04-25 Richard Biener <rguenther@suse.de>
18841
18842 * lto-streamer.h (LTO_major_version): Bump to 8.
18843
18844 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18845
18846 * BASE-VER: Set to 9.0.0.
18847
18848 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
18849
18850 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
18851 in __abskf2 and __powikf2.
18852
18853 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18854
18855 PR target/85512
18856 * config/aarch64/constraints.md (Usg, Usj): New constraints.
18857 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
18858 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
18859 Use the above on operand 2. Reindent.
18860 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
18861
18862 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18863
18864 PR target/85485
18865 * common/config/i386/i386-common.c (ix86_handle_option): Don't
18866 handle OPT_mcet.
18867 * config/i386/i386.opt (mcet): Removed.
18868 * doc/install.texi: Remove -mcet documentation.
18869 * doc/invoke.texi: Likewise.
18870
18871 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18872
18873 PR target/85485
18874 * doc/install.texi: Remove -mcet from bootstrap-cet.
18875
18876 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18877
18878 PR target/85511
18879 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
18880 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
18881 if TARGET_64BIT.
18882
18883 PR target/85503
18884 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
18885 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
18886 containing a CONST_VECTOR.
18887
18888 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
18889
18890 * doc/install.texi: Update newlib dependency for nvptx.
18891
18892 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18893
18894 PR target/85508
18895 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
18896 instead of INTVAL when shifting x left.
18897
18898 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
18899
18900 PR tree-optimization/85478
18901 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
18902 vect_grouped_store_supported for single element vectors.
18903
18904 2018-04-24 Richard Biener <rguenther@suse.de>
18905
18906 PR target/85491
18907 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
18908 load cost increase to the case of non-constant step.
18909
18910 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18911
18912 PR target/84828
18913 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
18914 destination if any_malformed_asm.
18915
18916 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
18917
18918 PR middle-end/85496
18919 * expr.c (store_field): In the bitfield case, if the value comes from
18920 a function call and is returned in registers by means of a PARALLEL,
18921 do not change the mode of the temporary unless BLKmode and VOIDmode.
18922
18923 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
18924
18925 PR rtl-optimization/85423
18926 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
18927 dependencies to debug insns when the previous insn is non-debug.
18928
18929 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18930
18931 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
18932 enums into a single definition.
18933 (fls): Fix predicates and printing.
18934 (seti): Likewise.
18935
18936 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18937
18938 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
18939 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
18940 and short u6 immediate.
18941 (check_if_valid_sleep_operand): Remove.
18942 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
18943
18944 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18945
18946 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
18947 flag_always_save_lp condition.
18948 * config/nds32/nds32.opt (malways-save-lp): New option.
18949
18950 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18951
18952 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
18953 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
18954 * config/nds32/nds32.h
18955 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
18956 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
18957
18958 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18959
18960 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
18961 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
18962
18963 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18964 Chung-Ju Wu <jasonwucj@gmail.com>
18965
18966 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
18967 Declare.
18968 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
18969 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
18970
18971 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18972
18973 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
18974
18975 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18976
18977 * config/nds32/nds32-protos.h (nds32_data_alignment,
18978 nds32_local_alignment): Declare.
18979 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
18980 nds32_local_alignment): New functions.
18981 (TARGET_CONSTANT_ALIGNMENT): Define.
18982 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
18983
18984 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18985
18986 * config/nds32/nds32.c
18987 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
18988 (TARGET_MODES_TIEABLE_P): Likewise.
18989
18990 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18991
18992 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
18993 level Ofast and Og.
18994
18995 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
18996 Chung-Ju Wu <jasonwucj@gmail.com>
18997
18998 * config/nds32/constants.md (unspec_volatile_element): Add enum values
18999 for unaligned access.
19000 * config/nds32/nds32-intrinsic.c: Implementation of expanding
19001 unaligned access.
19002 * config/nds32/nds32-intrinsic.md: Likewise.
19003 * config/nds32/nds32_intrinsic.h: Likewise.
19004 * config/nds32/nds32.h (nds32_builtins): Likewise.
19005 * config/nds32/nds32.opt (munaligned-access): New option.
19006 * config/nds32/nds32.c (nds32_asm_file_start): Display
19007 flag_unaligned_access status.
19008
19009 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
19010
19011 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
19012 -mno-relax is present.
19013 * config/riscv/linux.h (LINK_SPEC): Ditto.
19014
19015 2018-04-20 Martin Sebor <msebor@redhat.com>
19016
19017 PR c/85365
19018 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
19019 for null pointers.
19020 (gimple_fold_builtin_stxcpy_chk): Same.
19021 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
19022
19023 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
19024
19025 PR target/85456
19026 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
19027 __powikf2 when long double is IEEE 128-bit.
19028
19029 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
19030
19031 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
19032 step to make sure stack always aligned.
19033
19034 2018-04-20 Carl Love <cel@us.ibm.com>
19035
19036 PR target/83402
19037 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
19038 size check for arg0.
19039
19040 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
19041 Tom de Vries <tom@codesourcery.com>
19042
19043 PR target/85445
19044 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
19045 Emit insns for calls too.
19046 (nvptx_find_par): Always look for worker-level predecessor insn.
19047 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
19048 calls.
19049 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
19050 (nvptx_process_pars): Propagate frames for calls.
19051
19052 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
19053
19054 PR target/85469
19055 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
19056 Removed.
19057 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
19058 (ix86_handle_option): Don't handle OPT_mibt.
19059 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
19060 __SHSTK__.
19061 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
19062 has_ibt and ibt.
19063 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
19064 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
19065 (ix86_target_macros): Define __CET__ with flag_cf_protection
19066 for -fcf-protection.
19067 * config/i386/i386.c (isa2_opts): Remove -mibt.
19068 * config/i386/i386.h (TARGET_IBT): Removed.
19069 (TARGET_IBT_P): Likewise.
19070 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
19071 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
19072 * config/i386/i386.opt (mcet): Update help message.
19073 (mshstk): Likewise.
19074 (mibt): Removed.
19075 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
19076 -mcet as an alias for -mshstk.
19077
19078 2018-04-20 Richard Biener <rguenther@suse.de>
19079
19080 PR middle-end/85475
19081 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
19082 complexity by forcing a single use of the multiply operand.
19083
19084 2018-04-20 Martin Jambor <mjambor@suse.cz>
19085
19086 ipa/85449
19087 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
19088 recursion dependency to only apply to non-clones.
19089
19090 2018-04-20 Martin Jambor <mjambor@suse.cz>
19091
19092 ipa/85447
19093 * ipa-cp.c (create_specialized_node): Check that clones of
19094 self-recursive edges exist during IPA-CP.
19095
19096 2018-04-19 Toon Moene <toon@moene.org>
19097
19098 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
19099 by -O3.
19100
19101 2018-04-19 Jakub Jelinek <jakub@redhat.com>
19102
19103 PR tree-optimization/85467
19104 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
19105 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
19106 VECTOR_CST element to type.
19107
19108 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19109
19110 PR target/85397
19111 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
19112 * config/i386/i386.md (builtin_setjmp_setup): Removed.
19113 (builtin_longjmp): Likewise.
19114 (save_stack_nonlocal): New pattern.
19115 (restore_stack_nonlocal): Likewise.
19116
19117 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19118
19119 PR target/85404
19120 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
19121 Replace ASM_OUTPUT_LABEL with fprintf.
19122
19123 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19124
19125 PR target/85417
19126 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
19127 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
19128 * config/i386/i386-c.c (ix86_target_macros_internal): Also
19129 define __IBT__ and __SHSTK__ for -fcf-protection.
19130 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
19131 TARGET_IBT.
19132 (ix86_trampoline_init): Likewise.
19133 (x86_output_mi_thunk): Likewise.
19134 (ix86_notrack_prefixed_insn_p): Likewise.
19135 (ix86_option_override_internal): Don't disallow -fcf-protection.
19136 * config/i386/i386.md (rdssp<mode>): Also enable for
19137 -fcf-protection.
19138 (incssp<mode>): Likewise.
19139 (nop_endbr): Likewise.
19140 * config/i386/i386.opt (mcet): Change help message to built-in
19141 functions only.
19142 (mibt): Likewise.
19143 (mshstk): Likewise.
19144 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
19145 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
19146 enable CET built-in functions.
19147
19148 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
19149
19150 * common/config/i386/i386-common.c
19151 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
19152 OPTION_MASK_ISA_MOVDIRI_UNSET,
19153 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
19154 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
19155 * config.gcc (movdirintrin.h): New header.
19156 * config/i386/cpuid.h (bit_MOVDIRI,
19157 bit_MOVDIR64B): New bits.
19158 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
19159 and -mmvodir64b.
19160 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
19161 (VOID, PVOID, PCVOID)): New function types.
19162 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
19163 __builtin_ia32_directstoreu_u64,
19164 __builtin_ia32_movdir64b): New builtins.
19165 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
19166 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
19167 and -mmovdiri.
19168 (ix86_valid_target_attribute_inner_p): Ditto.
19169 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
19170 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
19171 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
19172 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
19173 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
19174 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
19175 (movdiri<mode>, movdir64b_<mode>): New.
19176 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
19177 * config/i386/immintrin.h: Include movdirintrin.h.
19178 * config/i386/movdirintrin.h: New file.
19179 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
19180
19181 2018-04-19 Richard Biener <rguenther@suse.de>
19182
19183 PR middle-end/85455
19184 * cfg.c (clear_bb_flags): When loop state says we have
19185 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
19186
19187 2018-04-19 Richard Biener <rguenther@suse.de>
19188
19189 PR tree-optimization/84737
19190 * tree-vect-data-refs.c (vect_copy_ref_info): New function
19191 copying restrict info.
19192 (vect_setup_realignment): Use it.
19193 * tree-vectorizer.h (vect_copy_ref_info): Declare.
19194 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
19195 the first DR to all generated stores.
19196 (vectorizable_load): Likewise for loads.
19197
19198 2018-04-19 Jakub Jelinek <jakub@redhat.com>
19199
19200 PR tree-optimization/85446
19201 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
19202 the integral and pointer types to have the same precision.
19203
19204 * doc/install.texi: Document --disable-cet being the default and
19205 --enable-cet=auto.
19206
19207 2018-04-18 Martin Liska <mliska@suse.cz>
19208
19209 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
19210 style.
19211
19212 2018-04-18 Martin Liska <mliska@suse.cz>
19213
19214 Revert
19215 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
19216
19217 PR ipa/83983
19218 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
19219 arguments if they are comparable.
19220
19221 2018-04-18 Martin Liska <mliska@suse.cz>
19222
19223 Revert
19224 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
19225
19226 PR lto/84805
19227 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
19228 incomplete types.
19229
19230 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
19231
19232 PR target/85388
19233 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
19234 ENDBR after calling __morestack.
19235
19236 2018-04-18 David Malcolm <dmalcolm@redhat.com>
19237
19238 PR jit/85384
19239 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
19240 by using gcc_base_ver to generate a gcc_driver_version, and use
19241 it when generating GCC_DRIVER_NAME.
19242 * configure: Regenerate.
19243
19244 2018-04-18 Jakub Jelinek <jakub@redhat.com>
19245
19246 PR target/81084
19247 * config.gcc: Obsolete powerpc*-*-*spe*.
19248
19249 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19250
19251 PR debug/84637
19252 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
19253 (stabstr_D): Change type of unum from unsigned int to
19254 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
19255 type.
19256
19257 2018-04-17 Jim Wilson <jimw@sifive.com>
19258
19259 PR 84856
19260 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
19261 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
19262 Set arg_pointer_offset after using pretend_args_size.
19263
19264 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19265
19266 PR rtl-optimization/85431
19267 * dse.c (record_store): Ignore zero width stores.
19268
19269 PR sanitizer/85230
19270 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
19271 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
19272 __builtin_stack_restore rather than after it.
19273 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
19274 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
19275 argument instead of virtual_dynamic_stack_rtx.
19276
19277 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
19278
19279 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
19280 New prototype.
19281 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
19282 Add note to error message to explain internal mapping of overloaded
19283 built-in function name to non-overloaded built-in function name.
19284 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
19285 function.
19286
19287 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
19288
19289 PR target/85424
19290 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
19291 where the inputs overlap with the output.
19292
19293 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19294
19295 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
19296 (=v, v) alternative and explicit "memory" attribute.
19297 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
19298 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19299 attributes.
19300 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
19301 "sselog1" type instead of "sselog".
19302 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
19303 "sselog". Remove explicit "memory" attribute.
19304 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
19305 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19306 attributes.
19307 (vec_extract_hi_v32hi): Merge all alternatives into one, use
19308 "sselog1" type instead of "sselog". Remove explicit "memory"
19309 attribute.
19310 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
19311 use "sselog1" type instead of "sselog". Remove explicit "memory"
19312 attribute.
19313 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
19314 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19315 attributes.
19316 (vec_extract_hi_v64qi): Merge all alternatives into one, use
19317 "sselog1" type instead of "sselog". Remove explicit "memory"
19318 attribute.
19319 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
19320 use "sselog1" type instead of "sselog". Remove explicit "memory"
19321 attribute.
19322
19323 PR target/85430
19324 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
19325
19326 PR middle-end/85414
19327 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
19328 on a SUBREG.
19329
19330 2018-04-17 Martin Jambor <mjambor@suse.cz>
19331
19332 PR ipa/85421
19333 * ipa-cp.c (create_specialized_node): Call
19334 expand_all_artificial_thunks if necessary.
19335
19336 2018-04-17 Martin Liska <mliska@suse.cz>
19337
19338 PR lto/85405
19339 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
19340 in message, remote space in between '_G' and '('.
19341
19342 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19343
19344 PR target/85281
19345 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
19346 avx512f_vmcmp<mode>3<round_saeonly_name>,
19347 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
19348 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
19349 avx512f_rndscale<mode><round_saeonly_name>,
19350 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
19351 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
19352 Use %<iptr>2 instead of %2 for -masm=intel.
19353 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
19354 avx512f_vcvttss2usi<round_saeonly_name>,
19355 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
19356 -masm=intel.
19357 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
19358 avx512f_vcvttsd2usi<round_saeonly_name>,
19359 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
19360 Use %q1 instead of %1 for -masm=intel.
19361 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
19362 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
19363 of %3 for -masm=intel.
19364 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
19365 -masm=intel.
19366 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
19367 -masm=intel.
19368 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
19369 -masm=intel.
19370 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
19371 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
19372 %g1.
19373 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
19374 -masm=intel.
19375 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
19376 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
19377 %g1 and one with %0 and %1.
19378 (avx512er_vmrcp28<mode><round_saeonly_name>,
19379 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
19380 %1 for -masm=intel.
19381 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
19382 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
19383 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
19384 of %0 and %{%4%} for -masm=intel.
19385 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
19386 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
19387 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
19388 order of %0 and %{%5%}%{z%} for -masm=intel.
19389
19390 2018-04-17 Jan Hubicka <jh@suse.cz>
19391
19392 PR lto/85405
19393 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
19394
19395 2018-04-17 Martin Liska <mliska@suse.cz>
19396
19397 PR ipa/85329
19398 * multiple_target.c (create_dispatcher_calls): Set apostrophes
19399 for target_clone error message. Make default implementation
19400 clone to be a local declaration.
19401 (separate_attrs): Add new argument and check for an empty
19402 string.
19403 (expand_target_clones): Handle it.
19404 (ipa_target_clone): Make redirection just for target_clones
19405 functions.
19406
19407 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
19408 Tom de Vries <tom@codesourcery.com>
19409
19410 PR middle-end/84955
19411 * omp-expand.c (expand_oacc_for): Add dummy false branch for
19412 tiled basic blocks without omp continue statements.
19413
19414 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
19415
19416 PR target/83660
19417 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
19418 vec_extract expression as having side effects to make sure it gets
19419 a cleanup point.
19420
19421 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
19422
19423 PR target/85403
19424 * config/i386/i386.c (get_builtin_code_for_version): Check
19425 error_mark_node.
19426
19427 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
19428
19429 PR target/84331
19430 * config.gcc: Support "skylake".
19431 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
19432 PROCESSOR_SKYLAKE.
19433 * config/i386/i386.c (m_SKYLAKE): Define.
19434 (processor_target_table): Add "skylake".
19435 (ix86_option_override_internal): Add "skylake".
19436 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
19437 PROCESSOR_CANNONLAKE.
19438 (get_builtin_code_for_version): Fix priority for
19439 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
19440 PROCESSOR_SKYLAKE-AVX512.
19441 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
19442 (processor_type): Add PROCESSOR_SKYLAKE.
19443
19444 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
19445 Jason Merrill <jason@redhat.com>
19446
19447 PR c++/85112
19448 * convert.c (convert_to_integer_1): Use direct recursion for
19449 enumeral types and types with a precision less than the number
19450 of bits in their mode.
19451
19452 2018-04-16 Julia Koval <julia.koval@intel.com>
19453
19454 PR target/84413
19455 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
19456 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
19457
19458 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
19459
19460 PR target/85293
19461 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
19462 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
19463 and -mno-direct-move.
19464
19465 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
19466
19467 PR target/83402
19468 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
19469 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
19470 Ensure negative shifts result in {0}.
19471
19472 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
19473
19474 PR rtl-optimization/79916
19475 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
19476 regs (if any) to define how to gnerate SD moves when LRA is in
19477 progress.
19478
19479 2018-04-13 Jakub Jelinek <jakub@redhat.com>
19480
19481 PR rtl-optimization/85393
19482 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
19483 * except.c (expand_dw2_landing_pad_for_region): Make static.
19484 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
19485 a label and unconditional jump to old_bb, rather than
19486 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
19487 basic block.
19488
19489 PR rtl-optimization/85376
19490 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
19491 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
19492 instead of a specific value.
19493
19494 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19495 Bin Cheng <bin.cheng@arm.com>
19496
19497 PR tree-optimization/82965
19498 PR tree-optimization/83991
19499 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
19500 by_profile_only parameter.
19501 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
19502 information if the loop was predicted to iterate too many times.
19503 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
19504
19505 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19506
19507 PR lto/71991
19508 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
19509 always inline.
19510
19511 2018-04-13 Martin Liska <mliska@suse.cz>
19512 Jakub Jelinek <jakub@redhat.com>
19513
19514 PR middle-end/81657
19515 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
19516 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
19517 * builtins.c (expand_builtin_memory_copy_args): Use
19518 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
19519 handle dest_addr == pc_rtx.
19520
19521 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
19522
19523 PR target/85291
19524 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
19525 asked to not generate direct moves.
19526 (fix_trunc<mode>si2_stfiwx): Similar.
19527 (fix_trunc<mode>si2_internal): Similar.
19528
19529 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19530
19531 PR debug/83157
19532 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
19533 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
19534 lookup if dest in some wider mode is known to be const0_rtx and
19535 if so, record permanent equivalence for it to be ZERO_EXTEND of
19536 the narrower mode destination.
19537
19538 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19539
19540 * lto-streamer-out.c (output_function): Revert 259346.
19541 * omp-expand.c (expand_oacc_for): Likewise.
19542
19543 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
19544
19545 PR rtl-optimization/85354
19546 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
19547 * sel-sched.c (sel_global_init): ... here.
19548
19549 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
19550
19551 PR target/85238
19552 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
19553 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
19554 mode for PE-COFF targets.
19555 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
19556 (i386_pe_asm_lto_end): Likewise.
19557 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
19558 (TARGET_ASM_LTO_END): Likewise.
19559 * config/i386/winnt.c (saved_debug_info_level): New static variable.
19560 (i386_pe_asm_lto_start): New function.
19561 (i386_pe_asm_lto_end): Likewise.
19562
19563 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19564 Richard Biener <rguenther@suse.de>
19565
19566 PR middle-end/84955
19567 * lto-streamer-out.c (output_function): Fix CFG loop state before
19568 streaming out.
19569 * omp-expand.c (expand_oacc_for): Handle calls to internal
19570 functions like regular functions.
19571
19572 2018-04-12 Richard Biener <rguenther@suse.de>
19573
19574 PR lto/85371
19575 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
19576 for the early LTO debug to properly generate references to it
19577 during DIE emission. Do not re-use that for the skeleton for
19578 split-dwarf.
19579 (dwarf2out_early_finish): Likewise.
19580
19581 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19582
19583 PR target/85328
19584 * config/i386/sse.md
19585 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
19586 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
19587 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
19588 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
19589 and output is a reg, avoid creating invalid lowpart subreg, but
19590 instead split into a 512-bit move. Don't split if not AVX512VL,
19591 input is xmm16+ reg and output is a mem.
19592 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
19593 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
19594 xmm16+ reg and output is a mem.
19595
19596 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
19597
19598 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
19599 also for flag_dwarf2_cfi_asm.
19600
19601 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19602
19603 PR rtl-optimization/85342
19604 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
19605 a bool scalar var inside of the loop instead. Don't try to update
19606 recog_data.operand after failed apply_change_group.
19607
19608 2018-04-12 Tom de Vries <tom@codesourcery.com>
19609
19610 PR target/85296
19611 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
19612 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
19613 array with flexible array member as array without given dimension.
19614 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
19615 argument for undefined param to true.
19616
19617 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
19618
19619 PR target/85321
19620 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19621 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
19622 from PowerPC section.
19623 * config/rs6000/sysv4.opt (mcall-): Improve help text.
19624 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
19625 help text that is too long.
19626 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
19627 help text that is too long.
19628 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
19629 help text that is too long.
19630
19631 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
19632
19633 * config/alpha/alpha.md (stack_probe_internal): Rename
19634 from "probe_stack". Update all callers.
19635
19636 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19637
19638 PR rtl-optimization/84566
19639 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
19640 sched_macro_fuse_insns.
19641
19642 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19643
19644 PR target/84301
19645 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
19646 (compute_block_dependences): ... from here.
19647
19648 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19649
19650 PR tree-optimization/85331
19651 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
19652 from int to HOST_WIDE_INT.
19653
19654 2018-04-11 Martin Jambor <mjambor@suse.cz>
19655
19656 PR ipa/84149
19657 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
19658 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
19659 not the same as the source val.
19660 (cgraph_edge_brings_value_p): New parameter.
19661 (gather_edges_for_value): Pass destination value to
19662 cgraph_edge_brings_value_p.
19663 (perhaps_add_new_callers): Likewise.
19664 (get_info_about_necessary_edges): Likewise and exclude values brought
19665 only by self-recursive edges.
19666 (create_specialized_node): Redirect only clones of self-calling edges.
19667 (+self_recursive_pass_through_p): New function.
19668 (find_more_scalar_values_for_callers_subset): Use it.
19669 (find_aggregate_values_for_callers_subset): Likewise.
19670 (known_aggs_to_agg_replacement_list): Removed.
19671 (decide_whether_version_node): Re-calculate known constants for all
19672 remaining context clones.
19673
19674 2018-04-11 Richard Biener <rguenther@suse.de>
19675
19676 PR lto/85339
19677 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
19678 from early DWARF output.
19679 (dwarf2out_early_finish): Output line info unconditionally into
19680 early DWARF and add reference to it.
19681
19682 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19683
19684 PR target/85281
19685 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
19686 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
19687 other than V2DFmode using iptr mode attribute.
19688 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
19689
19690 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19691
19692 PR rtl-optimization/84659
19693 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
19694
19695 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19696
19697 PR debug/85302
19698 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
19699 SIZEP is NULL.
19700 (output_loc_list): Pass address of a dummy size variable even in the
19701 locview handling loop.
19702 (index_location_lists): Add comment on why skip_loc_list_entry can't
19703 call size_of_locs.
19704
19705 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
19706
19707 PR target/85261
19708 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
19709 into register.
19710
19711 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
19712
19713 PR target/85321
19714 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19715 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
19716 and -mstring-compare-inline-limit.
19717
19718 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19719
19720 PR target/85287
19721 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
19722 for stack clash protection in a register whenever we need it to be in
19723 a register.
19724
19725 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19726
19727 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
19728 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
19729
19730 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19731
19732 PR target/85321
19733 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
19734 the help text.
19735 (mlong-double-): Ditto.
19736 * config/rs6000/sysv4.opt (msdata=): Ditto.
19737 (mtls-size=): Ditto.
19738
19739 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
19740
19741 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
19742 erroneous entries for
19743 "vector int vec_ldl (int, long int *)", and
19744 "vector unsigned int vec_ldl (int, unsigned long int *)".
19745 Add comments and entries for
19746 "vector bool char vec_ldl (int, bool char *)",
19747 "vector bool short vec_ldl (int, bool short *)",
19748 "vector bool int vec_ldl (int, bool int *)",
19749 "vector bool long long vec_ldl (int, bool long long *)",
19750 "vector pixel vec_ldl (int, pixel *)",
19751 "vector long long vec_ldl (int, long long *)",
19752 "vector unsigned long long vec_ldl (int, unsigned long long *)".
19753 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
19754 type tree bool_long_long_type_node and correct definition of
19755 bool_V2DI_type_node to make reference to this new type tree.
19756 (rs6000_mangle_type): Replace erroneous reference to
19757 bool_long_type_node with bool_long_long_type_node.
19758 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
19759 comments to emphasize sign distinctions for char and int types and
19760 replace RS6000_BTI_bool_long constant with
19761 RS6000_BTI_bool_long_long constant. Also add comment to restrict
19762 use of RS6000_BTI_pixel.
19763 (bool_long_type_node): Remove this macro definition.
19764 (bool_long_long_type_node): New macro definition
19765
19766 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19767
19768 PR rtl-optimization/85300
19769 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
19770 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
19771 simplify_unary_operation fails.
19772
19773 2018-04-10 Martin Liska <mliska@suse.cz>
19774
19775 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
19776 cgraph_edge and ipa_ref.
19777
19778 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19779
19780 PR target/85177
19781 PR target/85255
19782 * config/i386/sse.md
19783 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
19784 computation of the VEC_MERGE selector from mask.
19785 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
19786 Fix decoding of the VEC_MERGE selector into mask.
19787
19788 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19789
19790 PR tree-optimization/85286
19791 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
19792
19793 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19794
19795 * final.c (final_1): Set insn_last_address as well as
19796 insn_current_address.
19797
19798 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
19799
19800 PR target/85173
19801 * explow.c (emit_stack_probe): Call validize_mem on memory location
19802 before passing it to gen_probe_stack. Create address operand and
19803 legitimize it for the probe_stack_address case.
19804
19805 2018-04-09 Jan Hubicka <jh@suse.cz>
19806
19807 PR lto/85078
19808 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
19809 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
19810 * tree.c (free_lang_data_in_type): Fix handling of binfos;
19811 walk basetypes.
19812 (free_lang_data): Rebuild type inheritance graph.
19813
19814 2018-04-09 Martin Sebor <msebor@redhat.com>
19815
19816 * invoke.texi (-finline-small-functions): Mention other optimization
19817 options.
19818 (-findirect-inlining, -fpartial-inlining): Same.
19819 (-finline-functions-called-once): Same.
19820 (-freorder-blocks-and-partition): Same.
19821
19822 2018-04-09 Jan Hubicka <jh@suse.cz>
19823
19824 PR rtl/84058
19825 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
19826 jumps; choose last target that matches the criteria (i.e.
19827 no partition changes for non-crossing jumps).
19828 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
19829 support for redirecting crossing jumps to non-crossing.
19830
19831 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
19832
19833 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
19834 also for naked functions.
19835
19836 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
19837
19838 * config/arc/arc.md (add_shift): New pattern.
19839 (add_shift2): Likewise.
19840 (sub_shift): Likewise.
19841 (sub_shift_cmp0_noout): Likewise.
19842 (compare_si_ashiftsi): Likewise.
19843 (xbfu_cmp0_noout): New combine pattern.
19844 (xbfu_cmp0"): Likewise.
19845 (movsi_set_cc_insn): Place the predicable variant first.
19846 (commutative_binary_cmp0_noout): Remove clobber.
19847 (commutative_binary_cmp0): New pattern.
19848 (noncommutative_binary_cmp0): Likewise.
19849 (noncommutative_binary_cmp0_noout): Likewise.
19850 (noncommutative_binary_comparison_result_used): Removed.
19851 (rsub_cmp0): New pattern.
19852 (rsub_cmp0_noout): Likewise.
19853 (extzvsi): Changed, keep only meaningful variants.
19854 (SQH, SEZ): New iterators.
19855 (SQH_postfix): New mode attribute.
19856 (SEZ_prefix): New code attribute.
19857 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
19858 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
19859 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
19860 of numerical value.
19861 (noncommutative_operator): Check the availability of barrel
19862 shifter option.
19863
19864 2018-04-09 Richard Biener <rguenther@suse.de>
19865
19866 PR tree-optimization/85284
19867 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
19868 Only use the niter constraining form of simple_iv when the exit
19869 is always executed.
19870
19871 2018-04-09 Tom de Vries <tom@codesourcery.com>
19872
19873 PR target/84041
19874 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
19875 (define_expand "*memory_barrier"): New define_expand.
19876 (define_insn "memory_barrier"): New insn.
19877
19878 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19879
19880 PR rtl-optimization/80463
19881 PR rtl-optimization/83972
19882 PR rtl-optimization/83480
19883
19884 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
19885 correct producer for the insn.
19886 (tidy_control_flow): Fixup seqnos in case of debug insns.
19887
19888 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19889
19890 PR rtl-optimization/83913
19891
19892 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
19893 different sched-times when merging exprs.
19894
19895 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19896
19897 PR rtl-optimization/83962
19898
19899 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
19900 tidy_fallthru_edge and tidy_control_flow.
19901
19902 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19903
19904 PR rtl-optimization/83530
19905
19906 * sel-sched.c (force_next_insn): New global variable.
19907 (remove_insn_for_debug): When force_next_insn is true, also leave only
19908 next insn in the ready list.
19909 (sel_sched_region): When the region wasn't scheduled, make another pass
19910 over it with force_next_insn set to 1.
19911
19912 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
19913
19914 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
19915 into tm_file.
19916 * config/nds32/constants.md (unspec_volatile_element): Add enum values
19917 for interrupt control.
19918 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
19919 functions for interrupt control.
19920 * config/nds32/nds32-intrinsic.md: Likewise.
19921 * config/nds32/nds32_intrinsic.h: Likewise.
19922 * config/nds32/nds32.h (nds32_builtins): Likewise.
19923
19924 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19925
19926 * config/nds32/nds32.c (nds32_init_machine_status,
19927 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
19928 strict_aligned_p field.
19929 (nds32_expand_to_rtl_hook): New function.
19930 (TARGET_EXPAND_TO_RTL_HOOK): Define.
19931 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
19932
19933 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19934 Chung-Ju Wu <jasonwucj@gmail.com>
19935
19936 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
19937 * config/nds32/nds32-n7.md: New file.
19938 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
19939 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
19940 pipeline.
19941 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
19942 * config/nds32/nds32.md (pipeline_model): Add n7.
19943 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
19944 * config/nds32/pipelines.md: Include n7 settings.
19945
19946 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19947 Chung-Ju Wu <jasonwucj@gmail.com>
19948
19949 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
19950 * config/nds32/nds32-e8.md: New file.
19951 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
19952 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
19953 pipeline.
19954 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
19955 * config/nds32/nds32.md (pipeline_model): Add e8.
19956 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
19957 * config/nds32/pipelines.md: Include e8 settings.
19958
19959 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19960 Chung-Ju Wu <jasonwucj@gmail.com>
19961
19962 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
19963 * config/nds32/nds32-n8.md: New file.
19964 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
19965 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
19966 pipeline.
19967 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
19968 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
19969 * config/nds32/nds32.md (pipeline_model): Add n8.
19970 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
19971 * config/nds32/pipelines.md: Include n8 settings.
19972
19973 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19974 Chung-Ju Wu <jasonwucj@gmail.com>
19975
19976 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
19977 * config/nds32/nds32-n9-2r1w.md: New file.
19978 * config/nds32/nds32-n9-3r2w.md: New file.
19979 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
19980 nds32_register_ports): New or modify for cpu n9.
19981 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
19982 pipeline.
19983 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
19984 * config/nds32/nds32-utils.c: New file.
19985 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
19986 TARGET_MUL_SLOW): Define.
19987 * config/nds32/nds32.md (pipeline_model): New attribute.
19988 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
19989 New options that support cpu n9.
19990 * config/nds32/pipelines.md: Include n9 settings.
19991 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
19992
19993 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19994
19995 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
19996 information if necessary.
19997 (output_cond_branch_compare_zero): Likewise.
19998 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
19999 (nds32_target_alignment): Refine for alignment.
20000 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
20001 (FUNCTION_BOUNDARY): Modify.
20002 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
20003 align case.
20004 * config/nds32/nds32.opt (malways-align, malign-functions): New.
20005
20006 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
20007
20008 * config/nds32/constants.md (unspec_volatile_element): Add values for
20009 TLB operation and data prefetch.
20010 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
20011 functions for TLB operation and data prefetch.
20012 * config/nds32/nds32-intrinsic.md: Likewise.
20013 * config/nds32/nds32_intrinsic.h: Likewise.
20014 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
20015 (nds32_print_operand): Likewise.
20016 * config/nds32/nds32.h (nds32_builtins): Likewise.
20017
20018 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
20019 Andrew Pinski <pinsika@gcc.gnu.org>
20020
20021 PR middle-end/82976
20022 * match.pd: Use constant_boolean_node of correct type instead of
20023 boolean_true_node or boolean_false_node for simplifying
20024 pointer comparisons to zero.
20025
20026 2018-04-07 Jakub Jelinek <jakub@redhat.com>
20027
20028 PR tree-optimization/80021
20029 * tree.c (verify_type_variant): Make error call in verify_variant_match
20030 translatable and remove final full stop.
20031
20032 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20033
20034 * config/nds32/constants.md (unspec_volatile_element): Add
20035 UNSPEC_VOLATILE_EH_RETURN.
20036 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
20037 nds32_output_stack_pop): Support dwarf exception handling process.
20038 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
20039 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
20040 exception handling process.
20041 (nds32_compute_stack_frame): Likewise.
20042 (nds32_return_addr_rtx): Likewise.
20043 (nds32_initial_elimination_offset): Likewise.
20044 (nds32_expand_prologue): Likewise.
20045 (nds32_expand_epilogue): Likewise.
20046 (nds32_dynamic_chain_address): New function.
20047 * config/nds32/nds32.h (machine_function): Add fields for dwarf
20048 exception handling.
20049 (DYNAMIC_CHAIN_ADDRESS): Define.
20050 (EH_RETURN_DATA_REGNO): Define.
20051 (EH_RETURN_STACKADJ_RTX): Define.
20052 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
20053 patterns for dwarf exception handling.
20054
20055 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20056
20057 * config/nds32/nds32.h: Clean up obsolete macros.
20058
20059 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20060
20061 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
20062 Add enum values for particular instructions.
20063 * config/nds32/nds32-intrinsic.c: Implementation of expanding
20064 particular intrinsic functions.
20065 * config/nds32/nds32-intrinsic.md: Likewise.
20066 * config/nds32/nds32_intrinsic.h: Likewise.
20067 * config/nds32/nds32.h (nds32_builtins): Likewise.
20068 * config/nds32/nds32.md (type): Add pbsad and pbsada.
20069 (btst, ave): New patterns for particular instructions.
20070
20071 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20072
20073 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
20074 Add enum values for atomic load/store and memory sync.
20075 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
20076 and memory sync.
20077 * config/nds32/nds32-intrinsic.md: Likewise.
20078 * config/nds32/nds32_intrinsic.h: Likewise.
20079 * config/nds32/nds32.h (nds32_builtins): Likewise.
20080
20081 2018-04-07 Jakub Jelinek <jakub@redhat.com>
20082
20083 PR tree-optimization/85257
20084 * fold-const.c (native_encode_vector): If not all elts could fit
20085 and off is -1, return 0 rather than offset.
20086 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
20087 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
20088 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
20089 adjust buffer in native_interpret_expr call.
20090
20091 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20092
20093 * config/nds32/constants.md (unspec_volatile_element): Add cache
20094 control enum values.
20095 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
20096 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
20097 * config/nds32/nds32.c (nds32_cctl_names): New.
20098 (nds32_print_operand): Handle cache control register names.
20099 * config/nds32/nds32.h (nds32_builtins): New enum values.
20100 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
20101 macros.
20102 * config/nds32/nds32.md (type): Add mmu.
20103 * config/nds32/pipelines.md (simple_insn): Add mmu.
20104
20105 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20106
20107 * config/nds32/nds32.md (type): Remove call.
20108 * config/nds32/pipelines.md (simple_insn): Likewise.
20109
20110 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20111
20112 * config/nds32/constants.md (unspec_volatile_element): Add
20113 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
20114 UNSPEC_VOLATILE_FMFCFG.
20115 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
20116 description for fmfcfg and fmfcsr.
20117 (bdesc_1arg): Add fmtcsr.
20118 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
20119 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
20120 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
20121 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
20122 unspec_fmfcfg): New patterns.
20123 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
20124 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
20125 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
20126 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
20127 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
20128 __nds32__fmfcfg): Define.
20129
20130 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20131
20132 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
20133 intrinsic register names.
20134 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
20135 intrinsic register enum values and macros.
20136
20137 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20138
20139 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
20140 for load/store addressing form.
20141 (nds32_print_operand_address): Likewise.
20142
20143 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
20144
20145 PR target/85196
20146 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
20147 based on LABEL_REF. Remove useless assertion.
20148 (pic_address_needs_scratch): Fix formatting.
20149 (sparc_legitimize_pic_address): Minor tweaks.
20150 (sparc_delegitimize_address): Adjust assertion accordingly.
20151 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
20152 into symbolic_operand.
20153 (movsi_high_pic_label_ref): Likewise.
20154 (movsi_lo_sum_pic_label_ref): Likewise.
20155 (movdi_pic_label_ref): Likewise.
20156 (movdi_high_pic_label_ref): Likewise.
20157 (movdi_lo_sum_pic_label_ref): Likewise.
20158
20159 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
20160
20161 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
20162 custom LIB_SPEC setup.
20163
20164 2018-04-06 Ruslan Bukin <br@bsdpad.com>
20165 Kito Cheng <kito.cheng@gmail.com>
20166
20167 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
20168 * config/riscv/freebsd.h: New.
20169
20170 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20171
20172 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
20173 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
20174 file.
20175
20176 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20177 Kito Cheng <kito.cheng@gmail.com>
20178
20179 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
20180 nds32_output_call, nds32_symbol_binds_local_p): New functions.
20181 * config/nds32/nds32-protos.h (nds32_output_call,
20182 nds32_output_return): Declare.
20183 * config/nds32/nds32.md: Refine all the call and return patterns.
20184
20185 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20186
20187 PR debug/85252
20188 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
20189 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
20190
20191 PR rtl-optimization/84872
20192 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
20193 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
20194 EDGE_CROSSING edge.
20195
20196 2018-04-06 Tamar Christina <tamar.christina@arm.com>
20197
20198 * expr.c (copy_blkmode_to_reg): Revert 254862.
20199 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
20200
20201 2018-04-06 Richard Biener <rguenther@suse.de>
20202
20203 PR middle-end/85244
20204 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
20205 after seeing a component reference with an adjacent field. Treat
20206 refs to arrays at struct end of external decls similar to
20207 refs to unconstrained commons.
20208
20209 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20210
20211 PR sanitizer/85213
20212 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
20213 look through SAVE_EXPRs with non-side-effects argument. Adjust
20214 recursive calls.
20215 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
20216 save_p here.
20217
20218 2018-04-06 Richard Biener <rguenther@suse.de>
20219
20220 PR middle-end/85180
20221 * alias.c (find_base_term): New wrapper around find_base_term
20222 unwinding CSELIB_VAL_PTR changes.
20223 (find_base_term): Do not restore CSELIB_VAL_PTR during the
20224 recursion.
20225
20226 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
20227
20228 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
20229 instructions.
20230 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
20231 constant definitions.
20232 ("nop"): lr 0,0 -> nopr r0
20233 ("nop_lr0", "nop_lr1"): New insn definitions.
20234
20235 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20236
20237 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
20238 NDS32_V3PUSH_AVAILABLE_P macro.
20239
20240 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
20241 Chung-Ju Wu <jasonwucj@gmail.com>
20242
20243 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
20244 (nds32*-*-*): Add float and fpu_config into supported_defaults.
20245 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
20246 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
20247 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
20248 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
20249 * config/nds32/constraints.md: New constraints and checking for hard
20250 float configuration.
20251 * config/nds32/iterators.md: New mode iterator and attribute for hard
20252 float configuration.
20253 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
20254 patterns.
20255 * config/nds32/nds32-fpu.md: New file.
20256 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
20257 deal with hard float code generation.
20258 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
20259 ARCH_V3S.
20260 (abi_type, float_reg_number): New enum type.
20261 * config/nds32/nds32-predicates.c: New predicates for hard float.
20262 * config/nds32/nds32-protos.h: Declare functions for hard float.
20263 * config/nds32/nds32.c: Implementation for hard float configuration.
20264 * config/nds32/nds32.h: Definitions for hard float configuration.
20265 * config/nds32/nds32.md: Include hard float machine description and
20266 modify patterns for hard float configuration.
20267 * config/nds32/nds32.opt: New options for hard float configuration.
20268 * config/nds32/predicates.md: New predicates for hard float
20269 configuration.
20270
20271 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20272
20273 * common/config/nds32/nds32-common.c
20274 (nds32_option_optimization_table): Enable -mreleax-hint by default.
20275
20276 2018-04-05 Jakub Jelinek <jakub@redhat.com>
20277
20278 PR middle-end/85195
20279 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
20280 CONSTRUCTOR_ELT (ctor, ...)->value.
20281
20282 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
20283
20284 PR target/85193
20285 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
20286
20287 2018-04-05 Tom de Vries <tom@codesourcery.com>
20288
20289 PR target/85204
20290 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
20291 cond jump.
20292
20293 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20294 Kito Cheng <kito.cheng@gmail.com>
20295
20296 * config/nds32/constraints.md (U33): Fine-tune checking condition.
20297 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
20298 * config/nds32/nds32.h (nds32_16bit_address_type): Add
20299 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
20300
20301 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20302 Kito Cheng <kito.cheng@gmail.com>
20303
20304 * config/nds32/constraints.md (Ufe): New memory constraint.
20305 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
20306 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
20307 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
20308 operands.
20309 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
20310 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
20311
20312 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20313
20314 * config/nds32/nds32.md: Use optimize_size in the condition for
20315 alu-shift instructions.
20316
20317 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20318
20319 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
20320
20321 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20322
20323 * config/nds32/nds32.md (negsi2): Refine pattern.
20324
20325 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20326 Chung-Ju Wu <jasonwucj@gmail.com>
20327
20328 * config/nds32/iterators.md (shift_rotate): New code iterator.
20329 (shift): New code attribute.
20330 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
20331 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
20332 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
20333 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
20334 bit-wise operations.
20335 (andsi3, *andsi3): Ditto.
20336 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
20337 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
20338 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
20339 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
20340 nds32_ior_operand, nds32_xor_operand): New predicates.
20341
20342 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20343
20344 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
20345 (addsi3, subsi3): ... this.
20346
20347 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20348
20349 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
20350
20351 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20352
20353 * config/nds32/nds32.md: Adjust indention.
20354
20355 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20356
20357 * config/nds32/nds32.md (feature): New attribute.
20358
20359 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20360
20361 * config/nds32/nds32.md (subtype): New attribute.
20362
20363 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
20364
20365 PR target/85203
20366 * config/arm/arm-builtins.c (arm_expand_builtin): Change
20367 expansion to perform a bitwise AND of the argument followed by a
20368 boolean negation of the result.
20369
20370 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
20371
20372 PR rtl-optimization/84878
20373 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
20374 the basic block. Assert the use reference is not artificial and that
20375 it has an associated insn.
20376
20377 2018-04-04 Michael Matz <matz@suse.de>
20378
20379 * builtins.c (compute_objsize): Pass correct operand
20380 to array_at_struct_end_p.
20381
20382 2018-04-04 Richard Biener <rguenther@suse.de>
20383
20384 PR lto/85176
20385 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
20386 from contexts for DINFO_LEVEL_TERSE and below.
20387
20388 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20389
20390 * config/nds32/nds32-doubleword.md (move_<mode>): Require
20391 resiter_operand condition.
20392 * config/nds32/nds32.md (*move<mode>): Ditto.
20393
20394 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20395 Monk Chiang <sh.chiang04@gmail.com>
20396
20397 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
20398
20399 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20400
20401 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
20402
20403 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20404 Kito Cheng <kito.cheng@gmail.com>
20405
20406 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
20407 nds32_cond_code_str, output_cond_branch,
20408 output_cond_branch_compare_zero, nds32_expand_cbranch,
20409 nds32_expand_cstore, nds32_expand_movcc,
20410 nds32_output_cbranchsi4_equality_zero,
20411 nds32_output_cbranchsi4_equality_reg,
20412 nds32_output_cbranchsi4_equality_reg_or_const_int,
20413 nds32_output_cbranchsi4_greater_less_zero: New functions.
20414 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
20415 nds32_expand_cstore, nds32_expand_movcc,
20416 nds32_output_cbranchsi4_equality_zero,
20417 nds32_output_cbranchsi4_equality_reg,
20418 nds32_output_cbranchsi4_equality_reg_or_const_int,
20419 nds32_output_cbranchsi4_greater_less_zero): Declare.
20420 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
20421 nds32_rimm11s_operand): New predicates.
20422 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
20423 * config/nds32/nds32.md: Rewrite all the branch and conditional move
20424 patterns.
20425
20426 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20427
20428 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
20429 * config/nds32/nds32.md: Ditto.
20430 * config/nds32/pipelines.md: Ditto.
20431
20432 2018-04-04 Richard Biener <rguenther@suse.de>
20433
20434 PR tree-optimization/85168
20435 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
20436 propagating abnormals.
20437
20438 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20439
20440 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
20441
20442 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20443 Kito Cheng <kito.cheng@gmail.com>
20444
20445 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
20446 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
20447 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
20448 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
20449 * config/nds32/nds32.md (sibcall_internal): New.
20450 (sibcall_register): Remove.
20451 (sibcall_immediate): Remove.
20452 (sibcall_value_internal): New.
20453 (sibcall_value_register): Remove.
20454 (sibcall_value_immediate): Remove.
20455 * config/nds32/predicates.md (nds32_general_register_operand): New.
20456 (nds32_call_address_operand): New.
20457
20458 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20459
20460 PR rtl-optimization/85167
20461 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
20462 bb_defs if *split_p, instead preinitialize it to NULL.
20463
20464 PR tree-optimization/85156
20465 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
20466 evaluating the argument multiple times.
20467
20468 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
20469
20470 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
20471 than vector.
20472 (_mm_cvtpd_ps): Likewise.
20473 (_mm_cvttpd_epi32): Likewise.
20474 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
20475 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
20476 vector, pixel, and bool following altivec.h include.
20477
20478 2018-04-03 Martin Sebor <msebor@redhat.com>
20479
20480 * doc/extend.texi (Common Function Attributes): Clarify.
20481 (const attribute): Likewise.
20482 (pure attribute): Likewise.
20483
20484 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20485
20486 PR target/85169
20487 * config/i386/i386.c (ix86_expand_vector_set): Use
20488 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
20489
20490 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
20491
20492 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
20493 instructions when changing rounding bits to preserve precision bits
20494 in the x87 control word.
20495
20496 2018-04-03 Martin Liska <mliska@suse.cz>
20497
20498 PR tree-optimization/82491
20499 * rtl.h (strip_offset_and_add): Replace += suboffset with
20500 poly_uint64 () + suboffset.
20501
20502 2018-03-29 Martin Liska <mliska@suse.cz>
20503 Martin Jambor <mjambor@suse.cz>
20504
20505 PR ipa/84947
20506 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
20507 param_type is not an integral or pointer type.
20508
20509 2018-04-03 Richard Biener <rguenther@suse.de>
20510
20511 * sese.h (recompute_all_dominators): Remove.
20512
20513 2018-04-02 Martin Sebor <msebor@redhat.com>
20514
20515 * doc/invoke.texi (-Wrestrict): Fix typos.
20516
20517 2018-04-02 Jim Wilson <jimw@sifive.com>
20518
20519 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
20520 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
20521 (<optab>di3, <optab>si3_extend): Likewise.
20522 (<optab>si3_mask, <optab>si3_mask_1): New.
20523 (<optab>di3_mask, <optab>di3_mask_1): New.
20524 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
20525 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
20526 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
20527
20528 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
20529
20530 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
20531 example.
20532
20533 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
20534
20535 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
20536 (nds32_canonicalize_comparison): New function.
20537
20538 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20539 Kito Cheng <kito.cheng@gmail.com>
20540 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20541
20542 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
20543 * config/nds32/constants.md (unspec_volatile_element): Add
20544 UNSPEC_VOLATILE_RELAX_GROUP.
20545 * config/nds32/nds32-relax-opt.c: New file.
20546 * config/nds32/nds32-predicates.c
20547 (nds32_symbol_load_store_p): New function.
20548 * config/nds32/nds32-protos.h
20549 (nds32_symbol_load_store_p): Declare function.
20550 (make_pass_nds32_relax_opt): Declare new rtl pass function.
20551 * config/nds32/nds32.c
20552 (nds32_register_pass): New function to register pass.
20553 (nds32_register_passes): New function to register passes.
20554 * config/nds32/nds32.md (relax_group): New pattern.
20555 * config/nds32/nds32.opt (mrelax-hint): New option.
20556 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
20557
20558 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
20559
20560 * config/nds32/t-nds32: Modify files dependency.
20561
20562 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20563
20564 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
20565 (PROFILE_HOOK): Define its implementation.
20566
20567 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20568
20569 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
20570 type and 32-bit size.
20571
20572 2018-04-01 Jakub Jelinek <jakub@redhat.com>
20573
20574 PR middle-end/85090
20575 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
20576 (V_128_256): New mode iterator.
20577 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
20578 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
20579 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
20580 of V.
20581 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
20582 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
20583
20584 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
20585
20586 PR target/83315
20587 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
20588 NaN inputs correctly.
20589
20590 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
20591
20592 PR target/80546
20593 * config/rs6000/vsx.md (??r): New mode attribute.
20594 (*vsx_mov<mode>_64bit): Use it.
20595 (*vsx_mov<mode>_32bit): Likewise.
20596
20597 2018-03-30 Martin Sebor <msebor@redhat.com>
20598
20599 PR tree-optimization/84818
20600 * builtins.c (check_access): Use warning_n.
20601
20602 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
20603
20604 PR target/83822
20605 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
20606 condition.
20607 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
20608 condition.
20609
20610 2018-03-30 Julia Koval <julia.koval@intel.com>
20611
20612 PR target/84413
20613 * x86-tune.def (movx, partial_reg_dependency): Enable for
20614 m_SKYLAKE_AVX512.
20615
20616 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
20617
20618 PR inline-asm/84985
20619 * lra-constraints.c (process_alt_operands): Move setting
20620 this_alternative_matches below.
20621
20622 2018-03-29 Martin Liska <mliska@suse.cz>
20623
20624 PR lto/84995.
20625 * doc/invoke.texi: Document how LTO works with debug info.
20626 Describe auto-load support of binutils. Mention 'x86-64'
20627 as valid option value of -march option.
20628
20629 2018-03-29 Jakub Jelinek <jakub@redhat.com>
20630
20631 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
20632
20633 PR c/85094
20634 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
20635 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
20636 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
20637 checking.
20638
20639 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20640
20641 PR target/84912
20642 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
20643 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
20644 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
20645 for RS6000_BTM_POWERPC64.
20646 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
20647 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
20648 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
20649 definition.
20650 (DIVDE): Use it.
20651 (DIVDEU): Likewise.
20652
20653 2018-03-28 Carl Love <cel@us.ibm.com>
20654
20655 Revert
20656 2017-09-27 Carl Love <cel@us.ibm.com>
20657
20658 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
20659 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
20660 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
20661 fctiw instruction.
20662
20663 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
20664
20665 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
20666 instead of __vector bool.
20667 (_mm_max_pu8): Likewise.
20668 (_mm_min_pi16): Likewise.
20669
20670 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20671
20672 PR target/84912
20673 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
20674 (DIVWEUO): Likewise.
20675 (DIVDEO): Likewise.
20676 (DIVDEUO): Likewise.
20677 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
20678 DIVWEUO and DIVDEUO.
20679 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
20680 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
20681 (div_extend): Likewise.
20682 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
20683 builtin function.
20684 (__builtin_divweuo): Likewise.
20685 (__builtin_divdeo): Likewise.
20686 (__builtin_divdeuo): Likewise.
20687
20688 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20689
20690 PR target/85095
20691 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
20692 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
20693
20694 PR tree-optimization/82004
20695 * gimple-match-head.c (optimize_pow_to_exp): New function.
20696 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
20697 Don't fold to exp if optimize_pow_to_exp is false.
20698
20699 2018-03-28 Martin Liska <mliska@suse.cz>
20700
20701 PR other/84819
20702 * calls.c (initialize_argument_information): Fix trailing space.
20703 * common.opt: Fix typo and provide better explanation for
20704 -fsanitize-coverage option.
20705 * config/i386/i386.opt: Fix typo.
20706
20707 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20708 Martin Liska <mliska@suse.cz>
20709
20710 PR sanitizer/85081
20711 * gimplify.c (asan_poison_variable): Don't do the check for
20712 gimplify_omp_ctxp here.
20713 (gimplify_decl_expr): Do it here.
20714 (gimplify_target_expr): Likewise.
20715
20716 2018-03-28 Martin Liska <mliska@suse.cz>
20717
20718 PR target/84988
20719 * config/i386/i386.c (ix86_function_arg_advance): Do not call
20720 chkp_type_bounds_count if MPX is not enabled.
20721
20722 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
20723
20724 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
20725
20726 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
20727
20728 PR target/84914
20729 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
20730 function to create the function decl for complex long double
20731 multiply and divide for -mabi=ieeelongdouble.
20732 (init_float128_ieee): Call it.
20733
20734 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
20735
20736 PR target/85044
20737 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
20738 -fcf-protection=branch -mibt.
20739 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
20740
20741 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20742
20743 PR target/81863
20744 * config/arm/arm.c (arm_valid_symbolic_address): Handle
20745 arm_word_relocations.
20746
20747 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
20748
20749 PR target/85056
20750 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
20751 extern array declarations.
20752
20753 2018-03-27 Richard Biener <rguenther@suse.de>
20754
20755 PR middle-end/84067
20756 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
20757 explicit single_use checks.
20758
20759 2018-03-27 Richard Biener <rguenther@suse.de>
20760
20761 PR tree-optimization/85082
20762 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
20763 Valueize the VUSE.
20764
20765 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20766
20767 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
20768 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
20769 Turn on fasynchronous-unwind-tables and funwind-tables.
20770
20771 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
20772
20773 PR target/85073
20774 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
20775 (*bmi_blsr_<mode>_ccz): Ditto.
20776
20777 2018-03-26 Tom de Vries <tom@codesourcery.com>
20778
20779 PR tree-optimization/85063
20780 * omp-general.c (offloading_function_p): New function. Factor out
20781 of ...
20782 * omp-offload.c (pass_omp_target_link::gate): ... here.
20783 * omp-general.h (offloading_function_p): Declare.
20784 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
20785 with attribute omp declare target for offloading functions.
20786
20787 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
20788
20789 PR tree-optimization/84005
20790 * tree-data-ref.h (get_base_for_alignment): Declare.
20791 * tree-data-ref.c (get_base_for_alignment_1): New function.
20792 (get_base_for_alignment): Likewise.
20793 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
20794 get_base_for_alignment to find a suitable base object, instead
20795 of always using drb->base_address.
20796
20797 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20798
20799 PR inline-asm/85022
20800 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
20801 known size by default.
20802
20803 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
20804
20805 PR inline-asm/85030
20806 * lra-constraints.c (process_alt_operands): Don't match BLKmode
20807 and non BLKmode operands.
20808
20809 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20810
20811 PR target/85026
20812 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
20813 Clean up attributes.
20814
20815 2018-03-23 Richard Biener <rguenther@suse.de>
20816
20817 PR debug/85020
20818 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
20819 we are going to emit early debug for LTO.
20820
20821 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20822
20823 PR inline-asm/85034
20824 * function.c (match_asm_constraints_1): Don't optimize if input
20825 doesn't satisfy general_operand predicate for output's mode.
20826
20827 PR inline-asm/85022
20828 * alias.c (write_dependence_p): Don't require for x_canonicalized
20829 non-VOIDmode if x has VOIDmode.
20830
20831 PR sanitizer/85029
20832 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
20833 just don't try to optimize it rather than assert it never happens.
20834
20835 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20836
20837 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
20838 macro expansions for definition of ST_INTERNAL_<mode> and
20839 LD_INTERNAL_<mode> builtins.
20840 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
20841 Remove prototype.
20842 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
20843 function.
20844 (altivec_expand_st_builtin): Likewise.
20845 (altivec_expand_builtin): Remove calls to deleted functions.
20846 (rs6000_address_for_altivec): Delete this function.
20847 * config/rs6000/vector.md: Remove expands for
20848 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
20849
20850 2018-03-22 Sudakshina Das <sudi.das@arm.com>
20851
20852 PR target/84826
20853 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
20854 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
20855 re-computing once computed.
20856 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
20857 (arm_init_machine_status): Initialize
20858 machine->static_chain_stack_bytes.
20859
20860 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20861
20862 PR target/84760
20863 * doc/extend.texi: Add four new prototypes for vec_ld.
20864 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
20865 definitions for more logical presentation.
20866 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
20867 entries for V1TI variants of __builtin_altivec_ld builtin.
20868 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
20869 handling of V1TI variant of LVX icode pattern.
20870 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
20871 (rs6000_gimple_fold_builtin): Likewise.
20872 (altivec_init_builtins): Add code to define
20873 __builtin_altivec_lvx_v1ti function.
20874
20875 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20876
20877 PR inline-asm/84941
20878 * function.c (match_asm_constraints_1): Don't do the optimization
20879 if input isn't a REG, SUBREG, MEM or constant.
20880
20881 2018-03-22 Tom de Vries <tom@codesourcery.com>
20882
20883 PR tree-optimization/84956
20884 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
20885 bb_has_abnormal_pred.
20886
20887 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20888
20889 PR sanitizer/85018
20890 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
20891 DECL_INITIAL (decl) to decl at the end.
20892 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
20893 adjust the comment.
20894
20895 2018-03-21 Joseph Myers <joseph@codesourcery.com>
20896
20897 * doc/extend.texi (__builtin_tgmath): Document when complex
20898 integer types are treated as _Complex _Float64.
20899
20900 2018-03-21 Tom de Vries <tom@codesourcery.com>
20901
20902 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
20903
20904 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20905
20906 PR tree-optimization/84960
20907 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
20908 if it is ENTRY block, move them into single succ of ENTRY in that case.
20909
20910 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
20911
20912 PR tree-optimization/84811
20913 * poly-int.h (poly_span_traits): Remove the T3 parameter and
20914 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
20915 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
20916 (known_subrange_p): Update accordingly. Cast each value involved
20917 in the size comparison, rather than casting the result of the
20918 subtraction.
20919
20920 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20921
20922 PR tree-optimization/84982
20923 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
20924 by flipping the least significant bit rather than all bits from
20925 bitpos to bitpos + bitsize - 1.
20926
20927 2018-03-21 Nathan Sidwell <nathan@acm.org>
20928
20929 * doc/extend.texi (Deprecated Features): Remove mention of
20930 long-deleted deprecations.
20931
20932 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
20933
20934 PR jit/84288
20935 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
20936 * configure: Regenerate.
20937
20938 2018-03-21 Tom de Vries <tom@codesourcery.com>
20939
20940 PR tree-optimization/83126
20941 * tree-parloops.c (num_phis): New function.
20942 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
20943
20944 2018-03-21 Nathan Sidwell <nathan@acm.org>
20945
20946 * doc/extend.texi (Deprecated Features): Update deprecated flags,
20947 mention anon-struct/union members and trailing attributes.
20948
20949 2018-03-21 Bin Cheng <bin.cheng@arm.com>
20950
20951 PR tree-optimization/84969
20952 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
20953 builtin memset partitions if they set different rhs values.
20954
20955 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20956
20957 PR rtl-optimization/84989
20958 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
20959 VEC_DUPLICATE with scalar result mode.
20960
20961 2018-03-21 Martin Liska <mliska@suse.cz>
20962
20963 PR ipa/84963
20964 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
20965 not intended return statement.
20966
20967 2018-03-21 Martin Liska <mliska@suse.cz>
20968
20969 PR target/84988
20970 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
20971 (chkp_find_bound_slots_1): Limit number of iterations.
20972
20973 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
20974
20975 PR target/84838
20976 * Minor grammar fixes for x86 options.
20977
20978 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20979
20980 PR debug/84875
20981 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
20982 holding REG_CFA_RESTORE notes, instead turn them into a USE.
20983
20984 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
20985
20986 PR target/83789
20987 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
20988 (altivec_lvx_<mode>_1op): Likewise.
20989 (altivec_stvx_<mode>_2op): Likewise.
20990 (altivec_stvx_<mode>_1op): Likewise.
20991 (altivec_lvx_<VM2:mode>): New define_expand.
20992 (altivec_stvx_<VM2:mode>): Likewise.
20993 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
20994 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20995 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
20996 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20997 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
20998 (rs6000_gen_lvx): Likewise.
20999 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
21000 (altivec_expand_stv_builtin): Likewise.
21001 (altivec_expand_builtin): Likewise.
21002 * config/rs6000/vector.md: Likewise.
21003
21004 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21005
21006 PR target/82518
21007 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
21008 BYTES_BIG_ENDIAN.
21009
21010 2018-03-20 Richard Biener <rguenther@suse.de>
21011
21012 PR target/84986
21013 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
21014 sign-conversions as zero, fall back to standard scalar_stmt
21015 cost for the rest.
21016
21017 2018-03-20 Martin Liska <mliska@suse.cz>
21018
21019 PR ipa/84825
21020 * predict.c (rebuild_frequencies): Handle case when we have
21021 PROFILE_ABSENT, but flag_guess_branch_prob is false.
21022
21023 2018-03-20 Jakub Jelinek <jakub@redhat.com>
21024
21025 PR target/84990
21026 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
21027 flag_section_anchors.
21028 * varasm.c (use_blocks_for_decl_p): Remove hack for
21029 dw2_force_const_mem.
21030
21031 PR target/84845
21032 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
21033 to ...
21034 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
21035 be created, use lowpart_subreg of operands[0] rather than operands[0]
21036 itself.
21037 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
21038 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
21039 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
21040 and n constraint instead of aarch64_shift_imm_di and Usd.
21041 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
21042 (*aarch64_<optab>_reg_minus<mode>3): ... this.
21043
21044 2018-03-20 Sudakshina Das <sudi.das@arm.com>
21045
21046 PR target/82989
21047 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
21048 to favor GPR over NEON registers.
21049 (<shift>di3_neon): Likewise.
21050
21051 2018-03-20 Tom de Vries <tom@codesourcery.com>
21052
21053 PR target/84952
21054 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
21055 (nvptx_process_pars): Emit bar.sync asap and alap.
21056
21057 2018-03-20 Tom de Vries <tom@codesourcery.com>
21058
21059 PR target/84954
21060 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
21061 seen_label if seen_label is already set.
21062
21063 2018-03-20 Jakub Jelinek <jakub@redhat.com>
21064
21065 PR target/84945
21066 * config/i386/i386.c (fold_builtin_cpu): For features above 31
21067 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
21068 Use 1U instead of 1. Formatting fixes.
21069
21070 PR c/84953
21071 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
21072 instead of TREE_TYPE (s1) for the return value.
21073
21074 2018-03-19 Jakub Jelinek <jakub@redhat.com>
21075
21076 PR tree-optimization/84946
21077 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
21078 bitsize + bitsize in poly_uint64 rather than poly_int64.
21079
21080 PR sanitizer/78651
21081 * dwarf2asm.c: Include fold-const.c.
21082 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
21083 of decl rather than decl itself.
21084
21085 PR rtl-optimization/84643
21086 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
21087
21088 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
21089
21090 PR sanitizer/78651
21091 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
21092 calling assemble_variable.
21093
21094 2018-03-19 Sudakshina Das <sudi.das@arm.com>
21095
21096 PR target/81647
21097 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
21098 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
21099
21100 2018-03-19 Jim Wilson <jimw@sifive.com>
21101
21102 PR bootstrap/84856
21103 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
21104 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
21105 (riscv_first_stack_step): Likewise.
21106 (riscv_option_override): Use STACK_BOUNDARY instead of
21107 MIN_STACK_BOUNDARY.
21108 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
21109 MIN_STACK_BOUNDARY.
21110 (BIGGEST_ALIGNMENT): Set to 128.
21111 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
21112 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
21113 STACK_BOUNDARY.
21114
21115 2018-03-19 Richard Biener <rguenther@suse.de>
21116
21117 PR tree-optimization/84933
21118 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
21119 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
21120
21121 2018-03-19 Richard Biener <rguenther@suse.de>
21122
21123 PR tree-optimization/84859
21124 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
21125 (cond_if_else_store_replacement): Perform sinking operation on
21126 single-store BBs regardless of MAX_STORES_TO_SINK setting.
21127 Generalize what a BB with a single eligible store is.
21128
21129 2018-03-19 Richard Biener <rguenther@suse.de>
21130
21131 PR tree-optimization/84929
21132 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
21133 chrec_is_positive against non-chrec arg.
21134
21135 2018-03-19 Tamar Christina <tamar.christina@arm.com>
21136
21137 PR target/84711
21138 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
21139
21140 2018-03-18 Martin Liska <mliska@suse.cz>
21141
21142 PR rtl-optimization/84635
21143 * regrename.c (build_def_use): Use matches_mode only when
21144 matches >= 0.
21145
21146 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
21147
21148 PR tree-optimization/84913
21149 * tree-vect-loop.c (vectorizable_reduction): Don't try to
21150 vectorize chains of COND_EXPRs.
21151
21152 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21153
21154 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
21155
21156 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21157
21158 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
21159
21160 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21161
21162 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
21163
21164 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21165 Kito Cheng <kito.cheng@gmail.com>
21166
21167 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
21168 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
21169 (nds32_adjust_reg_alloc_order): New function.
21170 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
21171
21172 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
21173
21174 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
21175 nds32_print_operand, nds32_print_operand_address): Use
21176 HOST_WIDE_INT_PRINT_DEC instead.
21177
21178 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21179
21180 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
21181
21182 2018-03-17 Jakub Jelinek <jakub@redhat.com>
21183
21184 PR target/84902
21185 * config/i386/i386.c (initial_ix86_tune_features,
21186 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
21187 unsigned long long.
21188 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
21189 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
21190 rather than 1u << ix86_tune. Formatting fix.
21191 (ix86_option_override_internal): Change ix86_arch_mask from
21192 unsigned int to unsigned HOST_WIDE_INT, initialize to
21193 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
21194 (ix86_function_specific_restore): Likewise.
21195
21196 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21197
21198 PR target/84899
21199 * postreload.c (reload_combine_recognize_pattern): Perform
21200 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
21201 truncate_int_for_mode the result for the destination's mode.
21202
21203 PR c/84909
21204 * hsa-gen.c (mem_type_for_type): Fix comment typo.
21205 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
21206 Likewise.
21207 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21208 Likewise.
21209
21210 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
21211
21212 PR target/84876
21213 * lra-assigns.c (lra_split_hard_reg_for): Don't use
21214 regno_allocno_class_array and sorted_pseudos.
21215 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
21216 insns where regno is used.
21217
21218 2018-03-16 Martin Liska <mliska@suse.cz>
21219
21220 PR ipa/84833
21221 * multiple_target.c (create_dispatcher_calls): Redirect
21222 reference in the symbol table.
21223
21224 2018-03-16 Martin Liska <mliska@suse.cz>
21225
21226 PR ipa/84722
21227 * multiple_target.c (create_dispatcher_calls): Redirect also
21228 an alias.
21229
21230 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21231
21232 PR c++/79937
21233 PR c++/82410
21234 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
21235 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
21236 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
21237
21238 2018-03-16 Julia Koval <julia.koval@intel.com>
21239
21240 * doc/invoke.texi (Skylake Server): Add CLWB.
21241 Cannonlake): Remove CLWB.
21242
21243 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21244
21245 PR tree-optimization/84841
21246 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
21247 1 << 3.
21248 (FLOAT_ONE_CONST_TYPE): Define.
21249 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
21250 (sort_by_operand_rank): Put entries with higher constant_type last
21251 rather than first to match comments.
21252
21253 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
21254
21255 * config/nios2/nios2.md (movsi_internal): Fix thinko in
21256 split predicate.
21257
21258 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21259
21260 PR c++/79085
21261 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
21262 check and use address of target always.
21263
21264 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
21265
21266 PR target/84574
21267 * config/i386/i386.c (indirect_thunk_needed): Update comments.
21268 (indirect_thunk_bnd_needed): Likewise.
21269 (indirect_thunks_used): Likewise.
21270 (indirect_thunks_bnd_used): Likewise.
21271 (indirect_return_needed): New.
21272 (indirect_return_bnd_needed): Likewise.
21273 (output_indirect_thunk_function): Add a bool argument for
21274 function return.
21275 (output_indirect_thunk_function): Don't generate alias for
21276 function return thunk.
21277 (ix86_code_end): Call output_indirect_thunk_function to generate
21278 function return thunks.
21279 (ix86_output_function_return): Set indirect_return_bnd_needed
21280 and indirect_return_needed instead of indirect_thunk_bnd_needed
21281 and indirect_thunk_needed.
21282
21283 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
21284
21285 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
21286 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
21287 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
21288
21289 2018-03-15 David Malcolm <dmalcolm@redhat.com>
21290 Paul Hua <paul.hua.gm@gmail.com>
21291
21292 PR c/84852
21293 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
21294
21295 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
21296
21297 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
21298 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
21299 resp. SFmode cases.
21300
21301 2018-03-15 Tamar Christina <tamar.christina@arm.com>
21302
21303 PR target/84711
21304 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
21305 instead of GET_MODE_SIZE when comparing Units.
21306
21307 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
21308
21309 PR target/68256
21310 * varasm.c (hash_section): Return an unchangeble hash value
21311 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
21312 Return !aarch64_can_use_per_function_literal_pools_p ().
21313
21314 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21315
21316 PR target/84860
21317 * optabs.c (emit_conditional_move): Pass address of cmode's copy
21318 rather than address of cmode as last argument to prepare_cmp_insn.
21319
21320 2018-03-15 Julia Koval <julia.koval@intel.com>
21321
21322 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
21323 F_AVX512VNNI, F_AVX512BITALG): New.
21324
21325 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
21326
21327 PR target/83451
21328 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
21329 insn for floating-point loads and stores.
21330
21331 2018-03-14 Carl Love <cel@us.ibm.com>
21332
21333 * config/rs6000/rs6000-c.c: Add macro definitions for
21334 ALTIVEC_BUILTIN_VEC_PERMXOR.
21335 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
21336 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
21337 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
21338 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
21339 UNSPEC_VPERMXOR.
21340 * config/doc/extend.texi: Add prototypes for vec_permxor.
21341
21342 2018-03-14 David Malcolm <dmalcolm@redhat.com>
21343
21344 PR c/84852
21345 * diagnostic-show-locus.c (class layout_point): Convert m_line
21346 from int to linenum_type.
21347 (line_span::comparator): Use linenum "compare" function when
21348 comparing line numbers.
21349 (test_line_span): New function.
21350 (layout_range::contains_point): Convert param "row" from int to
21351 linenum_type.
21352 (layout_range::intersects_line_p): Likewise.
21353 (layout::will_show_line_p): Likewise.
21354 (layout::print_source_line): Likewise.
21355 (layout::should_print_annotation_line_p): Likewise.
21356 (layout::print_annotation_line): Likewise.
21357 (layout::print_leading_fixits): Likewise.
21358 (layout::annotation_line_showed_range_p): Likewise.
21359 (struct line_corrections): Likewise for field m_row.
21360 (line_corrections::line_corrections): Likewise for param "row".
21361 (layout::print_trailing_fixits): Likewise.
21362 (layout::get_state_at_point): Likewise.
21363 (layout::get_x_bound_for_row): Likewise.
21364 (layout::print_line): Likewise.
21365 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
21366 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
21367 * input.c (selftest::test_linenum_comparisons): New function.
21368 (selftest::input_c_tests): Call it.
21369 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
21370 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
21371 * selftest.h (ASSERT_GT): New macro.
21372 (ASSERT_GT_AT): New macro.
21373 (ASSERT_LT): New macro.
21374 (ASSERT_LT_AT): New macro.
21375
21376 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
21377
21378 PR rtl-optimization/84780
21379 * combine.c (distribute_links): Don't make a link based on pc_rtx.
21380
21381 2018-03-14 Martin Liska <mliska@suse.cz>
21382
21383 * tree.c (record_node_allocation_statistics): Use
21384 get_stats_node_kind.
21385 (get_stats_node_kind): New function extracted from
21386 record_node_allocation_statistics.
21387 (free_node): Use get_stats_node_kind.
21388
21389 2018-03-14 Richard Biener <rguenther@suse.de>
21390
21391 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
21392 that the value-set of ANTIC_IN doesn't grow.
21393
21394 Revert
21395 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
21396 member.
21397 (BB_VISITED_WITH_VISITED_SUCCS): New define.
21398 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
21399
21400 2018-03-14 Julia Koval <julia.koval@intel.com>
21401
21402 * config.gcc (icelake-client, icelake-server): New.
21403 (icelake): Remove.
21404 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
21405 (initial_ix86_arch_features): Ditto.
21406 (PTA_SKYLAKE): Add SGX.
21407 (PTA_ICELAKE): Remove.
21408 (PTA_ICELAKE_CLIENT): New.
21409 (PTA_ICELAKE_SERVER): New.
21410 (ix86_option_override_internal): Split up icelake on icelake client and
21411 icelake server.
21412 (get_builtin_code_for_version): Ditto.
21413 (fold_builtin_cpu): Ditto.
21414 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
21415 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
21416 * config/i386/i386.h (processor_type): Ditto.
21417 * doc/invoke.texi: Ditto.
21418
21419 2018-03-14 Jakub Jelinek <jakub@redhat.com>
21420
21421 PR sanitizer/83392
21422 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
21423 INTEGER_CST offset, add it together with bitpos / 8 and
21424 sign extend based on POINTER_SIZE.
21425
21426 PR target/84844
21427 Revert
21428 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
21429
21430 PR target/78090
21431 * config/i386/constraints.md (Yc): New register constraint.
21432 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
21433 Use Yc constraint for alternative 2 of operand 0. Remove
21434 preferred_for_speed attribute.
21435
21436 2018-03-14 Richard Biener <rguenther@suse.de>
21437
21438 PR tree-optimization/84830
21439 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
21440 with the old one to avoid oscillations.
21441
21442 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
21443
21444 PR target/83712
21445 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
21446 pseudos.
21447 (assign_by_spills): Return a flag of reload assignment failure.
21448 Do not process the reload assignment failures. Do not spill other
21449 reload pseudos if they has the same reg class. Update n if
21450 necessary.
21451 (lra_assign): Add a return arg. Set up from the result of
21452 assign_by_spills call.
21453 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21454 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21455 usage_insns if it is not NULL.
21456 (spill_hard_reg_in_range): New function.
21457 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21458 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21459 function prototypes.
21460 (lra_assign): Change prototype.
21461 * lra.c (lra): Add code to deal with fails by splitting hard reg
21462 live ranges.
21463
21464 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
21465
21466 * config/riscv/riscv.opt (mrelax): New option.
21467 * config/riscv/riscv.c (riscv_file_start): Emit ".option
21468 "norelax" when riscv_mrelax is disabled.
21469 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
21470
21471 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
21472
21473 PR target/84743
21474 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
21475 reassociation for int modes.
21476
21477 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21478
21479 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
21480 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
21481 for big-endian.
21482 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
21483 * config/aarch64/aarch64-sve.md
21484 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
21485 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
21486 (*extend<mode><Vwide>2): Rename to...
21487 (aarch64_sve_extend<mode><Vwide>2): ...this.
21488 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
21489 renaming the old pattern to...
21490 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
21491 unsigned packs.
21492 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
21493 define_expand, renaming the old pattern to...
21494 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
21495 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
21496 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
21497 account when deciding which SVE instruction the optab should use.
21498 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
21499
21500 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21501
21502 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
21503 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
21504 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
21505 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
21506 (tlsdesc_small_<mode>): Turn a define_expand and use
21507 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
21508 (tlsdesc_small_advsimd_<mode>): ...this.
21509 (tlsdesc_small_sve_<mode>): New pattern.
21510
21511 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21512
21513 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
21514 (UNSPEC_UMUL_HIGHPART): New constants.
21515 (MUL_HIGHPART): New int iteraor.
21516 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
21517 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
21518 define_expand.
21519 (*<su>mul<mode>3_highpart): New define_insn.
21520
21521 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
21522
21523 PR lto/84805
21524 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
21525 incomplete types.
21526
21527 2018-03-13 Martin Liska <mliska@suse.cz>
21528
21529 PR ipa/84658.
21530 * (sem_item_optimizer::sem_item_optimizer): Initialize new
21531 vector.
21532 (sem_item_optimizer::~sem_item_optimizer): Release it.
21533 (sem_item_optimizer::merge_classes): Register variable aliases.
21534 (sem_item_optimizer::fixup_pt_set): New function.
21535 (sem_item_optimizer::fixup_points_to_sets): Likewise.
21536 * ipa-icf.h: Declare new variables and functions.
21537
21538 2018-03-13 Jakub Jelinek <jakub@redhat.com>
21539
21540 PR middle-end/84834
21541 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
21542 integer_pow2p@2 and test integer_pow2p in condition.
21543 (A < 0 ? C : 0): Similarly for @1.
21544
21545 PR middle-end/84831
21546 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
21547 characters starting at p contain '\0' character, don't look beyond
21548 that.
21549
21550 PR target/84827
21551 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
21552 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
21553
21554 PR target/84828
21555 * reg-stack.c (change_stack): Change update_end var from int to
21556 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
21557 also call set_block_for_insn on the newly added insns and rescan.
21558
21559 PR target/84786
21560 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
21561 on the last operand.
21562
21563 PR c++/84704
21564 * tree.c (stabilize_reference_1): Return save_expr (e) for
21565 STATEMENT_LIST even if it doesn't have side-effects.
21566
21567 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
21568
21569 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
21570
21571 2018-03-12 Renlin Li <renlin.li@arm.com>
21572
21573 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
21574 aarch64_output_scalar_simd_mov_immediate.
21575
21576 2018-03-12 Martin Sebor <msebor@redhat.com>
21577
21578 PR tree-optimization/83456
21579 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
21580 for perfectly overlapping calls to memcpy.
21581 (gimple_fold_builtin_memory_chk): Same.
21582 (gimple_fold_builtin_strcpy): Handle no-warning.
21583 (gimple_fold_builtin_stxcpy_chk): Same.
21584 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
21585
21586 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21587
21588 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
21589 parameter. Use it for SFmode.
21590 (rs6000_function_arg_advance_1): Adjust.
21591 (rs6000_function_arg): Adjust.
21592 (rs6000_gimplify_va_arg): Pass false for that new parameter.
21593
21594 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21595
21596 PR rtl-optimization/84169
21597 PR rtl-optimization/84780
21598 * combine.c (can_combine_p): Check for a 2-insn combination whether
21599 the destination register is used between the two insns, too.
21600
21601 2018-03-12 Richard Biener <rguenther@suse.de>
21602
21603 PR tree-optimization/84803
21604 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
21605 for refs DR analysis didn't process.
21606
21607 2018-03-12 Richard Biener <rguenther@suse.de>
21608
21609 PR tree-optimization/84777
21610 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
21611 force-vectorize loops ignore whether we are optimizing for size.
21612
21613 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
21614
21615 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
21616 (TARGET_MD_ASM_ADJUST): Define.
21617
21618 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
21619 Kito Cheng <kito.cheng@gmail.com>
21620 Chung-Ju Wu <jasonwucj@gmail.com>
21621
21622 * config/nds32/nds32.c (nds32_compute_stack_frame,
21623 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
21624 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
21625 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
21626 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
21627 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
21628 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
21629 * config/nds32/nds32.md (prologue, epilogue): Use macro
21630 NDS32_V3PUSH_AVAILABLE_P to do checking.
21631
21632 2018-03-11 Jakub Jelinek <jakub@redhat.com>
21633
21634 PR debug/58150
21635 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
21636 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
21637 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
21638 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
21639 addition of most attributes on !orig_type_die or the attribute not
21640 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
21641
21642 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21643 Chung-Ju Wu <jasonwucj@gmail.com>
21644
21645 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
21646 __NDS32_VH__ macro.
21647 * config/nds32/nds32.opt (mvh): New option.
21648
21649 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21650 Chung-Ju Wu <jasonwucj@gmail.com>
21651
21652 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
21653 function.
21654 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
21655 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
21656 definition.
21657
21658 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21659 Chung-Ju Wu <jasonwucj@gmail.com>
21660
21661 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
21662 function.
21663 * config/nds32/nds32-multiple.md (strlensi): New pattern.
21664 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
21665
21666 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
21667 Kito Cheng <kito.cheng@gmail.com>
21668 Chung-Ju Wu <jasonwucj@gmail.com>
21669
21670 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
21671 UNSPEC_FFMISM and UNSPEC_FLMISM.
21672 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
21673 for ffb, ffmism and flmism.
21674 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
21675 (unspec_ffmism): Ditto.
21676 (unspec_flmism): Ditto.
21677 (nds32_expand_builtin_impl): Check if string extension is available.
21678 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
21679 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
21680
21681 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
21682
21683 Reverting patch:
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-10 H.J. Lu <hongjiu.lu@intel.com>
21705
21706 PR target/84807
21707 * config/i386/i386.opt: Replace Enforcment with Enforcement.
21708
21709 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
21710
21711 PR debug/84620
21712 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
21713 (dw_val_node): Add val_symbolic_view.
21714 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
21715 (symview_upper_bound): New.
21716 (new_line_info_table): Initialize symviews_since_reset.
21717 (dwarf2out_source_line): Count symviews_since_reset and set
21718 symview_upper_bound.
21719 (dw_val_equal_p): Handle symview.
21720 (add_AT_symview): New.
21721 (print_dw_val): Handle symview.
21722 (attr_checksum, attr_checksum_ordered): Likewise.
21723 (same_dw_val_p, size_of_die): Likewise.
21724 (value_format, output_die): Likewise.
21725 (add_high_low_attributes): Use add_AT_symview for entry_view.
21726 (dwarf2out_finish): Reset symview_upper_bound, clear
21727 zero_view_p.
21728
21729 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
21730
21731 PR target/83969
21732 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
21733 Add strict argument and use it.
21734 (rs6000_split_multireg_move): Update for new strict argument.
21735 (mem_operand_gpr): Disallow all non-offsettable addresses.
21736 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
21737
21738 2018-03-09 Jakub Jelinek <jakub@redhat.com>
21739
21740 PR target/84772
21741 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
21742 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
21743 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
21744
21745 PR c++/84767
21746 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
21747 decl, use remap_type if we want to use the type.
21748
21749 2018-03-09 Martin Sebor <msebor@redhat.com>
21750
21751 PR tree-optimization/84526
21752 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21753 Remove dead code.
21754 (builtin_access::generic_overlap): Be prepared to handle non-array
21755 base objects.
21756
21757 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
21758
21759 PR rtl-optimization/84682
21760 * lra-constraints.c (process_address_1): Check is_address flag
21761 for address constraints.
21762 (process_alt_operands): Likewise.
21763 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
21764 preprocess_constraints.
21765 * recog.h (preprocess_constraints): Add oploc parameter.
21766 Adjust callers.
21767 * recog.c (preprocess_constraints): Test address_operand for
21768 CT_ADDRESS constraints.
21769
21770 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
21771
21772 PR target/83712
21773 * lra-assigns.c (assign_by_spills): Return a flag of reload
21774 assignment failure. Do not process the reload assignment
21775 failures. Do not spill other reload pseudos if they has the same
21776 reg class.
21777 (lra_assign): Add a return arg. Set up from the result of
21778 assign_by_spills call.
21779 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21780 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21781 usage_insns if it is not NULL.
21782 (spill_hard_reg_in_range): New function.
21783 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21784 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21785 function prototypes.
21786 (lra_assign): Change prototype.
21787 * lra.c (lra): Add code to deal with fails by splitting hard reg
21788 live ranges.
21789
21790 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21791
21792 PR target/83193
21793 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
21794 Accept complain bool parameter. Only emit errors if it is true.
21795 (arm_parse_cpu_option_name): Likewise.
21796 (arm_target_thumb_only): Adjust callers of the above.
21797 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
21798 prototype to take a default true bool parameter.
21799 (arm_parse_arch_option_name): Likewise.
21800
21801 2018-03-09 David Malcolm <dmalcolm@redhat.com>
21802 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
21803
21804 PR jit/64089
21805 PR jit/84288
21806 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
21807 * configure: Regenerate.
21808 * configure.ac ("linker --version-script option"): New.
21809 ("linker soname option"): New.
21810
21811 2018-03-09 Richard Biener <rguenther@suse.de>
21812
21813 PR tree-optimization/84775
21814 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
21815 immediate uses of predicate stmts and mark them modified.
21816
21817 Revert
21818 PR tree-optimization/84178
21819 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21820 to caller.
21821 (version_loop_for_if_conversion): Delay update_ssa call.
21822 (tree_if_conversion): Delay update_ssa until after predicate
21823 insertion.
21824
21825 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
21826
21827 PR target/84763
21828 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
21829 when the function accesses prior frames.
21830
21831 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21832
21833 PR debug/84456
21834 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
21835 gen_llsym, otherwise call maybe_gen_llsym.
21836
21837 PR inline-asm/84742
21838 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
21839 has ',' character inside of it.
21840
21841 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21842
21843 PR target/84748
21844 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
21845 as clobbering CC_REGNUM.
21846
21847 2018-03-08 Richard Biener <rguenther@suse.de>
21848
21849 PR middle-end/84552
21850 * tree-scalar-evolution.c: Include tree-into-ssa.h.
21851 (follow_copies_to_constant): Do not follow SSA names registered
21852 for update.
21853
21854 2018-03-08 Richard Biener <rguenther@suse.de>
21855
21856 PR tree-optimization/84178
21857 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21858 to caller.
21859 (version_loop_for_if_conversion): Delay update_ssa call.
21860 (tree_if_conversion): Delay update_ssa until after predicate
21861 insertion.
21862
21863 2018-03-08 David Malcolm <dmalcolm@redhat.com>
21864
21865 PR tree-optimization/84178
21866 * tree-if-conv.c (release_bb_predicate): Remove the
21867 the assertion that the stmts have NULL use_ops.
21868 Discard the statements, asserting that they haven't
21869 yet been added to a BB.
21870
21871 2018-03-08 Richard Biener <rguenther@suse.de>
21872
21873 PR tree-optimization/84746
21874 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
21875 (phi_translate): Pass in destination ANTIC_OUT set.
21876 (phi_translate_1): Likewise. For a simplified result lookup
21877 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
21878 (phi_translate_set): Adjust.
21879 (do_pre_regular_insertion): Likewise.
21880 (do_pre_partial_partial_insertion): Likewise.
21881
21882 2018-03-08 Martin Liska <mliska@suse.cz>
21883
21884 PR gcov-profile/84735
21885 * doc/gcov.texi: Document usage of profile files.
21886 * gcov-io.h: Document changes in the format.
21887
21888 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
21889
21890 PR debug/84404
21891 PR debug/84408
21892 * dwarf2out.c (struct dw_line_info_table): Update comments for
21893 view == -1.
21894 (FORCE_RESET_NEXT_VIEW): New.
21895 (FORCE_RESETTING_VIEW_P): New.
21896 (RESETTING_VIEW_P): Check for -1 too.
21897 (ZERO_VIEW_P): Likewise.
21898 (new_line_info_table): Force-reset next view.
21899 (dwarf2out_begin_function): Likewise.
21900 (dwarf2out_source_line): Simplify zero_view_p initialization.
21901 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
21902 view directly. Omit view when omitting .loc at line 0.
21903
21904 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21905
21906 PR tree-optimization/84740
21907 * tree-switch-conversion.c (process_switch): Call build_constructors
21908 only if info.phi_count is non-zero.
21909
21910 PR tree-optimization/84739
21911 * tree-tailcall.c (find_tail_calls): Check call arguments against
21912 DECL_ARGUMENTS (current_function_decl) rather than
21913 DECL_ARGUMENTS (func) when checking for tail recursion.
21914
21915 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21916
21917 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
21918 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
21919 Volker Reichelt's entry and add entries for people that perform
21920 GCC fuzzy testing and report numerous bugs.
21921
21922 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
21923
21924 PR target/82411
21925 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
21926 readonly data in sdata, if that is disabled.
21927 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
21928 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
21929 -mreadonly-in-sdata option.
21930
21931 2018-03-07 Martin Sebor <msebor@redhat.com>
21932
21933 PR tree-optimization/84468
21934 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
21935 basic block when looking for nul assignment.
21936
21937 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
21938
21939 PR target/84277
21940 * except.h (output_function_exception_table): Adjust prototype.
21941 * except.c (output_function_exception_table): Remove FNNAME parameter
21942 and add SECTION parameter. Ouput one part of the table at a time.
21943 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
21944 the first part of the exception table and emit unwind directives.
21945 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
21946 (i386_pe_seh_cold_init): Likewise.
21947 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
21948 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
21949 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
21950 (ix86_output_call_insn): Emit a nop in one more case for SEH.
21951 * config/i386/winnt.c: Include except.h.
21952 (struct seh_frame_state): Add reg_offset, after_prologue and
21953 in_cold_section fields.
21954 (i386_pe_seh_end_prologue): Set seh->after_prologue.
21955 (i386_pe_seh_cold_init): New function.
21956 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
21957 to seh->in_cold_section.
21958 (seh_emit_push): Record the offset of the push.
21959 (seh_emit_save): Record the offet of the save.
21960 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
21961 Test seh->after_prologue to disregard the epilogue.
21962 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
21963 (i386_pe_end_cold_function): New function.
21964
21965 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21966
21967 PR fortran/84565
21968 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
21969 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
21970
21971 PR c++/84704
21972 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
21973 on tmp_var.
21974 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
21975 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
21976
21977 PR middle-end/84723
21978 * multiple_target.c: Include tree-inline.h and intl.h.
21979 (expand_target_clones): Diagnose and fail if node->definition and
21980 !tree_versionable_function_p (node->decl).
21981
21982 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
21983
21984 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
21985 sprint_ul.
21986 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
21987 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
21988 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
21989
21990 2018-03-06 Jakub Jelinek <jakub@redhat.com>
21991
21992 PR target/84710
21993 * combine.c (try_combine): Use reg_or_subregno instead of handling
21994 just paradoxical SUBREGs and REGs.
21995
21996 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
21997
21998 * config/arc/arc.c (arc_finalize_pic): Remove function.
21999 (arc_must_save_register): We use single base PIC register, remove
22000 checks to save/restore the PIC register.
22001 (arc_expand_prologue): Likewise.
22002 * config/arc/arc-protos.h (arc_set_default_type_attributes):
22003 Remove.
22004 (arc_verify_short): Likewise.
22005 (arc_attr_type): Likewise.
22006 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
22007 (walk_stores): Likewise.
22008 (arc_address_cost): Make it static.
22009 (arc_verify_short): Likewise.
22010 (branch_dest): Likewise.
22011 (arc_attr_type): Likewise.
22012 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
22013 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
22014 (arc_final_prescan_insn): Remove inserting the nops due to
22015 hardware hazards. It is done in reorg step.
22016 (insn_length_variant_t): Remove.
22017 (insn_length_parameters_t): Likewise.
22018 (arc_insn_length_parameters): Likewise.
22019 (arc_get_insn_variants): Likewise.
22020 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
22021
22022 2018-03-06 Jakub Jelinek <jakub@redhat.com>
22023
22024 PR inline-asm/84683
22025 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
22026 assertion failure.
22027
22028 PR tree-optimization/84687
22029 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
22030 on new_node->decl.
22031 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
22032
22033 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
22034
22035 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
22036 Rename to ppc_speculation_barrier.
22037 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
22038 __builtin_ppc_speculation_barrier.
22039
22040 2018-03-05 Jakub Jelinek <jakub@redhat.com>
22041
22042 PR target/84700
22043 * combine.c (combine_simplify_rtx): Don't try to simplify if
22044 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
22045 are equal to x.
22046
22047 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
22048
22049 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
22050 to 32 bytes when compiling for POWER9.
22051
22052 2018-03-05 Jakub Jelinek <jakub@redhat.com>
22053
22054 PR target/84564
22055 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
22056 regparm >= 3 with no arg reg available also for calls with
22057 flag_force_indirect_call. Pass decl to ix86_function_regparm.
22058
22059 PR target/84524
22060 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
22061 orig,vex.
22062 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
22063
22064 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
22065
22066 PR target/84264
22067 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
22068
22069 2018-03-05 Richard Biener <rguenther@suse.de>
22070
22071 PR tree-optimization/84486
22072 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
22073 When inserting a __builtin_assume_aligned call set the LHS
22074 SSA name alignment info accordingly.
22075
22076 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
22077
22078 PR tree-optimization/84114
22079 * config/aarch64/aarch64.c (aarch64_reassociation_width)
22080 Avoid reassociation of FLOAT_MODE addition.
22081
22082 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
22083
22084 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
22085 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
22086 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
22087 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
22088 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
22089 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
22090 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
22091 and -mwbnoinvd.
22092 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
22093 __builtin_ia32_wbinvd): New builtins.
22094 (SPECIAL_ARGS2): New.
22095 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
22096 (SPECIAL_ARGS2): New.
22097 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
22098 (ix86_valid_target_attribute_inner_p): Ditto.
22099 (ix86_init_mmx_sse_builtins): Add special_args2.
22100 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
22101 TARGET_WBNOINVD_P): New.
22102 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
22103 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
22104 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
22105 * config/i386/immintrin.h (_wbinvd): New intrinsic.
22106 * config/i386/pconfigintrin.h: New file.
22107 * config/i386/wbnoinvdintrin.h: Ditto.
22108 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
22109 wbnoinvdintrin.h.
22110 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
22111
22112 2018-03-05 Richard Biener <rguenther@suse.de>
22113
22114 PR tree-optimization/84670
22115 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
22116 member.
22117 (BB_VISITED_WITH_VISITED_SUCCS): New define.
22118 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
22119 (compute_antic_aux): Only assert the number of values in ANTIC_IN
22120 doesn't grow if all successors (recursively) were visited at least
22121 once.
22122
22123 2018-03-05 Richard Biener <rguenther@suse.de>
22124
22125 PR tree-optimization/84650
22126 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
22127 if executed in the loop pipeline.
22128
22129 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
22130
22131 * doc/configfiles.texi (Configuration Files): Move info about
22132 conditionalizing $target-protos.h to...
22133 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
22134 differs from $target-protos.h.
22135
22136 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
22137 Chung-Ju Wu <jasonwucj@gmail.com>
22138
22139 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
22140 * config/nds32/nds32-multiple.md (setmemsi): Define.
22141 * config/nds32/nds32-memory-manipulation.c
22142 (nds32_gen_dup_4_byte_to_word_value): New.
22143 (emit_setmem_word_loop): New.
22144 (emit_setmem_byte_loop): New.
22145 (nds32_expand_setmem_loop): New.
22146 (nds32_expand_setmem_loop_v3m): New.
22147 (nds32_expand_setmem_unroll): New.
22148 (nds32_expand_setmem): New.
22149
22150 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22151 Chung-Ju Wu <jasonwucj@gmail.com>
22152
22153 * config/nds32/nds32-memory-manipulation.c
22154 (nds32_emit_load_store): New.
22155 (nds32_emit_post_inc_load_store): New.
22156 (nds32_emit_mem_move): New.
22157 (nds32_emit_mem_move_block): New.
22158 (nds32_expand_movmemsi_loop_unknown_size): New.
22159 (nds32_expand_movmemsi_loop_known_size): New.
22160 (nds32_expand_movmemsi_loop): New.
22161 (nds32_expand_movmemsi_unroll): New.
22162 (nds32_expand_movmemqi): Rename ...
22163 (nds32_expand_movmemsi): ... to this.
22164 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
22165 (movmemsi): ... to this.
22166 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
22167 (nds32_expand_movmemsi): ... to this.
22168
22169 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22170 Monk Chiang <sh.chiang04@gmail.com>
22171 Chung-Ju Wu <jasonwucj@gmail.com>
22172
22173 * config/nds32/nds32-protos.h
22174 (nds32_expand_load_multiple): New arguments.
22175 (nds32_expand_store_multiple): Ditto.
22176 (nds32_valid_multiple_load_store): Rename ...
22177 (nds32_valid_multiple_load_store_p): ... to this.
22178 * config/nds32/nds32-memory-manipulation.c
22179 (nds32_expand_load_multiple): Refine implementation.
22180 (nds32_expand_store_multiple): Ditto.
22181 * config/nds32/nds32-multiple.md
22182 (load_multiple): Update nds32_expand_load_multiple interface.
22183 (store_multiple): Update nds32_expand_store_multiple interface.
22184 * config/nds32/nds32-predicates.c
22185 (nds32_valid_multiple_load_store): Rename ...
22186 (nds32_valid_multiple_load_store_p): ... to this and refine
22187 implementation.
22188 * config/nds32/predicates.md
22189 (nds32_load_multiple_and_update_address_operation): New predicate.
22190 (nds32_store_multiple_and_update_address_operation): New predicate.
22191
22192 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22193 Chung-Ju Wu <jasonwucj@gmail.com>
22194
22195 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
22196 (combo): New attribute.
22197 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
22198
22199 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
22200
22201 * config/nds32/nds32.opt: Change -mcmodel= default value.
22202
22203 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
22204 Monk Chiang <sh.chiang04@gmail.com>
22205 Chung-Ju Wu <jasonwucj@gmail.com>
22206
22207 * config/nds32/constants.md (unspec_element): New enum.
22208 * config/nds32/constraints.md (Umw): New constraint.
22209 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
22210 * config/nds32/nds32-intrinsic.md: Likewise.
22211 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
22212 (nds32_valid_smw_lwm_base_p): New.
22213 (nds32_output_smw_single_word): New.
22214 (nds32_output_lmw_single_word): New.
22215 (nds32_expand_unaligned_load): New.
22216 (nds32_expand_unaligned_store): New.
22217 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
22218 (nds32_output_smw_single_word): Declare.
22219 (nds32_output_lmw_single_word): Declare.
22220 (nds32_expand_unaligned_load): Declare.
22221 (nds32_expand_unaligned_store): Declare.
22222 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
22223 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
22224 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
22225 NDS32_BUILTIN_UASTORE_DW.
22226 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
22227 predicate.
22228
22229 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
22230 Kito Cheng <kito.cheng@gmail.com>
22231 Chung-Ju Wu <jasonwucj@gmail.com>
22232
22233 * config/nds32/nds32-intrinsic.c
22234 (nds32_expand_builtin_null_ftype_reg): Delete.
22235 (nds32_expand_builtin_reg_ftype_imm): Ditto.
22236 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
22237 (nds32_read_argument): New.
22238 (nds32_legitimize_target): Ditto.
22239 (nds32_legitimize_argument): Ditto.
22240 (nds32_check_constant_argument): Ditto.
22241 (nds32_expand_unop_builtin): Ditto.
22242 (nds32_expand_unopimm_builtin): Ditto.
22243 (nds32_expand_binop_builtin): Ditto.
22244 (nds32_builtin_decl_impl): Ditto.
22245 (builtin_description): Ditto.
22246 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
22247 (nds32_init_builtins_impl): Ditto.
22248 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
22249 (nds32_builtin_decl): New.
22250 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
22251 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
22252
22253 2018-03-02 Jeff Law <law@redhat.com>
22254
22255 * reorg.c (stop_search_p): Handle DEBUG_INSN.
22256 (redundant_insn, fill_simple_delay_slots): Likewise.
22257 (fill_slots_from_thread): Likewise.
22258 * resource.c (mark_referenced_resources): Likewise.
22259 (mark_set_resources, find_dead_or_set_registers): Likewise.
22260
22261 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22262
22263 * substring-locations.h (format_warning_va): Formatting fix for
22264 ATTRIBUTE_GCC_DIAG.
22265 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
22266 argument.
22267 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
22268 * substring-locations.c: Include intl.h.
22269 (format_warning_va): Turned into small wrapper around
22270 format_warning_n_va, renamed to ...
22271 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
22272 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
22273 use ngettext.
22274 (format_warning_at_substring_n): New function.
22275 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
22276 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
22277 format_warning_at_substring with just a shorter name instead of
22278 const function pointer.
22279 (fmtwarn_n): New function.
22280 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
22281 appropriate, get rid of all the fmtstr temporaries, move conditionals
22282 with G_() wrapped string literals directly into fmtwarn arguments,
22283 cast dir.len to (int), formatting fixes.
22284
22285 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
22286
22287 * doc/invoke.texi: Remove "Cilk Plus" references.
22288
22289 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22290 Richard Biener <rguenther@suse.de>
22291
22292 PR ipa/84628
22293 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
22294 for error or warning attributes if CALL_FROM_THUNK_P is set.
22295 Formatting fixes.
22296
22297 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22298
22299 PR target/56540
22300 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
22301 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
22302
22303 PR target/56540
22304 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
22305 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
22306
22307 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
22308 instead of -1U in last predictors element's probability member.
22309
22310 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
22311
22312 PR ipa/83983
22313 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
22314 arguments if they are comparable.
22315
22316 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22317
22318 PR tree-optimization/84634
22319 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
22320 masks and masked_loop_p with a single loop_masks, making sure it's
22321 null for bb vectorization.
22322
22323 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22324
22325 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
22326 (vect_analyze_data_ref_access): Use loop->safe_len rather than
22327 loop->force_vectorize to check whether there is no alias.
22328
22329 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22330
22331 PR target/84614
22332 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
22333 prototypes.
22334 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
22335 comments.
22336 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
22337 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
22338 instead of a loop around prev_real_insn.
22339 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
22340 prev_real_insn.
22341
22342 PR inline-asm/84625
22343 * config/i386/i386.c (ix86_print_operand): Use conditional
22344 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
22345 zero vector.
22346
22347 2018-03-02 Richard Biener <rguenther@suse.de>
22348
22349 PR tree-optimization/84427
22350 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
22351 (bitmap_set_subtract_values): Rewrite to handle multiple
22352 exprs per value.
22353 (clean): Likewise.
22354 (prune_clobbered_mems): Likewise.
22355 (phi_translate): Take edge instead of pred/phiblock.
22356 (phi_translate_1): Likewise.
22357 (phi_translate_set): Likewise. Insert all translated
22358 exprs for a value into the set, keeping possibly multiple
22359 expressions per value.
22360 (compute_antic_aux): Adjust for phi_translate changes.
22361 When intersecting union the expressions and prune those
22362 not in the final value set, keeping possibly multiple
22363 expressions per value. Do not use value-insertion
22364 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
22365 all expressions. Add verification that the value-sets
22366 only shrink during iteration.
22367 (compute_partial_antic_aux): Adjust for the phi_translate changes.
22368 (do_pre_regular_insertion): Likewise.
22369 (do_pre_partial_partial_insertion): Likewise.
22370
22371 2018-03-02 Richard Biener <rguenther@suse.de>
22372
22373 PR target/82005
22374 * config/darwin.c (saved_debug_info_level): New static global.
22375 (darwin_asm_lto_start): Disable debug info generation for LTO out.
22376 (darwin_asm_lto_end): Restore debug info generation settings.
22377
22378 2018-03-01 Martin Liska <mliska@suse.cz>
22379
22380 PR sanitizer/82484
22381 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
22382 volatile arguments.
22383
22384 2018-03-01 Richard Biener <rguenther@suse.de>
22385
22386 PR debug/84645
22387 * dwarf2out.c (gen_variable_die): Properly handle late VLA
22388 type annotation with LTO when debug was disabled at compile-time.
22389
22390 2018-03-01 Matthew Fortune <mfortune@gmail.com>
22391
22392 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
22393 XINT with INTVAL.
22394 (mips_final_postscan_insn): Likewise.
22395
22396 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
22397
22398 PR rtl-optimization/84528
22399 * alias.c (init_alias_target): Add commentary.
22400 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
22401 a unique base value if the frame pointer is not eliminated
22402 to the stack pointer.
22403
22404 2018-03-01 Tom de Vries <tom@codesourcery.com>
22405
22406 PR rtl-optimization/83327
22407 * lra-int.h (hard_regs_spilled_into): Declare.
22408 * lra.c (hard_regs_spilled_into): Define.
22409 (init_reg_info): Init hard_regs_spilled_into.
22410 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
22411 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
22412 (process_bb_lives): Handle hard_regs_spilled_into.
22413 (lra_create_live_ranges_1): Before doing liveness propagation, clear
22414 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
22415
22416 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
22417
22418 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
22419 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
22420 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
22421 * config/rs6000/aix72.h: New file.
22422
22423 2018-02-28 Jakub Jelinek <jakub@redhat.com>
22424
22425 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
22426 instead of warning_at with conditional singular and plural messages
22427 where possible.
22428
22429 PR target/52991
22430 * stor-layout.c (update_alignment_for_field): For
22431 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
22432 && !DECL_PACKED (field), do the alignment update, just use
22433 only desired_align instead of MAX (type_align, desired_align)
22434 as the alignment.
22435 (place_field): Don't do known_align < desired_align handling
22436 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
22437 is non-NULL, instead do it after rli->prev_field handling and
22438 only if not within a bitfield word. For DECL_PACKED (field)
22439 use type_align of BITS_PER_UNIT.
22440
22441 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
22442
22443 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
22444 superfluous parentheses and trailing spaces.
22445
22446 2018-02-28 Richard Biener <rguenther@suse.de>
22447
22448 PR tree-optimization/84584
22449 * graphite-scop-detection.c (scop_detection::add_scop): Discard
22450 SCoPs with fake exit edge.
22451
22452 2018-02-28 Martin Liska <mliska@suse.cz>
22453
22454 PR testsuite/84597
22455 * timevar.c (timer::print): Fix format to properly print 100%
22456 values.
22457
22458 2018-02-28 Richard Biener <rguenther@suse.de>
22459
22460 PR middle-end/84607
22461 * genmatch.c (capture_info::walk_match): Do not mark
22462 captured expressions without operands as expr_p given
22463 they act more like predicates and should be subject to
22464 "lost tail" side-effect preserving.
22465
22466 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
22467
22468 PR rtl-optimization/81611
22469 * auto-inc-dec.c (attempt_change): Move dead note from
22470 mem_insn if it's the next use of regno
22471 (find_address): Take address use of reg holding
22472 non-incremented value. Add parm to limit search to the named
22473 reg only.
22474 (merge_in_block): Attempt to use a mem insn that is the next
22475 use of the original regno.
22476
22477 2018-02-27 Martin Sebor <msebor@redhat.com>
22478
22479 PR c++/83871
22480 * doc/invoke.texi (-Wmissing-attributes): New option.
22481 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
22482
22483 2018-02-27 Martin Sebor <msebor@redhat.com>
22484
22485 PR translation/84207
22486 * diagnostic-core.h (warning_n, error_n, inform_n): Change
22487 n argument to unsigned HOST_WIDE_INT.
22488 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
22489 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
22490 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
22491 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
22492
22493 2018-02-27 Richard Biener <rguenther@suse.de>
22494
22495 PR tree-optimization/84512
22496 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
22497 Do not use the estimate returned from record_stmt_cost for
22498 the scalar iteration cost but sum properly using add_stmt_cost.
22499
22500 2018-02-27 Richard Biener <rguenther@suse.de>
22501
22502 PR tree-optimization/84466
22503 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
22504 Adjust last change to less strictly validate use operands.
22505
22506 2018-02-27 Martin Liska <mliska@suse.cz>
22507
22508 PR gcov-profile/84548
22509 * gcov.c (process_file): Allow partial overlap and consider it
22510 also as group functions.
22511 (output_lines): Properly calculate range of lines for a group.
22512
22513 2018-02-27 Martin Liska <mliska@suse.cz>
22514
22515 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
22516 'ggc' suffixes. Change first column width.
22517 (timer::print): Fix formatting of the column.
22518
22519 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
22520
22521 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
22522 preserve inline entry blocks for the sake of debug inline
22523 entry point markers alone.
22524 (remove_unused_locals): Suggest in comments a better place to
22525 force the preservation of inline entry blocks that are
22526 otherwise unused, but do not preserve them.
22527
22528 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22529
22530 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
22531
22532 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22533
22534 PR target/84039
22535 * config/i386/constraints.md (Bs): Replace
22536 ix86_indirect_branch_register with
22537 TARGET_INDIRECT_BRANCH_REGISTER.
22538 (Bw): Likewise.
22539 * config/i386/i386.md (indirect_jump): Likewise.
22540 (tablejump): Likewise.
22541 (*sibcall_memory): Likewise.
22542 (*sibcall_value_memory): Likewise.
22543 Peepholes of indirect call and jump via memory: Likewise.
22544 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
22545 (*sibcall_value_GOT_32): Likewise.
22546 * config/i386/predicates.md (indirect_branch_operand): Likewise.
22547 (GOT_memory_operand): Likewise.
22548 (call_insn_operand): Likewise.
22549 (sibcall_insn_operand): Likewise.
22550 (GOT32_symbol_operand): Likewise.
22551 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
22552
22553 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22554
22555 PR rtl-optimization/83496
22556 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
22557 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
22558 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
22559 redundant insn, if any.
22560 (relax_delay_slots): Likewise.
22561 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
22562
22563 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
22564
22565 PR tree-optimization/83965
22566 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
22567 that grouped statements are part of a reduction chain. Return
22568 true if the statement is not marked as a reduction itself but
22569 is part of a group.
22570 (vect_recog_dot_prod_pattern): Don't check whether the statement
22571 is part of a group here.
22572 (vect_recog_sad_pattern): Likewise.
22573 (vect_recog_widen_sum_pattern): Likewise.
22574
22575 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22576
22577 PR debug/84545
22578 * final.c (rest_of_clean_state): Also look for calls inside sequences.
22579
22580 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22581
22582 PR target/84530
22583 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
22584 the bool argument.
22585 (ix86_output_indirect_function_return): New prototype.
22586 (ix86_split_simple_return_pop_internal): Likewise.
22587 * config/i386/i386.c (indirect_return_via_cx): New.
22588 (indirect_return_via_cx_bnd): Likewise.
22589 (indirect_thunk_name): Handle return va CX_REG.
22590 (output_indirect_thunk_function): Create alias for
22591 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
22592 (ix86_output_indirect_jmp): Remove the bool argument.
22593 (ix86_output_indirect_function_return): New function.
22594 (ix86_split_simple_return_pop_internal): Likewise.
22595 * config/i386/i386.md (*indirect_jump): Don't pass false
22596 to ix86_output_indirect_jmp.
22597 (*tablejump_1): Likewise.
22598 (simple_return_pop_internal): Change it to define_insn_and_split.
22599 Call ix86_split_simple_return_pop_internal to split it for
22600 -mfunction-return=.
22601 (simple_return_indirect_internal): Call
22602 ix86_output_indirect_function_return instead of
22603 ix86_output_indirect_jmp.
22604
22605 2018-02-26 Jakub Jelinek <jakub@redhat.com>
22606
22607 PR bootstrap/84405
22608 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
22609 memset and value initialization afterwards.
22610
22611 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
22612
22613 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
22614
22615 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
22616
22617 PR target/84521
22618 * common/config/aarch64/aarch64-common.c
22619 (aarch_option_optimization_table[]): Switch
22620 off fomit-frame-pointer
22621
22622 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22623 Chung-Ju Wu <jasonwucj@gmail.com>
22624
22625 * config/nds32/nds32-multiple.md (load_multiple): Disallow
22626 volatile memory.
22627 (store_multiple): Ditto.
22628
22629 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22630
22631 * config.gcc: Add --with-cpu support for nds32 target.
22632 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
22633 * config/nds32/nds32.opt: Add -mcpu= option.
22634
22635 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
22636
22637 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
22638 isel=yes): Warn for these deprecated options.
22639
22640 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
22641
22642 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
22643 ISA_2_5_MASKS_EMBEDDED.
22644
22645 2018-02-23 Jakub Jelinek <jakub@redhat.com>
22646
22647 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
22648 p->max as pointers rather than using iterative_hash_expr.
22649
22650 2018-02-23 Carl Love <cel@us.ibm.com>
22651
22652 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
22653 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
22654 BU_P8V_OVERLOAD_2.
22655 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
22656 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
22657 P8V_BUILTIN_VEC_VUNSIGNED2.
22658
22659 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
22660
22661 PR target/81572
22662 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
22663 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
22664 LRA_UNKNOWN_ALT.
22665 * lra-constraints.c (curr_insn_transform): Set up
22666 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
22667 LRA_UNKNOWN_ALT.
22668 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
22669 * lra-eliminations.c (spill_pseudos): Ditto.
22670 (process_insn_for_elimination): Ditto.
22671 * lra-lives.c (reg_early_clobber_p): Use the new macros.
22672 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
22673 LRA_NON_CLOBBERED_ALT.
22674
22675 2018-02-22 Martin Sebor <msebor@redhat.com>
22676
22677 PR tree-optimization/84480
22678 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
22679 to maybe_diag_stxncpy_trunc. Call it.
22680 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
22681 from gimple_fold_builtin_strcpy. Print inlining stack.
22682 (handle_builtin_stxncpy): Print inlining stack.
22683 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
22684
22685 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
22686
22687 PR target/84176
22688 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
22689 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
22690 and -fcheck-pointer-bounds are used together.
22691 (indirect_thunk_prefix): New enum.
22692 (indirect_thunk_need_prefix): New function.
22693 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
22694 "_nt" instead of "_bnd" for NOTRACK prefix.
22695 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
22696 (output_indirect_thunk_function): Likewise.
22697 (): Likewise.
22698 (ix86_code_end): Update output_indirect_thunk_function calls.
22699 (ix86_output_indirect_branch_via_reg): Replace
22700 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
22701 (ix86_output_indirect_branch_via_push): Likewise.
22702 (ix86_output_function_return): Likewise.
22703 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
22704 incompatible with -fcf-protection=branch and
22705 -fcheck-pointer-bounds.
22706
22707 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22708
22709 PR target/83335
22710 * config/aarch64/aarch64.c (aarch64_print_address_internal):
22711 Change gcc_assert call to output_operand_lossage.
22712
22713 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22714
22715 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
22716
22717 2018-02-22 DJ Delorie <dj@redhat.com>
22718 Sebastian Perta <sebastian.perta@renesas.com>
22719 Oleg Endo <olegendo@gcc.gnu.org>
22720
22721 * config/rx/rx.c (rx_rtx_costs): New function.
22722 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
22723
22724 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
22725
22726 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
22727
22728 2018-02-22 Martin Liska <mliska@suse.cz>
22729
22730 PR driver/83193
22731 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
22732 Add "native" as a possible value.
22733
22734 2018-02-22 Martin Liska <mliska@suse.cz>
22735
22736 PR driver/83193
22737 * config/i386/i386.c (ix86_option_override_internal):
22738 Add "native" as a possible value for -march and -mtune.
22739
22740 2018-02-22 Jakub Jelinek <jakub@redhat.com>
22741
22742 PR target/84502
22743 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
22744 to all type variants.
22745
22746 PR tree-optimization/84503
22747 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
22748 width as info->bitpos + info->bitsize - start.
22749 (merged_store_group::merge_overlapping): Simplify width computation.
22750 (check_no_overlap): New function.
22751 (imm_store_chain_info::try_coalesce_bswap): Compute expected
22752 start + width and last_order of the group, fail if check_no_overlap
22753 fails.
22754 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
22755 to group if check_no_overlap fails.
22756
22757 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22758
22759 * config/rs6000/altivec.md: Delete contraint arguments to
22760 define_expand, define_split, and define_peephole2, and in
22761 define_insn_and_split if always unused.
22762 * config/rs6000/darwin.md: Ditto.
22763 * config/rs6000/dfp.md: Ditto.
22764 * config/rs6000/rs6000.md: Ditto.
22765 * config/rs6000/sync.md: Ditto.
22766 * config/rs6000/vector.md: Ditto.
22767 * config/rs6000/vsx.md: Ditto.
22768
22769 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22770
22771 * config/rs6000/altivec.md: Write output control strings as braced
22772 blocks instead of double-quoted strings.
22773 * config/rs6000/darwin.md: Ditto.
22774 * config/rs6000/rs6000.md: Ditto.
22775 * config/rs6000/vector.md: Ditto.
22776 * config/rs6000/vsx.md: Ditto.
22777
22778 2018-02-21 Jason Merrill <jason@redhat.com>
22779
22780 PR c++/84314 - ICE with templates and fastcall attribute.
22781 * attribs.c (build_type_attribute_qual_variant): Remove assert.
22782
22783 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22784
22785 * ipa-cp.c (determine_versionability): Fix comment typos.
22786
22787 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22788
22789 PR c/84229
22790 * ipa-cp.c (determine_versionability): Do not version functions caling
22791 va_arg_pack.
22792
22793 2018-02-21 Martin Liska <mliska@suse.cz>
22794
22795 PR driver/83193
22796 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
22797 Add "native" as a possible value.
22798 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
22799 the macro when native cpu detection is available.
22800
22801 2018-02-21 Martin Liska <mliska@suse.cz>
22802
22803 PR driver/83193
22804 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
22805 Add "native" as a possible value.
22806 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
22807 when native cpu detection is available.
22808
22809 2018-02-21 Jakub Jelinek <jakub@redhat.com>
22810 Martin Sebor <msebor@redhat.com>
22811
22812 PR tree-optimization/84478
22813 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
22814 false.
22815 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
22816 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
22817 support which is conservatively correct, for 2 only stay conservative
22818 for maxlen. Formatting and comment capitalization fixes. Add STRICT
22819 argument to the 2 argument get_range_strlen, adjust 6 arg
22820 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
22821 false.
22822 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
22823 (gimple_fold_builtin_strlen): Pass true as last argument to
22824 get_range_strlen.
22825
22826 2018-02-20 Martin Sebor <msebor@redhat.com>
22827
22828 PR middle-end/84095
22829 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
22830 (builtin_memref::set_base_and_offset): Same. Handle inner references.
22831 (builtin_memref::builtin_memref): Factor out parts into
22832 set_base_and_offset and call it.
22833
22834 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22835
22836 PR middle-end/84406
22837 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
22838 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
22839 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
22840 search at the associated MODE_INT.
22841
22842 2018-02-20 Jeff Law <law@redhat.com>
22843
22844 PR middle-end/82123
22845 PR tree-optimization/81592
22846 PR middle-end/79257
22847 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
22848 for range data rather than using global data.
22849 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
22850 range data rather than using global data.
22851 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
22852 pass it to children as needed.
22853 (struct directive::fmtresult): Similarly.
22854 (struct directive::set_width): Similarly.
22855 (struct directive::set_precision): Similarly.
22856 (format_integer, format_directive, parse_directive): Similarly.
22857 (format_none): Accept unnamed vr_values parameter.
22858 (format_percent, format_floating, format_character): Similarly.
22859 (format_string, format_plain): Similarly.
22860 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
22861 the EVRP range analyzer for range data rather than using global data.
22862 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
22863 gimple-ssa-evrp-analyze.h
22864 (class sprintf_dom_walker): Add after_dom_children member function.
22865 Add evrp_range_analyzer member.
22866 (sprintf_dom_walker::before_dom_children): Call into the EVRP
22867 range analyzer as needed.
22868 (sprintf_dom_walker::after_dom_children): New member function.
22869 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
22870 if not optimizing.
22871 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
22872 (evrp_range_analyzer::pop_to_marker): Likewise.
22873
22874 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22875
22876 PR tree-optimization/84419
22877 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
22878 with the required type if its current type is compatible but
22879 different.
22880
22881 2018-02-20 Jakub Jelinek <jakub@redhat.com>
22882
22883 PR middle-end/82004
22884 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
22885 after vectorization.
22886
22887 2018-02-20 Martin Liska <mliska@suse.cz>
22888
22889 PR driver/83193
22890 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
22891 possible values if we don't have a hint.
22892
22893 2018-02-20 Martin Liska <mliska@suse.cz>
22894
22895 PR c/84310
22896 PR target/79747
22897 * final.c (shorten_branches): Build align_tab array with one
22898 more element.
22899 * opts.c (finish_options): Add alignment option limit check.
22900 (MAX_CODE_ALIGN): Likewise.
22901 (MAX_CODE_ALIGN_VALUE): Likewise.
22902 * doc/invoke.texi: Document maximum allowed option value for
22903 all -falign-* options.
22904
22905 2018-02-19 Jakub Jelinek <jakub@redhat.com>
22906
22907 PR target/84146
22908 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
22909 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
22910 * var-tracking.c (emit_note_insn_var_location): Remove all references
22911 to NOTE_INSN_CALL_ARG_LOCATION.
22912 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
22913 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
22914 Use copy_rtx_if_shared.
22915 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
22916 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
22917 (dwarf2out_var_location): Remove handling of
22918 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
22919 on call_insn.
22920 * final.c (final_scan_insn): Remove all references to
22921 NOTE_INSN_CALL_ARG_LOCATION.
22922 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
22923 before dumping final insns.
22924 * except.c (emit_note_eh_region_end): Remove all references to
22925 NOTE_INSN_CALL_ARG_LOCATION.
22926 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
22927 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
22928 * config/arc/arc.c (hwloop_optimize): Likewise.
22929 * config/arm/arm.c (create_fix_barrier): Likewise.
22930 * config/s390/s390.c (s390_chunkify_start): Likewise.
22931 * config/sh/sh.c (find_barrier): Likewise.
22932 * config/i386/i386.c (rest_of_insert_endbranch,
22933 ix86_seh_fixup_eh_fallthru): Likewise.
22934 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
22935 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
22936 * config/frv/frv.c (frv_function_prologue): Likewise.
22937 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
22938 reg note.
22939 (note_outside_basic_block_p): Remove all references to
22940 NOTE_INSN_CALL_ARG_LOCATION.
22941 * gengtype.c (adjust_field_rtx_def): Likewise.
22942 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
22943 Likewise.
22944 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
22945 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
22946
22947 PR c++/84444
22948 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
22949 is ADDR_EXPR.
22950
22951 PR tree-optimization/84452
22952 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
22953 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
22954 is NULL.
22955
22956 2018-02-19 Martin Liska <mliska@suse.cz>
22957
22958 PR sanitizer/82183
22959 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
22960
22961 2018-02-19 Martin Liska <mliska@suse.cz>
22962 Richard Sandiford <richard.sandiford@linaro.org>
22963
22964 PR tree-optimization/82491
22965 * gimple-fold.c (get_base_constructor): Make earlier bail out
22966 to prevent ubsan.
22967
22968 2018-02-19 Carl Love <cel@us.ibm.com>
22969
22970 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
22971 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
22972 BU_P8V_OVERLOAD_1.
22973 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
22974 P8V_BUILTIN_VEC_NEG.
22975
22976 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
22977
22978 * config/rl78/rl78.md (movdf): New define expand.
22979
22980 2018-02-19 Martin Liska <mliska@suse.cz>
22981
22982 PR other/80589
22983 * doc/invoke.texi: Fix typo.
22984 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
22985
22986 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
22987
22988 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
22989 handle rs6000_single_float and rs6000_double_float specially for
22990 e500 family CPUs.
22991
22992 2018-02-16 Jeff Law <law@redhat.com>
22993
22994 * config/rx/rx.c (add_pop_cfi_notes): New function.;
22995 (pop_regs): Use it.
22996
22997 2018-02-16 Jakub Jelinek <jakub@redhat.com>
22998
22999 PR ipa/84425
23000 * ipa-inline.c (inline_small_functions): Fix a typo.
23001
23002 2018-02-16 Nathan Sidwell <nathan@acm.org>
23003
23004 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
23005
23006 2018-02-16 Carl Love <cel@us.ibm.com>
23007
23008 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
23009 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
23010 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
23011 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
23012 expansion to P8V_BUILTIN_VEC_FLOAT2.
23013
23014 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
23015
23016 PR rtl-optimization/70023
23017 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
23018 src_regno into account.
23019
23020 2018-02-16 Carl Love <cel@us.ibm.com>
23021
23022 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
23023 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
23024 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
23025 * config/rs6000/rs6000.c: Remove case statements for
23026 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
23027 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
23028 and P9V_BUILTIN_VEC_VINSERT4B.
23029 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
23030 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
23031 * config/rs6000/vsx.md:
23032 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
23033 vec_insert4b.
23034
23035 2018-02-16 Carl Love <cel@us.ibm.com>
23036
23037 * config/rs6000/altivec.h: Add builtin names vec_extract4b
23038 vec_insert4b.
23039 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
23040 definitions.
23041 * config/rs6000/rs6000-c.c: Add the definitions for
23042 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
23043 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
23044 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
23045 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
23046 definition for insert4b and define insn *insert3b_internal.
23047 * doc/extend.texi: Add documentation for vec_extract4b.
23048
23049 2018-02-16 Nathan Sidwell <nathan@acm.org>
23050
23051 * doc/extend.texi (Backwards Compatibility): Mention friend
23052 injection. Note for-scope is deprecated.
23053 * doc/invoke.texi (-ffriend-injection): Deprecate.
23054
23055 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
23056
23057 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
23058 that moved to I2, also allow destinations that are a paradoxical
23059 subreg (instead of a normal reg).
23060
23061 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
23062
23063 PR target/83831
23064 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
23065 to QImode.
23066
23067 2018-02-16 Richard Biener <rguenther@suse.de>
23068
23069 PR tree-optimization/84037
23070 PR tree-optimization/84016
23071 PR target/82862
23072 * config/i386/i386.c (ix86_builtin_vectorization_cost):
23073 Adjust vec_construct for the fact we need additional higher latency
23074 128bit inserts for AVX256 and AVX512 vector builds.
23075 (ix86_add_stmt_cost): Scale vector construction cost for
23076 elementwise loads.
23077
23078 2018-02-16 Richard Biener <rguenther@suse.de>
23079
23080 PR tree-optimization/84417
23081 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
23082 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
23083 (non_rewritable_lvalue_p): Likewise, use poly-ints.
23084
23085 2018-02-16 Martin Liska <mliska@suse.cz>
23086
23087 PR sanitizer/84307
23088 * internal-fn.def (ASAN_CHECK): Set proper flags.
23089 (ASAN_MARK): Likewise.
23090
23091 2018-02-16 Julia Koval <julia.koval@intel.com>
23092
23093 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
23094 from PTA_CANNONLAKE.
23095
23096 2018-02-16 Jakub Jelinek <jakub@redhat.com>
23097
23098 PR target/84272
23099 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
23100 Use ++iter rather than iter++ for std::list iterators.
23101 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
23102 defer deleting them until all nodes in the forest are processed. Do
23103 free even leaf nodes. Change to_process into auto_vec.
23104
23105 PR bootstrap/84405
23106 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
23107 * vec.h (vec_default_construct): Use memset instead of placement new
23108 if BROKEN_VALUE_INITIALIZATION is defined.
23109 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
23110 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
23111 is defined.
23112
23113 PR rtl-optimization/83723
23114 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
23115 * lra.c (lra_substitute_pseudo): Likewise. If true, use
23116 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
23117 recursive calls.
23118 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
23119 callers.
23120 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
23121
23122 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
23123
23124 PR rtl-optimization/81443
23125 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
23126 from inner REGs to paradoxical SUBREGs.
23127
23128 2018-02-16 Richard Biener <rguenther@suse.de>
23129
23130 PR tree-optimization/84399
23131 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
23132 For operands we can analyze at their definition make sure we can
23133 analyze them at each use as well.
23134
23135 2018-02-16 Richard Biener <rguenther@suse.de>
23136
23137 PR tree-optimization/84190
23138 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
23139 volatile accesses if the decl isn't volatile.
23140
23141 2018-02-15 Jason Merrill <jason@redhat.com>
23142
23143 PR c++/84314 - ICE with templates and fastcall attribute.
23144 * attribs.c (build_type_attribute_qual_variant): Don't clobber
23145 TYPE_CANONICAL on an existing type.
23146
23147 2018-02-15 Jakub Jelinek <jakub@redhat.com>
23148
23149 PR tree-optimization/84383
23150 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
23151 dstoff nor call operand_equal_p if dstbase is NULL.
23152
23153 PR tree-optimization/84334
23154 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
23155 also a CONSTANT_CLASS_P, punt.
23156
23157 2018-02-14 Jim Wilson <jimw@sifive.com>
23158
23159 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
23160 first SMALL_OPERAND check. New local min_second_step. Move assert
23161 to where locals are set. Add TARGET_RVC support.
23162 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
23163
23164 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
23165
23166 * doc/invoke.texi: Correct -Wformat-overflow code sample.
23167
23168 2018-02-14 Martin Sebor <msebor@redhat.com>
23169
23170 PR tree-optimization/83698
23171 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
23172 arrays constrain the offset range to their bounds.
23173 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
23174 (builtin_access::overlap): Avoid setting the size of overlap if it's
23175 already been set.
23176 (maybe_diag_overlap): Also consider arrays when deciding what values
23177 of offsets to include in diagnostics.
23178
23179 2018-02-14 Martin Sebor <msebor@redhat.com>
23180
23181 PR c/84108
23182 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
23183 that correspond to the kind of a declaration.
23184
23185 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
23186
23187 PR target/83984
23188 * config/pa/pa.md: Load address of PIC label using the linkage table
23189 if the label is nonlocal.
23190
23191 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
23192
23193 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
23194 warning message if user requests -maltivec=be.
23195 * doc/invoke.texi: Document deprecation of -maltivec=be.
23196
23197 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
23198
23199 PR target/84220
23200 * config/rs6000/rs6000-c.c: Update definitions for
23201 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
23202 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
23203
23204 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
23205
23206 PR target/84239
23207 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
23208 add _get_ssp intrinsics. Remove argument from
23209 __builtin_ia32_rdssp[d|q].
23210 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
23211 * config/i386/i386-builtin.def: Remove argument from
23212 __builtin_ia32_rdssp[d|q].
23213 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
23214 ix86_expand_special_args_builtin for _rdssp[d|q].
23215 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
23216 Clear register before usage.
23217 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
23218 Add documentation for new _get_ssp and _inc_ssp intrinsics.
23219
23220 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
23221
23222 PR tree-optimization/84357
23223 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
23224 operand 1 of an ARRAY_REF too.
23225
23226 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
23227
23228 PR target/83831
23229 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
23230 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23231 declarations.
23232 (set_of_reg): New struct.
23233 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
23234 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
23235 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23236 functions.
23237 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
23238 Split into bitclr, bitset, bitinvert patterns if appropriate.
23239 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
23240 use rx_fuse_in_memory_bitop.
23241 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
23242 to named insn, correct maximum insn length.
23243
23244 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
23245
23246 PR target/79242
23247 * machmode.def: Define a complex mode for PARTIAL_INT.
23248 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
23249 MODE_PARTIAL_INT.
23250 * doc/rtl.texi: Document CSPImode.
23251 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
23252 handling.
23253 (msp430_hard_regno_nregs_with_padding): Likewise.
23254
23255 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
23256
23257 PR target/84279
23258 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
23259
23260 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
23261
23262 PR rtl-optimization/84169
23263 * combine.c (try_combine): New variable split_i2i3. Set it to true if
23264 we generated a parallel as new i3 and we split that to new i2 and i3
23265 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
23266 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
23267 those to i2, not i1. Partially rewrite this scan code.
23268
23269 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23270
23271 PR c/82210
23272 * stor-layout.c (place_field): For variable length fields, adjust
23273 offset_align afterwards not just based on the field's alignment,
23274 but also on the size.
23275
23276 PR middle-end/84309
23277 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
23278 of exps and logs in the use_exp2 case.
23279
23280 2018-02-13 Jeff Law <law@redhat.com>
23281
23282 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
23283 entry for "vector".
23284
23285 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
23286 ARGS as unused.
23287
23288 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
23289
23290 PR debug/84342
23291 PR debug/84319
23292 * common.opt (gas-loc-support, gas-locview-support): New.
23293 (ginline-points, ginternal-reset-location-views): New.
23294 * doc/invoke.texi: Document them. Use @itemx where intended.
23295 (gvariable-location-views): Adjust.
23296 * target.def (reset_location_view): New.
23297 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
23298 (TARGET_RESET_LOCATION_VIEW): New.
23299 * doc/tm.texi: Rebuilt.
23300 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
23301 (dwarf2out_default_as_locview_support): New.
23302 (output_asm_line_debug_info): Use option variables.
23303 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
23304 (output_loc_list): Likewise.
23305 (add_high_low_attributes): Check option variables.
23306 Don't output entry view attribute in strict mode.
23307 (gen_inlined_subroutine_die): Check option variables.
23308 (dwarf2out_inline_entry): Likewise.
23309 (init_sections_and_labels): Likewise.
23310 (dwarf2out_early_finish): Likewise.
23311 (maybe_reset_location_view): New, from...
23312 (dwarf2out_var_location): ... here. Call it.
23313 * debug.h (dwarf2out_default_as_loc_support): Declare.
23314 (dwarf2out_default_as_locview_support): Declare.
23315 * hooks.c (hook_int_rtx_insn_0): New.
23316 * hooks.h (hook_int_rtx_insn_0): Declare.
23317 * toplev.c (process_options): Take -gas-loc-support and
23318 -gas-locview-support from dwarf2out. Enable
23319 -gvariable-location-views by default only with locview
23320 assembler support. Enable -ginternal-reset-location-views by
23321 default only if the target defines the corresponding hook.
23322 Enable -ginline-points by default if location views are
23323 enabled; force it disabled if statement frontiers are
23324 disabled.
23325 * tree-inline.c (expand_call_inline): Check option variables.
23326 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
23327
23328 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
23329
23330 PR tree-optimization/84321
23331 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
23332 handling. Also check whether the anti-range contains any values
23333 that satisfy the mask; switch to a VR_RANGE if not.
23334
23335 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
23336
23337 PR sanitizer/84340
23338 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
23339
23340 2018-02-13 Martin Jambor <mjambor@suse.cz>
23341
23342 PR c++/83990
23343 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
23344 of call statements, also set location of a load to a temporary.
23345
23346 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
23347
23348 * config/rl78/rl78.c (add_vector_labels): New function.
23349 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
23350 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
23351 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
23352 which checks that no arguments are passed.
23353 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
23354 * doc/extend.texi: Documentation for the new attribute.
23355
23356 2018-02-13 Andreas Schwab <schwab@suse.de>
23357
23358 * config/riscv/linux.h (CPP_SPEC): Define.
23359
23360 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23361
23362 PR target/84335
23363 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
23364 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
23365 OPTION_MASK_ISA_AES as first argument to def_builtin_const
23366 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
23367 instead of OPTION_MASK_ISA_PCLMUL as first argument to
23368 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
23369 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
23370 temporarily for AES and PCLMUL builtins.
23371
23372 PR tree-optimization/84339
23373 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
23374 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
23375 Formatting fixes.
23376
23377 PR middle-end/84309
23378 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
23379 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
23380 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
23381 inline function.
23382 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
23383 inline function.
23384 * omp-simd-clone.h: New file.
23385 * omp-simd-clone.c: Include omp-simd-clone.h.
23386 (expand_simd_clones): No longer static.
23387 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
23388 cgraph.h and omp-simd-clone.h.
23389 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
23390 (vect_recog_widen_shift_pattern): Formatting fix.
23391 (vect_pattern_recog_1): Don't check optab for calls.
23392
23393 PR target/84336
23394 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
23395 operands[2] into a REG before using gen_lowpart on it.
23396
23397 2018-02-12 Jeff Law <law@redhat.com>
23398
23399 PR target/83760
23400 * config/sh/sh.c (find_barrier): Consider a sibling call
23401 a barrier as well.
23402
23403 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
23404 successfully back substituting a reg.
23405
23406 2018-02-12 Richard Biener <rguenther@suse.de>
23407
23408 PR tree-optimization/84037
23409 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
23410 parameter, move visited init to caller.
23411 (vect_slp_analyze_operations): Separate cost from validity
23412 check, initialize visited once for all instances.
23413 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
23414 for all instances.
23415 * tree-vect-stmts.c (vect_model_simple_cost): Make early
23416 out an assert.
23417 (vect_model_promotion_demotion_cost): Likewise.
23418 (vectorizable_bswap): Guard cost modeling with !slp_node
23419 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
23420 SLP stmts.
23421 (vectorizable_call): Likewise.
23422 (vectorizable_conversion): Likewise.
23423 (vectorizable_assignment): Likewise.
23424 (vectorizable_shift): Likewise.
23425 (vectorizable_operation): Likewise.
23426 (vectorizable_store): Likewise.
23427 (vectorizable_load): Likewise.
23428 (vectorizable_condition): Likewise.
23429 (vectorizable_comparison): Likewise.
23430
23431 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
23432
23433 PR sanitizer/84307
23434 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
23435 (ASAN_MARK): Fix fnspec to account for return value, change pointer
23436 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
23437
23438 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23439
23440 PR middle-end/83665
23441 * params.def (inline-min-speedup): Increase from 8 to 15.
23442 (max-inline-insns-auto): Decrease from 40 to 30.
23443 * ipa-split.c (consider_split): Add some buffer for function to
23444 be considered inlining candidate.
23445 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
23446 default values.
23447
23448 2018-02-12 Richard Biener <rguenther@suse.de>
23449
23450 PR tree-optimization/84037
23451 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
23452 matched stmts if we cannot swap the non-matched ones.
23453
23454 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23455
23456 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
23457 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
23458 _mm_maskz_scalef_round_ss): New intrinsics.
23459 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
23460 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
23461 __builtin_ia32_scalefss_round): Remove.
23462 (__builtin_ia32_scalefsd_mask_round,
23463 __builtin_ia32_scalefss_mask_round): New intrinsics.
23464 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
23465 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
23466 ((match_operand:VF_128 2 "<round_nimm_predicate>"
23467 "<round_constraint>")): Changed to ...
23468 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
23469 "<round_scalar_constraint>")): ... this.
23470 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
23471 %0, %1, %2<round_op3>}"): Changed to ...
23472 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
23473 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
23474 %2<round_scalar_mask_op3>}"): ... this.
23475 * config/i386/subst.md (round_scalar_nimm_predicate): New.
23476
23477 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23478
23479 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
23480 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
23481 (_mm_maskz_sqrt_round_ss): New intrinsics.
23482 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
23483 (__builtin_ia32_sqrtsd_mask_round)
23484 (__builtin_ia32_sqrtss_mask_round): New builtins.
23485 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
23486 (__builtin_ia32_sqrtss_round): Remove.
23487 (__builtin_ia32_sqrtsd_mask_round)
23488 (__builtin_ia32_sqrtss_mask_round): New builtins.
23489 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
23490 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
23491 ((match_operand:VF_128 1 "vector_operand"
23492 "xBm,<round_constraint>")): Changed to ...
23493 ((match_operand:VF_128 1 "vector_operand"
23494 "xBm,<round_scalar_constraint>")): ... this.
23495 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
23496 %0, %2, %<iptr>1<round_op3>}): Changed to ...
23497 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
23498 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
23499 %<iptr>1<round_scalar_mask_op3>}): ... this.
23500 ((set_attr "prefix" "<round_prefix>")): Changed to ...
23501 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
23502
23503 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
23504
23505 PR target/84266
23506 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
23507 Cast vec_cmpeq result to correct type.
23508 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
23509 Cast vec_cmpgt result to correct type.
23510
23511 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
23512
23513 * final.c (final_scan_insn_1): Renamed from...
23514 (final_scan_insn): ... this. New wrapper, to recover
23515 seen from the outermost call in recursive ones.
23516 * config/sparc/sparc.c (output_return): Drop seen from call.
23517 (output_sibcall): Likewise.
23518 * config/visium/visium.c (output_branch): Likewise.
23519
23520 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
23521
23522 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
23523 function label.
23524
23525 2018-02-10 Alan Modra <amodra@gmail.com>
23526
23527 PR target/84300
23528 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
23529 Specify LR as an input.
23530
23531 2018-02-10 Jakub Jelinek <jakub@redhat.com>
23532
23533 PR sanitizer/83987
23534 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
23535 remove_member_access_dummy_vars): New functions.
23536 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
23537 lower_omp_1, execute_lower_omp): Use them.
23538
23539 PR rtl-optimization/84308
23540 * shrink-wrap.c (spread_components): Release todo vector.
23541
23542 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
23543
23544 PR rtl-optimization/57193
23545 * ira-color.c (struct allocno_color_data): Add member
23546 conflict_allocno_hard_prefs.
23547 (update_conflict_allocno_hard_prefs): New.
23548 (bucket_allocno_compare_func): Add a preference based on
23549 conflict_allocno_hard_prefs.
23550 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
23551 (color_allocnos): Remove a dead code. Initiate
23552 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
23553
23554 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23555
23556 PR target/84226
23557 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
23558 constraint from =wa to wa. Avoid a subreg on the output operand,
23559 instead use a pseudo and subreg it in a move.
23560 (p9_xxbrd_<mode>): Changed to ...
23561 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
23562 (p9_xxbrd_v2df): New expander.
23563 (p9_xxbrw_<mode>): Changed to ...
23564 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
23565 (p9_xxbrw_v4sf): New expander.
23566
23567 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23568
23569 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
23570
23571 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
23572
23573 PR target/83926
23574 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
23575 multiply in 32-bit mode.
23576 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
23577 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
23578 mode.
23579
23580 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23581
23582 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
23583 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
23584 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
23585 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
23586
23587 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
23588
23589 PR lto/84213
23590 * dwarf2out.c (is_trivial_indirect_ref): New function.
23591 (dwarf2out_late_global_decl): Do not generate a location
23592 attribute for variables that have a non-trivial DECL_VALUE_EXPR
23593 and that are not defined in the current unit.
23594
23595 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23596
23597 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
23598 instead of a libcall for UNORDERED.
23599
23600 2018-02-09 Tamar Christina <tamar.christina@arm.com>
23601
23602 PR target/82641
23603 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
23604 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
23605
23606 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23607
23608 PR target/PR84295
23609 * config/s390/s390.c (s390_set_current_function): Invoke
23610 s390_indirect_branch_settings also if fndecl didn't change.
23611
23612 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23613
23614 * config/rs6000/rs6000.md (blockage): Set length to zero.
23615
23616 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23617
23618 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
23619
23620 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23621
23622 PR sanitizer/84285
23623 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
23624 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
23625 -static-lib*san.
23626
23627 PR debug/84252
23628 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
23629 PARALLEL incoming that failed vt_get_decl_and_offset check.
23630
23631 PR middle-end/84237
23632 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
23633 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
23634 TREE_READONLY bit.
23635 (get_variable_section): For decls in named .bss* sections pass true as
23636 second argument to bss_initializer_p.
23637
23638 2018-02-09 Marek Polacek <polacek@redhat.com>
23639 Jakub Jelinek <jakub@redhat.com>
23640
23641 PR c++/83659
23642 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
23643 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
23644 Sync some changes from cxx_fold_indirect_ref.
23645
23646 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23647
23648 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
23649 markers.
23650 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
23651 (BLOCK_INLINE_ENTRY_LABEL): New.
23652 (dwarf2out_var_location): Disregard inline entry markers.
23653 (inline_entry_data): New struct.
23654 (inline_entry_data_hasher): New hashtable type.
23655 (inline_entry_data_hasher::hash): New.
23656 (inline_entry_data_hasher::equal): New.
23657 (inline_entry_data_table): New variable.
23658 (add_high_low_attributes): Add DW_AT_entry_pc and
23659 DW_AT_GNU_entry_view attributes if a pending entry is found
23660 in inline_entry_data_table. Add old entry_pc attribute only
23661 if debug nonbinding markers are disabled.
23662 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
23663 markers are enabled.
23664 (block_within_block_p, dwarf2out_inline_entry): New.
23665 (dwarf2out_finish): Check that no entries remained in
23666 inline_entry_data_table.
23667 * final.c (reemit_insn_block_notes): Handle inline entry notes.
23668 (final_scan_insn, notice_source_line): Likewise.
23669 (rest_of_clean_state): Skip inline entry markers.
23670 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
23671 markers.
23672 * gimple.c (gimple_build_debug_inline_entry): New.
23673 * gimple.h (enum gimple_debug_subcode): Add
23674 GIMPLE_DEBUG_INLINE_ENTRY.
23675 (gimple_build_debug_inline_entry): Declare.
23676 (gimple_debug_inline_entry_p): New.
23677 (gimple_debug_nonbind_marker_p): Adjust.
23678 * insn-notes.def (INLINE_ENTRY): New.
23679 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
23680 inline entry marker notes.
23681 (print_insn): Likewise.
23682 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
23683 (INSN_DEBUG_MARKER_KIND): Likewise.
23684 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
23685 * tree-inline.c (expand_call_inline): Build and insert
23686 debug_inline_entry stmt.
23687 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
23688 inline entry blocks early, if nonbind markers are enabled.
23689 (dump_scope_block): Dump fragment info.
23690 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
23691 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
23692 (gimple_build_debug_inline_entry): New.
23693 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
23694 Enable/disable inline entry points too.
23695 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
23696 (DEBUG_INSN): Describe inline entry markers.
23697
23698 * common.opt (gvariable-location-views): New.
23699 (gvariable-location-views=incompat5): New.
23700 * config.in: Rebuilt.
23701 * configure: Rebuilt.
23702 * configure.ac: Test assembler for view support.
23703 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
23704 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
23705 * dwarf2out.c (var_loc_view): New typedef.
23706 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
23707 (dwarf2out_locviews_in_attribute): New.
23708 (dwarf2out_locviews_in_loclist): New.
23709 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
23710 (enum dw_line_info_opcode): Add LI_adv_address.
23711 (struct dw_line_info_table): Add view.
23712 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
23713 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
23714 (zero_view_p): New variable.
23715 (ZERO_VIEW_P): New macro.
23716 (output_asm_line_debug_info): New.
23717 (struct var_loc_node): Add view.
23718 (add_AT_view_list, AT_loc_list): New.
23719 (add_var_loc_to_decl): Add view param. Test it against last.
23720 (new_loc_list): Add view params. Record them.
23721 (AT_loc_list_ptr): Handle loc and view lists.
23722 (view_list_to_loc_list_val_node): New.
23723 (print_dw_val): Handle dw_val_class_view_list.
23724 (size_of_die): Likewise.
23725 (value_format): Likewise.
23726 (loc_list_has_views): New.
23727 (gen_llsym): Set vl_symbol too.
23728 (maybe_gen_llsym, skip_loc_list_entry): New.
23729 (dwarf2out_maybe_output_loclist_view_pair): New.
23730 (output_loc_list): Output view list or entries too.
23731 (output_view_list_offset): New.
23732 (output_die): Handle dw_val_class_view_list.
23733 (output_dwarf_version): New.
23734 (output_compilation_unit_header): Use it.
23735 (output_skeleton_debug_sections): Likewise.
23736 (output_rnglists, output_line_info): Likewise.
23737 (output_pubnames, output_aranges): Update version comments.
23738 (output_one_line_info_table): Output view numbers in asm comments.
23739 (dw_loc_list): Determine current endview, pass it to new_loc_list.
23740 Call maybe_gen_llsym.
23741 (loc_list_from_tree_1): Adjust.
23742 (add_AT_location_description): Create view list attribute if
23743 needed, check it's absent otherwise.
23744 (convert_cfa_to_fb_loc_list): Adjust.
23745 (maybe_emit_file): Call output_asm_line_debug_info for test.
23746 (dwarf2out_var_location): Reset views as needed. Precompute
23747 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
23748 attribute. Set view.
23749 (new_line_info_table): Reset next view.
23750 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
23751 (dwarf2out_source_line): Likewise. Output view resets and labels to
23752 the assembler, or select appropriate line info opcodes.
23753 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
23754 (optimize_string_length): Catch it. Adjust.
23755 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
23756 dw_val_class_view_list, and remove it if no longer needed.
23757 (hash_loc_list): Hash view numbers.
23758 (loc_list_hasher::equal): Compare them.
23759 (optimize_location_lists): Check whether a view list symbol is
23760 needed, and whether the locview attribute is present, and
23761 whether they match. Remove the locview attribute if no longer
23762 needed.
23763 (index_location_lists): Call skip_loc_list_entry for test.
23764 (dwarf2out_finish): Call output_asm_line_debug_info for test.
23765 Use output_dwarf_version.
23766 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
23767 (struct dw_val_node): Add val_view_list.
23768 * final.c (SEEN_NEXT_VIEW): New.
23769 (set_next_view_needed): New.
23770 (clear_next_view_needed): New.
23771 (maybe_output_next_view): New.
23772 (final_start_function): Rename to...
23773 (final_start_function_1): ... this. Take pointer to FIRST,
23774 add SEEN parameter. Emit param bindings in the initial view.
23775 (final_start_function): Reintroduce SEEN-less interface.
23776 (final): Rename to...
23777 (final_1): ... this. Take SEEN parameter. Output final pending
23778 next view at the end.
23779 (final): Reintroduce seen-less interface.
23780 (final_scan_insn): Output pending next view before switching
23781 sections or ending a block. Mark the next view as needed when
23782 outputting variable locations. Notify debug backend of section
23783 changes, and of location view changes.
23784 (rest_of_handle_final): Adjust.
23785 * toplev.c (process_options): Autodetect value for debug variable
23786 location views option. Warn on incompat5 without -gdwarf-5.
23787 * doc/invoke.texi (gvariable-location-views): New.
23788 (gvariable-location-views=incompat5): New.
23789 (gno-variable-location-views): New.
23790
23791 2018-02-08 David Malcolm <dmalcolm@redhat.com>
23792
23793 PR tree-optimization/84136
23794 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
23795 that the result of find_edge is non-NULL.
23796
23797 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23798
23799 PR target/83008
23800 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
23801 storing integer register in SImode. Fix cost of 256 and 512
23802 byte aligned SSE register store.
23803
23804 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23805
23806 * config/i386/i386.c (ix86_multiplication_cost): Fix
23807 multiplication cost for TARGET_AVX512DQ.
23808
23809 2018-02-08 Marek Polacek <polacek@redhat.com>
23810
23811 PR tree-optimization/84238
23812 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
23813 get_range_strlen.
23814
23815 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23816
23817 PR tree-optimization/84265
23818 * tree-vect-stmts.c (vectorizable_store): Don't treat
23819 VMAT_CONTIGUOUS accesses as grouped.
23820 (vectorizable_load): Likewise.
23821
23822 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23823
23824 PR tree-optimization/81635
23825 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
23826 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
23827 (test_round_for_mask): New functions.
23828 (wide_int_cc_tests): Call test_round_for_mask.
23829 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
23830 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
23831 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
23832 range returned by get_range_info.
23833
23834 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23835
23836 PR ipa/81360
23837 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
23838 * symtab.c: Include builtins.h
23839 (symtab_node::output_to_lto_symbol_table_p): Move here
23840 from lto-streamer-out.c:output_symbol_p.
23841 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
23842 (output_symbol_p): Move all logic to symtab.c
23843 (produce_symtab): Update.
23844
23845 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23846
23847 * config/s390/s390-opts.h (enum indirect_branch): Define.
23848 * config/s390/s390-protos.h (s390_return_addr_from_memory)
23849 (s390_indirect_branch_via_thunk)
23850 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
23851 (enum s390_indirect_branch_type): Define.
23852 * config/s390/s390.c (struct s390_frame_layout, struct
23853 machine_function): Remove.
23854 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
23855 (indirect_branch_table_label_no, indirect_branch_table_name):
23856 Define variables.
23857 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
23858 (enum s390_indirect_branch_option): Define.
23859 (s390_return_addr_from_memory): New function.
23860 (s390_handle_string_attribute): New function.
23861 (s390_attribute_table): Add new attribute handler.
23862 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
23863 (s390_indirect_branch_via_thunk): New function.
23864 (s390_indirect_branch_via_inline_thunk): New function.
23865 (s390_function_ok_for_sibcall): When jumping via thunk disallow
23866 sibling call optimization for non z10 compiles.
23867 (s390_emit_call): Force indirect branch target to be a single
23868 register. Add r1 clobber for non-z10 compiles.
23869 (s390_emit_epilogue): Emit return jump via return_use expander.
23870 (s390_reorg): Handle JUMP_INSNs as execute targets.
23871 (s390_option_override_internal): Perform validity checks for the
23872 new command line options.
23873 (s390_indirect_branch_attrvalue): New function.
23874 (s390_indirect_branch_settings): New function.
23875 (s390_set_current_function): Invoke s390_indirect_branch_settings.
23876 (s390_output_indirect_thunk_function): New function.
23877 (s390_code_end): Implement target hook.
23878 (s390_case_values_threshold): Implement target hook.
23879 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
23880 macros.
23881 * config/s390/s390.h (struct s390_frame_layout)
23882 (struct machine_function): Move here from s390.c.
23883 (TARGET_INDIRECT_BRANCH_NOBP_RET)
23884 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
23885 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
23886 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
23887 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
23888 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
23889 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
23890 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
23891 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
23892 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
23893 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
23894 (mnemonic attribute): Add values which aren't recognized
23895 automatically.
23896 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
23897 pattern for branch conversion. Fix mnemonic attribute.
23898 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
23899 indirect branch via thunk if requested.
23900 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
23901 ("*indirect_jump"): Disable for branch conversion using out of
23902 line thunks.
23903 ("indirect_jump_via_thunk<mode>_z10")
23904 ("indirect_jump_via_thunk<mode>")
23905 ("indirect_jump_via_inlinethunk<mode>_z10")
23906 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
23907 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
23908 ("casesi_jump_via_inlinethunk<mode>_z10")
23909 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
23910 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
23911 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
23912 ("*indirect2_jump"): Disable for branch conversion.
23913 ("casesi_jump"): Turn into expander and expand patterns for branch
23914 conversion.
23915 ("return_use"): New expander.
23916 ("*return"): Emit return via thunk and rename it to ...
23917 ("*return<mode>"): ... this one.
23918 * config/s390/s390.opt: Add new options and and enum for the
23919 option values.
23920
23921 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23922
23923 * lra-constraints.c (match_reload): Unconditionally use
23924 gen_lowpart_SUBREG, rather than selecting between that
23925 and equivalent gen_rtx_SUBREG code.
23926
23927 2018-02-08 Richard Biener <rguenther@suse.de>
23928
23929 PR tree-optimization/84233
23930 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
23931 changed flag instead of boguously re-using phi_inserted.
23932
23933 2018-02-08 Martin Jambor <mjambor@suse.cz>
23934
23935 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
23936 static local variables.
23937
23938 2018-02-08 Richard Biener <rguenther@suse.de>
23939
23940 PR tree-optimization/84278
23941 * tree-vect-stmts.c (vectorizable_store): When looking for
23942 smaller vector types to perform grouped strided loads/stores
23943 make sure the mode is supported by the target.
23944 (vectorizable_load): Likewise.
23945
23946 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23947
23948 * config/aarch64/aarch64.c (aarch64_components_for_bb):
23949 Increase LDP/STP opportunities by adding adjacent callee-saves.
23950
23951 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23952
23953 PR rtl-optimization/84068
23954 PR rtl-optimization/83459
23955 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
23956
23957 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
23958
23959 PR tree-optimization/84224
23960 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
23961 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
23962 non-zero arguments.
23963
23964 2018-02-07 Iain Sandoe <iain@codesourcery.com>
23965
23966 PR target/84113
23967 * config/rs6000/altivec.md (*restore_world): Remove LR use.
23968 * config/rs6000/predicates.md (restore_world_operation): Adjust op
23969 count, remove one USE.
23970
23971 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
23972
23973 * doc/install.texi (Configuration): Document the
23974 --with-long-double-format={ibm,ieee} PowerPC configuration
23975 options.
23976
23977 PR target/84154
23978 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
23979 Convert from define_expand to be define_insn_and_split. Rework
23980 float/double/_Float128 conversions to QI/HI/SImode to work with
23981 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
23982 conversions to QI/HImode types did a store and then a load to
23983 truncate the value. For conversions to VSX registers, don't split
23984 the insn, instead emit the code directly. Use the code iterator
23985 any_fix to combine signed and unsigned conversions.
23986 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
23987 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
23988 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23989 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
23990 (fix_<mode>di2_hw): Likewise.
23991 (fixuns_<mode>di2_hw): Likewise.
23992 (fix_<mode>si2_hw): Likewise.
23993 (fixuns_<mode>si2_hw): Likewise.
23994 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
23995 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23996 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
23997 fix<uns>_trunc<SFDF:mode>si2_p8.
23998 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
23999 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
24000 (fix<uns>_<mode>_mem): Likewise.
24001 (fctiw<u>z_<mode>_mem): Likewise.
24002 (fix<uns>_<mode>_mem): Likewise.
24003 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
24004 the register allocator from doing a direct move to the GPRs to do
24005 a store, and instead use the ISA 3.0 store byte/half-word from
24006 vector register instruction. For IEEE 128-bit floating point,
24007 also optimize stores of 32-bit ints.
24008 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
24009
24010 2018-02-07 Alan Hayward <alan.hayward@arm.com>
24011
24012 * genextract.c (push_pathstr_operand): New function to support
24013 [a-zA-Z].
24014 (walk_rtx): Call push_pathstr_operand.
24015 (print_path): Support [a-zA-Z].
24016
24017 2018-02-07 Richard Biener <rguenther@suse.de>
24018
24019 PR tree-optimization/84037
24020 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
24021 (cse_and_gimplify_to_preheader): Declare.
24022 (vect_get_place_in_interleaving_chain): Likewise.
24023 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
24024 ivexpr_map.
24025 (_loop_vec_info::~_loop_vec_info): Delete it.
24026 (cse_and_gimplify_to_preheader): New function.
24027 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
24028 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
24029 (vectorizable_load): Likewise. For grouped stores always base
24030 the IV on the first element.
24031 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
24032 condition before gimplifying.
24033
24034 2018-02-07 Jakub Jelinek <jakub@redhat.com>
24035
24036 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
24037 *DIV_EXPR and *MOD_EXPR.
24038
24039 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
24040
24041 PR target/84248
24042 * config/i386/i386.c (ix86_option_override_internal): Mask out
24043 the CF_SET bit when checking -fcf-protection.
24044
24045 2018-02-07 Tom de Vries <tom@codesourcery.com>
24046
24047 PR libgomp/84217
24048 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
24049 enough.
24050
24051 2018-02-07 Richard Biener <rguenther@suse.de>
24052
24053 PR tree-optimization/84204
24054 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
24055 this place.
24056
24057 PR tree-optimization/84205
24058 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
24059 special-case isl_ast_op_zdiv_r.
24060
24061 PR tree-optimization/84223
24062 * graphite-scop-detection.c (gather_bbs::before_dom_children):
24063 Only add conditions from within the region.
24064 (gather_bbs::after_dom_children): Adjust.
24065
24066 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
24067
24068 PR target/84209
24069 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
24070 * config/avr/avr.md: Only post-reload split REG-REG moves if
24071 either register is GENERAL_REG_P.
24072
24073 2018-02-07 Jakub Jelinek <jakub@redhat.com>
24074
24075 PR tree-optimization/84235
24076 * tree-ssa-scopedtables.c
24077 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
24078 if the subtraction is performed in floating point type where NaNs are
24079 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
24080 build 1. Formatting fix.
24081
24082 2018-02-06 Jakub Jelinek <jakub@redhat.com>
24083
24084 PR target/84146
24085 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
24086 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
24087 and skip it regardless of bb boundaries. Use CALL_P macro,
24088 don't test INSN_P (insn) together with CALL_P or JUMP_P check
24089 unnecessarily, formatting fix.
24090
24091 2018-02-06 Michael Collison <michael.collison@arm.com>
24092
24093 * config/arm/thumb2.md:
24094 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
24095 (*thumb_mov_notscc): Ditto.
24096
24097 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
24098
24099 PR target/84154
24100 * config/rs6000/rs6000.md (su code attribute): Use "u" for
24101 unsigned_fix, not "s".
24102
24103 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24104
24105 * configure.ac (gcc_fn_eh_frame_ro): New function.
24106 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
24107 correct .eh_frame permissions.
24108 * configure: Regenerate.
24109
24110 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
24111
24112 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
24113 irrelevant options.
24114
24115 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24116
24117 * config/rs6000/rs6000.c (rs6000_option_override_internal):
24118 Display warning message for -mno-speculate-indirect-jumps.
24119
24120 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
24121
24122 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
24123 Undocumented.
24124 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
24125
24126 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
24127
24128 PR tree-optimization/84225
24129 * tree-eh.c (find_trapping_overflow): Only call
24130 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
24131
24132 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24133
24134 PR target/84145
24135 * config/i386/i386.c: Reimplement the check of possible options
24136 -mibt/-mshstk conbination. Change error messages.
24137 * doc/invoke.texi: Fix a typo: remove extra '='.
24138
24139 2018-02-06 Marek Polacek <polacek@redhat.com>
24140
24141 PR tree-optimization/84228
24142 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
24143
24144 2018-02-06 Tamar Christina <tamar.christina@arm.com>
24145
24146 PR target/82641
24147 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
24148 emitted arch directives.
24149 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
24150 __ARM_FEATURE_COPROC before changing architectures.
24151
24152 2018-02-06 Richard Biener <rguenther@suse.de>
24153
24154 * config/i386/i386.c (print_reg): Fix typo.
24155 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
24156
24157 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
24158
24159 * configure: Regenerate.
24160
24161 2018-02-05 Martin Sebor <msebor@redhat.com>
24162
24163 PR tree-optimization/83369
24164 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
24165 inlining context.
24166
24167 2018-02-05 Martin Liska <mliska@suse.cz>
24168
24169 * doc/invoke.texi: Cherry-pick upstream r323995.
24170
24171 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
24172
24173 * ira.c (ira_init_register_move_cost): Adjust comment.
24174
24175 2018-02-05 Martin Liska <mliska@suse.cz>
24176
24177 PR gcov-profile/84137
24178 * doc/gcov.texi: Fix typo in documentation.
24179
24180 2018-02-05 Martin Liska <mliska@suse.cz>
24181
24182 PR gcov-profile/83879
24183 * doc/gcov.texi: Document necessity of --dynamic-list-data when
24184 using dlopen functionality.
24185
24186 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
24187
24188 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
24189 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
24190 _mm_maskz_range_ss, _mm_mask_range_round_ss,
24191 _mm_maskz_range_round_ss): New intrinsics.
24192 (__builtin_ia32_rangesd128_round)
24193 (__builtin_ia32_rangess128_round): Remove.
24194 (__builtin_ia32_rangesd128_mask_round,
24195 __builtin_ia32_rangess128_mask_round): New builtins.
24196 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
24197 __builtin_ia32_rangess128_round): Remove.
24198 (__builtin_ia32_rangesd128_mask_round,
24199 __builtin_ia32_rangess128_mask_round): New builtins.
24200 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
24201 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
24202 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
24203 "<round_saeonly_constraint>")): Changed to ...
24204 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
24205 "<round_saeonly_scalar_constraint>")): ... this.
24206 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
24207 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
24208 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
24209 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
24210 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
24211
24212 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
24213
24214 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
24215 options.
24216 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
24217 Remove all values except native, 8540 and 8548.
24218
24219 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
24220
24221 * config/i386/i386.c (ix86_output_function_return): Pass
24222 INVALID_REGNUM, instead of -1, as invalid register number to
24223 indirect_thunk_name and output_indirect_thunk.
24224
24225 2018-02-02 Julia Koval <julia.koval@intel.com>
24226
24227 * config.gcc: Add -march=icelake.
24228 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
24229 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
24230 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
24231 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
24232 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
24233 (processor_target_table): Add icelake.
24234 (ix86_option_override_internal): Handle new PTAs.
24235 (get_builtin_code_for_version): Handle icelake.
24236 (M_INTEL_COREI7_ICELAKE): New.
24237 (fold_builtin_cpu): Handle icelake.
24238 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
24239 * doc/invoke.texi: Add -march=icelake.
24240
24241 2018-02-02 Julia Koval <julia.koval@intel.com>
24242
24243 * config/i386/i386.c (ix86_option_override_internal): Change flags type
24244 to wide_int_bitmask.
24245 * wide-int-bitmask.h: New.
24246
24247 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24248
24249 PR target/84066
24250 * config/i386/i386.md: Replace Pmode with word_mode in
24251 builtin_setjmp_setup and builtin_longjmp to support x32.
24252
24253 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
24254
24255 PR target/56010
24256 PR target/83743
24257 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
24258 #include "opts.h".
24259 (rs6000_supported_cpu_names): New static variable.
24260 (linux_cpu_translation_table): Likewise.
24261 (elf_platform) <cpu>: Define new static variable and use it.
24262 Translate kernel AT_PLATFORM name to canonical name if needed.
24263 Error if platform name is unknown.
24264
24265 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
24266
24267 PR target/84089
24268 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
24269
24270 2018-02-01 Jeff Law <law@redhat.com>
24271
24272 PR target/84128
24273 * config/i386/i386.c (release_scratch_register_on_entry): Add new
24274 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
24275 the scratch if RELEASE_VIA_POP is false.
24276 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
24277 If we have to save a temporary register, decrement SIZE appropriately.
24278 Pass new arguments to release_scratch_register_on_entry.
24279 (ix86_adjust_stack_and_probe): Likewise.
24280 (ix86_emit_probe_stack_range): Pass new arguments to
24281 release_scratch_register_on_entry.
24282
24283 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
24284
24285 PR rtl-optimization/84157
24286 * combine.c (change_zero_ext): Use REG_P predicate in
24287 front of HARD_REGISTER_P predicate.
24288
24289 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
24290
24291 * config/avr/avr.c (avr_option_override): Move disabling of
24292 -fdelete-null-pointer-checks to...
24293 * common/config/avr/avr-common.c (avr_option_optimization_table):
24294 ...here.
24295
24296 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24297
24298 PR tree-optimization/81635
24299 * tree-data-ref.c (split_constant_offset_1): For types that
24300 wrap on overflow, try to use range info to prove that wrapping
24301 cannot occur.
24302
24303 2018-02-01 Renlin Li <renlin.li@arm.com>
24304
24305 PR target/83370
24306 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
24307 TAILCALL_ADDR_REGS.
24308 (aarch64_register_move_cost): Likewise.
24309 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
24310 TAILCALL_ADDR_REGS.
24311 (REG_CLASS_NAMES): Likewise.
24312 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
24313 TAILCALL_ADDR_REGS. Remove IP registers.
24314 * config/aarch64/aarch64.md (Ucs): Update register constraint.
24315
24316 2018-02-01 Richard Biener <rguenther@suse.de>
24317
24318 * domwalk.h (dom_walker::dom_walker): Add additional constructor
24319 for specifying RPO order and allow NULL for that.
24320 * domwalk.c (dom_walker::dom_walker): Likewise.
24321 (dom_walker::walk): Handle NULL RPO order.
24322 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
24323 in RPO order.
24324 (rewrite_update_dom_walker): Likewise.
24325 (mark_def_dom_walker): Likewise.
24326
24327 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24328
24329 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
24330 (aarch64_maybe_expand_sve_subreg_move): Declare.
24331 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
24332 * config/aarch64/predicates.md (aarch64_any_register_operand): New
24333 predicate.
24334 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
24335 that are semantically a reverse operation.
24336 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
24337 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
24338 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
24339 functions.
24340 (aarch64_can_change_mode_class): For big-endian, forbid changes
24341 between two SVE modes if they have different element sizes.
24342
24343 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24344
24345 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
24346 the TImode handling for big-endian targets.
24347
24348 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24349
24350 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
24351 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
24352 not just bytes.
24353 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
24354 Remove BSWAP handing for big-endian targets and use the form of
24355 LD1RQ appropariate for the mode.
24356
24357 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24358
24359 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
24360 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
24361 duplicated element.
24362
24363 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24364
24365 PR tearget/83845
24366 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
24367 check for operands that need to go through aarch64_sve_reload_be.
24368
24369 2018-02-01 Jakub Jelinek <jakub@redhat.com>
24370
24371 PR tree-optimization/81661
24372 PR tree-optimization/84117
24373 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
24374 * tree-eh.c: Include gimplify.h.
24375 (find_trapping_overflow, replace_trapping_overflow,
24376 rewrite_to_non_trapping_overflow): New functions.
24377 * tree-vect-loop.c: Include tree-eh.h.
24378 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
24379 * tree-data-ref.c: Include tree-eh.h.
24380 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
24381
24382 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
24383
24384 PR rtl-optimization/84123
24385 * combine.c (change_zero_ext): Check if hard register satisfies
24386 can_change_dest_mode before calling gen_lowpart_SUBREG.
24387
24388 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
24389
24390 PR target/82444
24391 * ira.c (ira_init_register_move_cost): Remove assert.
24392
24393 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24394
24395 PR rtl-optimization/84071
24396 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
24397 * doc/tm.texi: Regenerate.
24398
24399 2018-01-31 Richard Biener <rguenther@suse.de>
24400
24401 PR tree-optimization/84132
24402 * tree-data-ref.c (analyze_miv_subscript): Properly
24403 check whether evolution_function_is_affine_multivariate_p
24404 before calling gcd_of_steps_may_divide_p.
24405
24406 2018-01-31 Julia Koval <julia.koval@intel.com>
24407
24408 PR target/83618
24409 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
24410 * config/i386/i386.md (rdpid_rex64) New.
24411 (rdpid): Make 32bit only.
24412
24413 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
24414
24415 PR lto/84105
24416 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
24417 an IDENTIFIER_NODE for FUNCTION_TYPE's.
24418
24419 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24420
24421 Revert
24422 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
24423
24424 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
24425
24426 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24427
24428 PR rtl-optimization/84071
24429 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
24430 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
24431
24432 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24433
24434 * config/arc/arc.c (arc_handle_aux_attribute): New function.
24435 (arc_attribute_table): Add 'aux' attribute.
24436 (arc_in_small_data_p): Consider aux like variables.
24437 (arc_is_aux_reg_p): New function.
24438 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
24439 (arc_get_aux_arg): New function.
24440 (prepare_move_operands): Handle aux-register access.
24441 (arc_handle_aux_attribute): New function.
24442 * doc/extend.texi (ARC Variable attributes): Add subsection.
24443
24444 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24445
24446 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
24447 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
24448 (arc_attribute_table): Add 'uncached' attribute.
24449 (arc_print_operand): Print '.di' flag for uncached memory
24450 accesses.
24451 (arc_in_small_data_p): Do not consider for small data the uncached
24452 types.
24453 (arc_is_uncached_mem_p): New function.
24454 * config/arc/predicates.md (compact_store_memory_operand): Check
24455 for uncached memory accesses.
24456 (nonvol_nonimm_operand): Likewise.
24457 * doc/extend.texi (ARC Type Attribute): New subsection.
24458
24459 2018-01-31 Jakub Jelinek <jakub@redhat.com>
24460
24461 PR c/84100
24462 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
24463 falign-loops=): Add Optimization flag.
24464
24465 2018-01-30 Jeff Law <law@redhat.com>
24466
24467 PR target/84064
24468 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
24469 INT_REGISTERS_SAVED. Check it prior to calling
24470 get_scratch_register_on_entry.
24471 (ix86_adjust_stack_and_probe): Similarly.
24472 (ix86_emit_probe_stack_range): Similarly.
24473 (ix86_expand_prologue): Corresponding changes.
24474
24475 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24476
24477 PR target/40411
24478 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
24479 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
24480
24481 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
24482
24483 PR target/84112
24484 * lra-constraints.c (curr_insn_transform): Process AND in the
24485 address.
24486
24487 2018-01-30 Jakub Jelinek <jakub@redhat.com>
24488
24489 PR rtl-optimization/83986
24490 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
24491 dependence against last_pending_memory_flush in addition to
24492 pending_jump_insns.
24493
24494 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
24495
24496 PR tree-optimization/81611
24497 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
24498 copies.
24499
24500 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
24501
24502 PR target/83758
24503 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
24504 a reg rtx.
24505
24506 2018-01-30 Richard Biener <rguenther@suse.de>
24507 Jakub Jelinek <jakub@redhat.com>
24508
24509 PR tree-optimization/84111
24510 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
24511 inner loops added during recursion, as they don't have up-to-date
24512 SSA form.
24513
24514 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24515
24516 PR ipa/81360
24517 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
24518 (can_inline_edge_by_limits_p): ... here.
24519 (can_early_inline_edge_p, check_callers,
24520 update_caller_keys, update_callee_keys, recursive_inlining,
24521 add_new_edges_to_heap, speculation_useful_p,
24522 inline_small_functions,
24523 inline_small_functions, flatten_function,
24524 inline_to_all_callers_1): Update.
24525
24526 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24527
24528 * profile-count.c (profile_count::combine_with_ipa_count): Handle
24529 zeros correctly.
24530
24531 2018-01-30 Richard Biener <rguenther@suse.de>
24532
24533 PR tree-optimization/83008
24534 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
24535 invariant and constant vector uses in stmts when they need
24536 more than one stmt.
24537
24538 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24539
24540 PR bootstrap/84017
24541 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
24542 * configure: Regenerate.
24543
24544 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24545
24546 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
24547 pattern.
24548 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
24549 Use gen_rtx_REG rather than gen_lowpart.
24550
24551 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24552
24553 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
24554 rather than 0 when creating partial subregs.
24555
24556 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24557
24558 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
24559 of usage.
24560
24561 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
24562
24563 PR target/81550
24564 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
24565 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
24566 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
24567 flags. This restores the settings used before the 2017-07-24.
24568 Turning off pre increment/decrement/modify allows IVOPTS to
24569 optimize DF/SF loops where the index is an int.
24570
24571 2018-01-29 Richard Biener <rguenther@suse.de>
24572 Kelvin Nilsen <kelvin@gcc.gnu.org>
24573
24574 PR bootstrap/80867
24575 * tree-vect-stmts.c (vectorizable_call): Don't call
24576 targetm.vectorize_builtin_md_vectorized_function if callee is
24577 NULL.
24578
24579 2018-01-22 Carl Love <cel@us.ibm.com>
24580
24581 * doc/extend.tex: Fix typo in second arg in
24582 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
24583
24584 2018-01-29 Richard Biener <rguenther@suse.de>
24585
24586 PR tree-optimization/84086
24587 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
24588 (flush_ssaname_freelist): When SSA names were released reset
24589 the SCEV hash table.
24590
24591 2018-01-29 Richard Biener <rguenther@suse.de>
24592
24593 PR tree-optimization/84057
24594 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
24595 removed paths when removing edges.
24596
24597 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
24598
24599 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
24600 -mfunction-return=@var{choice}.
24601
24602 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
24603
24604 PR diagnostic/84034
24605 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
24606 Handle CR like TAB.
24607 (layout::print_source_line): Likewise.
24608 (test_get_line_width_without_trailing_whitespace): Add test cases.
24609
24610 2018-01-27 Jakub Jelinek <jakub@redhat.com>
24611
24612 PR middle-end/84040
24613 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
24614 debug insns.
24615
24616 2018-01-26 Jim Wilson <jimw@sifive.com>
24617
24618 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
24619
24620 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
24621 specified.
24622
24623 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24624
24625 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
24626 and CMP + SUB-immediate -> SUBS.
24627
24628 2018-01-26 Martin Sebor <msebor@redhat.com>
24629
24630 PR tree-optimization/83896
24631 * tree-ssa-strlen.c (get_string_len): Rename...
24632 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
24633 Avoid assuming length is constant.
24634 (handle_char_store): Use HOST_WIDE_INT for string length.
24635
24636 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
24637
24638 PR target/81763
24639 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
24640 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
24641
24642 2018-01-26 Richard Biener <rguenther@suse.de>
24643
24644 PR rtl-optimization/84003
24645 * dse.c (record_store): Only record redundant stores when
24646 the earlier store aliases at least all accesses the later one does.
24647
24648 2018-01-26 Jakub Jelinek <jakub@redhat.com>
24649
24650 PR rtl-optimization/83985
24651 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
24652 REG_CFA_RESTORE insns.
24653 (delete_unmarked_insns): Don't ignore separate shrink wrapping
24654 REG_CFA_RESTORE insns here.
24655
24656 PR c/83989
24657 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
24658 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
24659
24660 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24661
24662 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
24663 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
24664 (arc_init): Likewise.
24665 (arc_override_options): Likewise.
24666 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
24667 value.
24668 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
24669 support.
24670 * config/arc/arc.h (TARGET_DBNZ): Define.
24671 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
24672 properly set the tune attribute.
24673 (dbnz): Use TARGET_DBNZ guard.
24674 * config/arc/arc.opt (mtune): Add core3 option.
24675
24676 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24677
24678 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
24679 recognize new pic like addresses.
24680 (arc_delegitimize_address): Clean up.
24681
24682 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24683
24684 * config/arc/arc-arches.def: Option mrf16 valid for all
24685 architectures.
24686 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
24687 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
24688 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
24689 * config/arc/arc-tables.opt: Regenerate.
24690 * config/arc/arc.c (arc_conditional_register_usage): Handle
24691 reduced register file case.
24692 (arc_file_start): Set must have build attributes.
24693 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
24694 mrf16 option value.
24695 * config/arc/arc.opt (mrf16): Add new option.
24696 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
24697 * config/arc/genmultilib.awk: Handle new mrf16 option.
24698 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
24699 * config/arc/t-multilib: Regenerate.
24700 * doc/invoke.texi (ARC Options): Document mrf16 option.
24701
24702 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24703
24704 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
24705 * config/arc/arc.c (arc_handle_secure_attribute): New function.
24706 (arc_attribute_table): Add 'secure_call' attribute.
24707 (arc_print_operand): Print secure call operand.
24708 (arc_function_ok_for_sibcall): Don't optimize tail calls when
24709 secure.
24710 (arc_is_secure_call_p): New function. * config/arc/arc.md
24711 (call_i): Add support for sjli instruction.
24712 (call_value_i): Likewise.
24713 * config/arc/constraints.md (Csc): New constraint.
24714
24715 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24716 John Eric Martin <John.Martin@emmicro-us.com>
24717
24718 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
24719 * config/arc/arc.c (_arc_jli_section): New struct.
24720 (arc_jli_section): New type.
24721 (rc_jli_sections): New static variable.
24722 (arc_handle_jli_attribute): New function.
24723 (arc_attribute_table): Add jli_always and jli_fixed attribute.
24724 (arc_file_end): New function.
24725 (TARGET_ASM_FILE_END): Define.
24726 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
24727 (arc_add_jli_section): New function.
24728 (jli_call_scan): Likewise.
24729 (arc_reorg): Call jli_call_scan.
24730 (arc_output_addsi): Remove 'S' from printing asm operand.
24731 (arc_is_jli_call_p): New function.
24732 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
24733 operand.
24734 (movhi_insn): Likewise.
24735 (movsi_insn): Likewise.
24736 (movsi_set_cc_insn): Likewise.
24737 (loadqi_update): Likewise.
24738 (load_zeroextendqisi_update): Likewise.
24739 (load_signextendqisi_update): Likewise.
24740 (loadhi_update): Likewise.
24741 (load_zeroextendhisi_update): Likewise.
24742 (load_signextendhisi_update): Likewise.
24743 (loadsi_update): Likewise.
24744 (loadsf_update): Likewise.
24745 (movsicc_insn): Likewise.
24746 (bset_insn): Likewise.
24747 (bxor_insn): Likewise.
24748 (bclr_insn): Likewise.
24749 (bmsk_insn): Likewise.
24750 (bicsi3_insn): Likewise.
24751 (cmpsi_cc_c_insn): Likewise.
24752 (movsi_ne): Likewise.
24753 (movsi_cond_exec): Likewise.
24754 (clrsbsi2): Likewise.
24755 (norm_f): Likewise.
24756 (normw): Likewise.
24757 (swap): Likewise.
24758 (divaw): Likewise.
24759 (flag): Likewise.
24760 (sr): Likewise.
24761 (kflag): Likewise.
24762 (ffs): Likewise.
24763 (ffs_f): Likewise.
24764 (fls): Likewise.
24765 (call_i): Remove 'S' asm letter, add jli instruction.
24766 (call_value_i): Likewise.
24767 * config/arc/arc.op (mjli-always): New option.
24768 * config/arc/constraints.md (Cji): New constraint.
24769 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
24770 operand.
24771 (subsf3_fpx): Likewise.
24772 (mulsf3_fpx): Likewise.
24773 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
24774 asm operand.
24775 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
24776 function attrbutes.
24777 * doc/invoke.texi (ARC): Document mjli-always option.
24778
24779 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
24780
24781 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
24782 avoid addition with 0 and use incw and decw where possible.
24783
24784 2018-01-26 Richard Biener <rguenther@suse.de>
24785
24786 PR tree-optimization/81082
24787 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
24788 association if it requires casting to unsigned.
24789 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
24790 from fold_plusminus_mult_expr to catch important cases late when
24791 range info is available.
24792
24793 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24794
24795 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
24796 * configure.ac (hidden_linkonce): New test.
24797 * configure: Regenerate.
24798 * config.in: Regenerate.
24799
24800 2018-01-26 Julia Koval <julia.koval@intel.com>
24801
24802 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
24803 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
24804 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
24805 _mm_mask_bitshuffle_epi64_mask): Fix type.
24806 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
24807 USI_FTYPE_V4DI_V4DI_USI): Remove.
24808 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
24809 __builtin_ia32_vpshufbitqmb256_mask,
24810 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
24811 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
24812 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
24813
24814 2018-01-26 Alan Modra <amodra@gmail.com>
24815
24816 PR target/84033
24817 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
24818 UNSPEC_VBPERMQ. Sort other unspecs.
24819
24820 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
24821
24822 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
24823
24824 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
24825
24826 PR middle-end/83055
24827 * predict.c (drop_profile): Do not push/pop cfun; update also
24828 node->count.
24829 (handle_missing_profiles): Fix logic looking for zero profiles.
24830
24831 2018-01-25 Jakub Jelinek <jakub@redhat.com>
24832
24833 PR middle-end/83977
24834 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
24835 on functions with #pragma omp declare simd or functions with simd
24836 attribute.
24837 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
24838 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
24839 Remove trailing \n from warning_at calls.
24840
24841 2018-01-25 Tom de Vries <tom@codesourcery.com>
24842
24843 PR target/84028
24844 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24845 for neutered workers.
24846
24847 2018-01-24 Joseph Myers <joseph@codesourcery.com>
24848
24849 PR target/68467
24850 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
24851 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
24852
24853 2018-01-24 Jeff Law <law@redhat.com>
24854
24855 PR target/83994
24856 * i386.c (get_probe_interval): Move to earlier point.
24857 (ix86_compute_frame_layout): If -fstack-clash-protection and
24858 the frame is larger than the probe interval, then use pushes
24859 to save registers rather than reg->mem moves.
24860 (ix86_expand_prologue): Remove conditional for int_registers_saved
24861 assertion.
24862
24863 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
24864
24865 PR target/84014
24866 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
24867 min/max for never referenced object.
24868
24869 2018-01-24 Jakub Jelinek <jakub@redhat.com>
24870
24871 PR middle-end/83977
24872 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
24873 here.
24874 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
24875 attributes from DECL_ATTRIBUTES (decl) without affecting
24876 DECL_ATTRIBUTES (current_function_decl).
24877 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
24878 functions with non-NULL DECL_ABSTRACT_ORIGIN.
24879
24880 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
24881
24882 PR tree-optimization/83979
24883 * fold-const.c (fold_comparison): Use constant_boolean_node
24884 instead of boolean_{true,false}_node.
24885
24886 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
24887
24888 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
24889 with zero counts.
24890
24891 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24892
24893 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
24894 Simplify the clause that sets the length attribute.
24895 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
24896 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
24897 clause that sets the length attribute.
24898 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
24899
24900 2018-01-24 Tom de Vries <tom@codesourcery.com>
24901
24902 PR target/83589
24903 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
24904 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
24905 Add strict parameter.
24906 (prevent_branch_around_nothing): Insert dummy insn between branch to
24907 label and label with no ptx insn inbetween.
24908 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
24909
24910 2018-01-24 Tom de Vries <tom@codesourcery.com>
24911
24912 PR target/81352
24913 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24914 for neutered threads in warp.
24915 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
24916
24917 2018-01-24 Richard Biener <rguenther@suse.de>
24918
24919 PR tree-optimization/83176
24920 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
24921 operands.
24922
24923 2018-01-24 Richard Biener <rguenther@suse.de>
24924
24925 PR tree-optimization/82819
24926 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
24927 code generating pluses that are no-ops in the target precision.
24928
24929 2018-01-24 Richard Biener <rguenther@suse.de>
24930
24931 PR middle-end/84000
24932 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
24933
24934 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24935
24936 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
24937 to merge probabilities.
24938 * predict.c (probably_never_executed): Also mark as cold functions
24939 with global 0 profile and guessed local profile.
24940 * profile-count.c (profile_probability::combine_with_count): New
24941 member function.
24942 * profile-count.h (profile_probability::operator*,
24943 profile_probability::operator*=, profile_probability::operator/,
24944 profile_probability::operator/=): Reduce precision to adjusted
24945 and set value to guessed on contradictory divisions.
24946 (profile_probability::combine_with_freq): Remove.
24947 (profile_probability::combine_wiht_count): Declare.
24948 (profile_count::force_nonzero):: Set to adjusted.
24949 (profile_count::probability_in):: Set quality to adjusted.
24950 * tree-ssa-tail-merge.c (replace_block_by): Use
24951 combine_with_count.
24952
24953 2018-01-23 Andrew Waterman <andrew@sifive.com>
24954 Jim Wilson <jimw@sifive.com>
24955
24956 * config/riscv/riscv.c (riscv_stack_boundary): New.
24957 (riscv_option_override): Set riscv_stack_boundary. Handle
24958 riscv_preferred_stack_boundary_arg.
24959 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
24960 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
24961 (STACK_BOUNDARY): Set to riscv_stack_boundary.
24962 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
24963 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
24964 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
24965
24966 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
24967
24968 PR target/83905
24969 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
24970 of struct ix86_frame.
24971 (ix86_expand_epilogue): Likewise. Add a local variable for
24972 the reg_save_offset field in struct ix86_frame.
24973
24974 2018-01-23 Bin Cheng <bin.cheng@arm.com>
24975
24976 PR tree-optimization/82604
24977 * tree-loop-distribution.c (enum partition_kind): New enum item
24978 PKIND_PARTIAL_MEMSET.
24979 (partition_builtin_p): Support above new enum item.
24980 (generate_code_for_partition): Ditto.
24981 (compute_access_range): Differentiate cases that equality can be
24982 proven at all loops, the innermost loops or no loops.
24983 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
24984 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
24985 (finalize_partitions, distribute_loop): Don't fuse partition of
24986 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
24987 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
24988 parloop is enabled.
24989
24990 2018-01-23 Martin Liska <mliska@suse.cz>
24991
24992 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
24993 order to ignore the predictor.
24994 (PRED_POLYMORPHIC_CALL): Likewise.
24995 (PRED_RECURSIVE_CALL): Likewise.
24996
24997 2018-01-23 Martin Liska <mliska@suse.cz>
24998
24999 * tree-profile.c (tree_profiling): Print function header to
25000 aware reader which function we are working on.
25001 * value-prof.c (gimple_find_values_to_profile): Do not print
25002 not interesting value histograms.
25003
25004 2018-01-23 Martin Liska <mliska@suse.cz>
25005
25006 * profile-count.h (enum profile_quality): Add
25007 profile_uninitialized as the first value. Do not number values
25008 as they are zero based.
25009 (profile_count::verify): Update sanity check.
25010 (profile_probability::verify): Likewise.
25011
25012 2018-01-23 Nathan Sidwell <nathan@acm.org>
25013
25014 * doc/invoke.texi (ffor-scope): Deprecate.
25015
25016 2018-01-23 David Malcolm <dmalcolm@redhat.com>
25017
25018 PR tree-optimization/83510
25019 * domwalk.c (set_all_edges_as_executable): New function.
25020 (dom_walker::dom_walker): Convert bool param
25021 "skip_unreachable_blocks" to enum reachability. Move setup of
25022 edge flags to set_all_edges_as_executable and only do it when
25023 reachability is REACHABLE_BLOCKS.
25024 * domwalk.h (enum dom_walker::reachability): New enum.
25025 (dom_walker::dom_walker): Convert bool param
25026 "skip_unreachable_blocks" to enum reachability.
25027 (set_all_edges_as_executable): New decl.
25028 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
25029 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
25030 "reachability".
25031 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
25032 but converting true to REACHABLE_BLOCKS.
25033 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
25034 * tree-vrp.c
25035 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
25036 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
25037 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
25038 REACHABLE_BLOCKS.
25039 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
25040 if check_all_array_refs will be called.
25041
25042 2018-01-23 David Malcolm <dmalcolm@redhat.com>
25043
25044 * tree.c (selftest::test_location_wrappers): Add more test
25045 coverage.
25046
25047 2018-01-23 David Malcolm <dmalcolm@redhat.com>
25048
25049 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
25050 (selftest::test_bit_in_range): Likewise.
25051
25052 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
25053
25054 PR testsuite/83888
25055 * doc/sourcebuild.texi (vect_float): Say that the selector
25056 only describes the situation when -funsafe-math-optimizations is on.
25057 (vect_float_strict): Document.
25058
25059 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
25060
25061 PR tree-optimization/83965
25062 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
25063 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
25064 instead of checking only for a reduction.
25065 (vect_recog_widen_sum_pattern): Likewise.
25066
25067 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
25068
25069 * predict.c (probably_never_executed): Only use precise profile info.
25070 (compute_function_frequency): Skip after inlining hack since we now
25071 have quality checking.
25072
25073 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
25074
25075 * profile-count.h (profile_probability::very_unlikely,
25076 profile_probability::unlikely, profile_probability::even): Set
25077 precision to guessed.
25078
25079 2018-01-23 Richard Biener <rguenther@suse.de>
25080
25081 PR tree-optimization/83963
25082 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
25083 Properly terminate dominator walk when crossing the exit edge not
25084 when visiting its source block.
25085
25086 2018-01-23 Jakub Jelinek <jakub@redhat.com>
25087
25088 PR c++/83918
25089 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
25090 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
25091
25092 2018-01-22 Jakub Jelinek <jakub@redhat.com>
25093
25094 PR tree-optimization/83957
25095 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
25096 semicolon after for body surrounded by braces.
25097
25098 PR tree-optimization/83081
25099 * profile-count.h (profile_probability::split): New method.
25100 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
25101 Use profile_probability::split.
25102 (do_compare_rtx_and_jump): Fix adjustment of probabilities
25103 when splitting a single conditional jump into 2.
25104
25105 2018-01-22 David Malcolm <dmalcolm@redhat.com>
25106
25107 PR tree-optimization/69452
25108 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
25109 decl.
25110
25111 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25112
25113 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
25114 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
25115 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
25116
25117 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25118
25119 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
25120 declaration.
25121 * config/rl78/rl78.md (movdi): New define_expand.
25122 * config/rl78/rl78.c (rl78_split_movdi): New function.
25123
25124 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
25125
25126 PR target/83862
25127 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
25128 no longer used.
25129 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
25130 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
25131 128-bit to produce an UNSPEC move to get the double word with the
25132 signbit and then a shift directly to do signbit.
25133 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
25134 implementation with a new version that just does either a direct
25135 move or a regular move. Move memory interface to separate insns.
25136 Move insns so they are next to the expander.
25137 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
25138 with signbit move. Split big and little endian case.
25139 (signbit<mode>2_dm_mem_le): Likewise.
25140 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
25141 (signbit<mode>2_dm2): Likewise.
25142
25143 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25144
25145 * config/rl78/rl78.md (anddi3): New define_expand.
25146
25147 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25148
25149 * config/rl78/rl78.md (umindi3): New define_expand.
25150
25151 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25152
25153 * config/rl78/rl78.md (smindi3): New define_expand.
25154
25155 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25156
25157 * config/rl78/rl78.md (smaxdi3): New define_expand.
25158
25159 2018-01-22 Carl Love <cel@us.ibm.com>
25160
25161 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
25162 LVX_V1TI): Add macro expansion.
25163 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
25164 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
25165 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
25166 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
25167 Change check to determine if the instruction is a byte reversing
25168 entry. Fix typo in comment.
25169 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
25170 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
25171 Add def_builtin calls for new builtins.
25172 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
25173 Add define_insn expansion.
25174
25175 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25176
25177 * config/rl78/rl78.md (umaxdi3): New define_expand.
25178
25179 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25180
25181 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
25182 for non-QImode registers.
25183
25184 2018-01-22 Richard Biener <rguenther@suse.de>
25185
25186 PR tree-optimization/83963
25187 * graphite-scop-detection.c (scop_detection::get_sese): Delay
25188 including the loop exit block.
25189 (scop_detection::merge_sese): Likewise.
25190 (scop_detection::add_scop): Do it here instead.
25191
25192 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25193
25194 * doc/sourcebuild.texi (arm_softfloat): Document.
25195
25196 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
25197
25198 PR gcc/77734
25199 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
25200 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
25201 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
25202
25203 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25204 David Edelsohn <dje.gcc@gmail.com>
25205
25206 PR target/83946
25207 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25208 Change "crset eq" to "crset 2".
25209 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25210 (*call_indirect_aix<mode>_nospec): Likewise.
25211 (*call_value_indirect_aix<mode>_nospec): Likewise.
25212 (*call_indirect_elfv2<mode>_nospec): Likewise.
25213 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
25214 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
25215 change assembly output from . to $.
25216 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25217 (indirect_jump<mode>_nospec): Change assembly output from . to $.
25218 (*tablejump<mode>_internal1_nospec): Likewise.
25219
25220 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
25221
25222 PR target/80870
25223 * config/sh/sh_optimize_sett_clrt.cc:
25224 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
25225
25226 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
25227
25228 PR tree-optimization/83940
25229 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
25230 offset_dt to vect_constant_def rather than vect_unknown_def_type.
25231 (vect_check_load_store_mask): Add a mask_dt_out parameter and
25232 use it to pass back the definition type.
25233 (vect_check_store_rhs): Likewise rhs_dt_out.
25234 (vect_build_gather_load_calls): Add a mask_dt argument and use
25235 it instead of a call to vect_is_simple_use.
25236 (vectorizable_store): Update calls to vect_check_load_store_mask
25237 and vect_check_store_rhs. Use the dt returned by the latter instead
25238 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
25239 instead of calls to vect_is_simple_use. Pass the scalar rather
25240 than the vector operand to vect_is_simple_use when handling
25241 second and subsequent copies of an rhs value.
25242 (vectorizable_load): Update calls to vect_check_load_store_mask
25243 and vect_build_gather_load_calls. Use the cached mask_dt and
25244 gs_info.offset_dt instead of calls to vect_is_simple_use.
25245
25246 2018-01-20 Jakub Jelinek <jakub@redhat.com>
25247
25248 PR middle-end/83945
25249 * tree-emutls.c: Include gimplify.h.
25250 (lower_emutls_2): New function.
25251 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
25252 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
25253 it before further processing.
25254
25255 PR target/83930
25256 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
25257 UINTVAL (trueop1) instead of INTVAL (op1).
25258
25259 2018-01-19 Jakub Jelinek <jakub@redhat.com>
25260
25261 PR debug/81570
25262 PR debug/83728
25263 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
25264 INCOMING_FRAME_SP_OFFSET if not defined.
25265 (scan_trace): Add ENTRY argument. If true and
25266 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
25267 emit a note to adjust the CFA offset.
25268 (create_cfi_notes): Adjust scan_trace callers.
25269 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
25270 INCOMING_FRAME_SP_OFFSET in the CIE.
25271 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
25272 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
25273 Likewise.
25274 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
25275 * doc/tm.texi: Regenerated.
25276
25277 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25278
25279 PR rtl-optimization/83147
25280 * lra-constraints.c (remove_inheritance_pseudos): Use
25281 lra_substitute_pseudo_within_insn.
25282
25283 2018-01-19 Tom de Vries <tom@codesourcery.com>
25284 Cesar Philippidis <cesar@codesourcery.com>
25285
25286 PR target/83920
25287 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
25288
25289 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
25290
25291 PR target/83790
25292 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
25293 spaces for function labels.
25294
25295 2018-01-19 Martin Liska <mliska@suse.cz>
25296
25297 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
25298 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
25299 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
25300 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
25301 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
25302 (PRED_CONST_RETURN): Change from 69 to 65.
25303 (PRED_NULL_RETURN): Change from 91 to 71.
25304 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
25305 (PRED_LOOP_GUARD): Change from 66 to 73.
25306
25307 2018-01-19 Martin Liska <mliska@suse.cz>
25308
25309 * predict.c (predict_insn_def): Add new assert.
25310 (struct branch_predictor): Change type to signed integer.
25311 (test_prediction_value_range): Amend test to cover
25312 PROB_UNINITIALIZED.
25313 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
25314 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
25315 (PRED_LOOP_ITERATIONS_MAX): Likewise.
25316 (PRED_LOOP_IV_COMPARE): Likewise.
25317 * predict.h (PROB_UNINITIALIZED): Define new constant.
25318
25319 2018-01-19 Martin Liska <mliska@suse.cz>
25320
25321 * predict.c (dump_prediction): Add new format for
25322 analyze_brprob.py script which is enabled with -details
25323 suboption.
25324 * profile-count.h (precise_p): New function.
25325
25326 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25327
25328 PR tree-optimization/83922
25329 * tree-vect-loop.c (vect_verify_full_masking): Return false if
25330 there are no statements that need masking.
25331 (vect_active_double_reduction_p): New function.
25332 (vect_analyze_loop_operations): Use it when handling phis that
25333 are not in the loop header.
25334
25335 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25336
25337 PR tree-optimization/83914
25338 * tree-vect-loop.c (vectorizable_induction): Don't convert
25339 init_expr or apply the peeling adjustment for inductions
25340 that are nested within the vectorized loop.
25341
25342 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25343
25344 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
25345 instead of NEG.
25346
25347 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25348
25349 PR sanitizer/81715
25350 PR testsuite/83882
25351 * function.h (gimplify_parameters): Add gimple_seq * argument.
25352 * function.c: Include gimple.h and options.h.
25353 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
25354 for the added local temporaries if needed.
25355 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
25356 if there are any parameter cleanups, wrap whole body into a
25357 try/finally with the cleanups.
25358
25359 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
25360
25361 PR target/82964
25362 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
25363 Use GET_MODE_CLASS for scalar floating point.
25364
25365 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25366
25367 PR ipa/82256
25368 patch by PaX Team
25369 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
25370 Fix call of call_cgraph_insertion_hooks.
25371
25372 2018-01-18 Martin Sebor <msebor@redhat.com>
25373
25374 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
25375
25376 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25377
25378 PR ipa/83619
25379 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
25380 frequencies.
25381
25382 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
25383
25384 PR other/70268
25385 * common.opt: (-ffile-prefix-map): New option.
25386 * opts.c (common_handle_option): Defer it.
25387 * opts-global.c (handle_common_deferred_options): Handle it.
25388 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
25389 * file-prefix-map.h: New file.
25390 (remap_debug_filename, add_debug_prefix_map): ...here.
25391 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
25392 * final.c (debug_prefix_map, add_debug_prefix_map
25393 remap_debug_filename): Move to...
25394 * file-prefix-map.c: New file.
25395 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
25396 generalize, get rid of alloca(), use strrchr() instead of strchr().
25397 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
25398 Implement in terms of add_prefix_map().
25399 (remap_macro_filename, remap_debug_filename): Implement in term of
25400 remap_filename().
25401 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
25402 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
25403 * dbxout.c: Include file-prefix-map.h.
25404 * varasm.c: Likewise.
25405 * vmsdbgout.c: Likewise.
25406 * xcoffout.c: Likewise.
25407 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
25408 * doc/cppopts.texi (-fmacro-prefix-map): Document.
25409 * doc/invoke.texi (-ffile-prefix-map): Document.
25410 (-fdebug-prefix-map): Update description.
25411
25412 2018-01-18 Martin Liska <mliska@suse.cz>
25413
25414 * config/i386/i386.c (indirect_thunk_name): Document that also
25415 lfence is emitted.
25416 (output_indirect_thunk): Document why both instructions
25417 (pause and lfence) are generated.
25418
25419 2018-01-18 Richard Biener <rguenther@suse.de>
25420
25421 PR tree-optimization/83887
25422 * graphite-scop-detection.c
25423 (scop_detection::get_nearest_dom_with_single_entry): Remove.
25424 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
25425 (scop_detection::merge_sese): Re-implement with a flood-fill
25426 algorithm that properly finds a SESE region if it exists.
25427
25428 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25429
25430 PR c/61240
25431 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
25432 pointer_diff optimizations use view_convert instead of convert.
25433
25434 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25435
25436 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25437 Generate different code for -mno-speculate-indirect-jumps.
25438 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25439 (*call_indirect_aix<mode>): Disable for
25440 -mno-speculate-indirect-jumps.
25441 (*call_indirect_aix<mode>_nospec): New define_insn.
25442 (*call_value_indirect_aix<mode>): Disable for
25443 -mno-speculate-indirect-jumps.
25444 (*call_value_indirect_aix<mode>_nospec): New define_insn.
25445 (*sibcall_nonlocal_sysv<mode>): Generate different code for
25446 -mno-speculate-indirect-jumps.
25447 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25448
25449 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
25450
25451 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
25452 long double type, set the flags for noting the default long double
25453 type, even if we don't pass or return a long double type.
25454
25455 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
25456
25457 PR ipa/83051
25458 * ipa-inline.c (flatten_function): Do not overwrite final inlining
25459 failure.
25460
25461 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
25462
25463 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
25464 support for merge[hl].
25465 (fold_mergehl_helper): New helper function.
25466 (tree-vector-builder.h): New #include for tree_vector_builder usage.
25467 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
25468 (altivec_vmrglw_direct): Add xxmrglw insn.
25469
25470 2018-01-17 Andrew Waterman <andrew@sifive.com>
25471
25472 * config/riscv/riscv.c (riscv_conditional_register_usage): If
25473 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
25474
25475 2018-01-17 David Malcolm <dmalcolm@redhat.com>
25476
25477 PR lto/83121
25478 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
25479 call the lto_location_cache before reading the
25480 DECL_SOURCE_LOCATION of the types.
25481
25482 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
25483 Richard Sandiford <richard.sandiford@linaro.org>
25484
25485 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
25486 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
25487 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
25488 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
25489 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
25490 Add declaration.
25491 * config/aarch64/constraints.md (aarch64_movti_operand):
25492 Limit immediates.
25493 * config/aarch64/predicates.md (Uti): Add new constraint.
25494
25495 2018-01-17 Carl Love <cel@us.ibm.com>
25496
25497 * config/rs6000/vsx.md (define_expand xl_len_r,
25498 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
25499 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
25500 lxvll.
25501 (define_expand, define_insn): Move the shift left from the
25502 define_insn to the define_expand for lxvl and stxvl instructions.
25503 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
25504 and XL_LEN_R definitions to PURE.
25505
25506 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
25507
25508 * config/i386/i386.c (indirect_thunk_name): Declare regno
25509 as unsigned int. Compare regno with INVALID_REGNUM.
25510 (output_indirect_thunk): Ditto.
25511 (output_indirect_thunk_function): Ditto.
25512 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
25513 in the call to output_indirect_thunk_function.
25514
25515 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
25516
25517 PR middle-end/83884
25518 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
25519 rather than the size of inner_type to determine the stack slot size
25520 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
25521
25522 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
25523
25524 PR target/83546
25525 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
25526 to PTA_SILVERMONT.
25527
25528 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
25529
25530 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
25531 endian Linux systems to optionally enable multilibs for selecting
25532 the long double type if the user configured an explicit type.
25533 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
25534 have no long double multilibs if not defined.
25535 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
25536 warn if the user used -mabi={ieee,ibm}longdouble and we built
25537 multilibs for long double.
25538 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
25539 appropriate multilib option.
25540 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
25541 multilib options.
25542 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
25543 for building long double multilibs.
25544 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
25545
25546 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
25547
25548 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
25549 copies.
25550
25551 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
25552 64 bits.
25553 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
25554 128 bits.
25555
25556 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
25557 variables.
25558
25559 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
25560 return value.
25561
25562 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25563
25564 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
25565 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
25566
25567 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
25568
25569 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
25570 different rtl trees depending on TARGET_64BIT.
25571 (rs6000_gen_lvx): Likewise.
25572
25573 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25574
25575 * config/visium/visium.md (nop): Tweak comment.
25576 (hazard_nop): Likewise.
25577
25578 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25579
25580 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
25581 -mspeculate-indirect-jumps.
25582 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
25583 for -mno-speculate-indirect-jumps.
25584 (*call_indirect_elfv2<mode>_nospec): New define_insn.
25585 (*call_value_indirect_elfv2<mode>): Disable for
25586 -mno-speculate-indirect-jumps.
25587 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
25588 (indirect_jump): Emit different RTL for
25589 -mno-speculate-indirect-jumps.
25590 (*indirect_jump<mode>): Disable for
25591 -mno-speculate-indirect-jumps.
25592 (*indirect_jump<mode>_nospec): New define_insn.
25593 (tablejump): Emit different RTL for
25594 -mno-speculate-indirect-jumps.
25595 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
25596 (tablejumpsi_nospec): New define_expand.
25597 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
25598 (tablejumpdi_nospec): New define_expand.
25599 (*tablejump<mode>_internal1): Disable for
25600 -mno-speculate-indirect-jumps.
25601 (*tablejump<mode>_internal1_nospec): New define_insn.
25602 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
25603 option.
25604
25605 2018-01-16 Artyom Skrobov tyomitch@gmail.com
25606
25607 * caller-save.c (insert_save): Drop unnecessary parameter. All
25608 callers updated.
25609
25610 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25611 Richard Biener <rguenth@suse.de>
25612
25613 PR libgomp/83590
25614 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
25615 return early, inline manually is_gimple_sizepos. Make sure if we
25616 call gimplify_expr we don't end up with a gimple constant.
25617 * tree.c (variably_modified_type_p): Don't return true for
25618 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
25619 * gimplify.h (is_gimple_sizepos): Remove.
25620
25621 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25622
25623 PR tree-optimization/83857
25624 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
25625 vectorizable_live_operation for pure SLP statements.
25626 (vectorizable_live_operation): Handle PHIs.
25627
25628 2018-01-16 Richard Biener <rguenther@suse.de>
25629
25630 PR tree-optimization/83867
25631 * tree-vect-stmts.c (vect_transform_stmt): Precompute
25632 nested_in_vect_loop_p since the scalar stmt may get invalidated.
25633
25634 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25635
25636 PR c/83844
25637 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
25638 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
25639 If off is not INTEGER_CST, issue a may not be aligned warning
25640 rather than isn't aligned. Use isn%'t rather than isn't.
25641 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
25642 into MULT_EXPR.
25643 <case MULT_EXPR>: Improve the case when bottom and one of the
25644 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
25645 operand, in that case check if the other operand is multiple of
25646 bottom divided by the INTEGER_CST operand.
25647
25648 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25649
25650 PR target/83858
25651 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
25652 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
25653 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
25654 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
25655 * config/pa/pa.c (pa_function_arg_advance): Likewise.
25656 (pa_function_arg, pa_arg_partial_bytes): Likewise.
25657 (pa_function_arg_size): New function.
25658
25659 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25660
25661 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
25662 in a separate statement.
25663
25664 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25665
25666 PR tree-optimization/83847
25667 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
25668 group gathers and scatters.
25669
25670 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25671
25672 PR rtl-optimization/86620
25673 * params.def (max-sched-ready-insns): Bump minimum value to 1.
25674
25675 PR rtl-optimization/83213
25676 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
25677 to last if both are JUMP_INSNs.
25678
25679 PR tree-optimization/83843
25680 * gimple-ssa-store-merging.c
25681 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
25682 store_immediate_info for bswap/nop orig_stores.
25683
25684 2018-01-15 Andrew Waterman <andrew@sifive.com>
25685
25686 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
25687 !TARGET_MUL.
25688 <UDIV>: Increase cost if !TARGET_DIV.
25689
25690 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
25691
25692 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
25693 (define_attr "cr_logical_3op"): New.
25694 (cceq_ior_compare): Adjust.
25695 (cceq_ior_compare_complement): Adjust.
25696 (*cceq_rev_compare): Adjust.
25697 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
25698 (is_cracked_insn): Adjust.
25699 (insn_must_be_first_in_group): Adjust.
25700 * config/rs6000/40x.md: Adjust.
25701 * config/rs6000/440.md: Adjust.
25702 * config/rs6000/476.md: Adjust.
25703 * config/rs6000/601.md: Adjust.
25704 * config/rs6000/603.md: Adjust.
25705 * config/rs6000/6xx.md: Adjust.
25706 * config/rs6000/7450.md: Adjust.
25707 * config/rs6000/7xx.md: Adjust.
25708 * config/rs6000/8540.md: Adjust.
25709 * config/rs6000/cell.md: Adjust.
25710 * config/rs6000/e300c2c3.md: Adjust.
25711 * config/rs6000/e500mc.md: Adjust.
25712 * config/rs6000/e500mc64.md: Adjust.
25713 * config/rs6000/e5500.md: Adjust.
25714 * config/rs6000/e6500.md: Adjust.
25715 * config/rs6000/mpc.md: Adjust.
25716 * config/rs6000/power4.md: Adjust.
25717 * config/rs6000/power5.md: Adjust.
25718 * config/rs6000/power6.md: Adjust.
25719 * config/rs6000/power7.md: Adjust.
25720 * config/rs6000/power8.md: Adjust.
25721 * config/rs6000/power9.md: Adjust.
25722 * config/rs6000/rs64.md: Adjust.
25723 * config/rs6000/titan.md: Adjust.
25724
25725 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25726
25727 * config/i386/predicates.md (indirect_branch_operand): Rewrite
25728 ix86_indirect_branch_register logic.
25729
25730 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25731
25732 * config/i386/constraints.md (Bs): Update
25733 ix86_indirect_branch_register check. Don't check
25734 ix86_indirect_branch_register with GOT_memory_operand.
25735 (Bw): Likewise.
25736 * config/i386/predicates.md (GOT_memory_operand): Don't check
25737 ix86_indirect_branch_register here.
25738 (GOT32_symbol_operand): Likewise.
25739
25740 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25741
25742 * config/i386/predicates.md (constant_call_address_operand):
25743 Rewrite ix86_indirect_branch_register logic.
25744 (sibcall_insn_operand): Likewise.
25745
25746 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25747
25748 * config/i386/constraints.md (Bs): Replace
25749 ix86_indirect_branch_thunk_register with
25750 ix86_indirect_branch_register.
25751 (Bw): Likewise.
25752 * config/i386/i386.md (indirect_jump): Likewise.
25753 (tablejump): Likewise.
25754 (*sibcall_memory): Likewise.
25755 (*sibcall_value_memory): Likewise.
25756 Peepholes of indirect call and jump via memory: Likewise.
25757 * config/i386/i386.opt: Likewise.
25758 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25759 (GOT_memory_operand): Likewise.
25760 (call_insn_operand): Likewise.
25761 (sibcall_insn_operand): Likewise.
25762 (GOT32_symbol_operand): Likewise.
25763
25764 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25765
25766 PR middle-end/83837
25767 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
25768 type rather than type addr's type points to.
25769 (expand_omp_atomic_mutex): Likewise.
25770 (expand_omp_atomic): Likewise.
25771
25772 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25773
25774 PR target/83839
25775 * config/i386/i386.c (output_indirect_thunk_function): Use
25776 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
25777 for __x86_return_thunk.
25778
25779 2018-01-15 Richard Biener <rguenther@suse.de>
25780
25781 PR middle-end/83850
25782 * expmed.c (extract_bit_field_1): Fix typo.
25783
25784 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25785
25786 PR target/83687
25787 * config/arm/iterators.md (VF): New mode iterator.
25788 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
25789 Remove integer-related logic from pattern.
25790 (neon_vabd<mode>_3): Likewise.
25791
25792 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25793
25794 PR middle-end/82694
25795 * common.opt (fstrict-overflow): No longer an alias.
25796 (fwrapv-pointer): New option.
25797 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
25798 also for pointer types based on flag_wrapv_pointer.
25799 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
25800 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
25801 opts->x_flag_wrapv got set.
25802 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
25803 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
25804 POINTER_TYPE_OVERFLOW_UNDEFINED.
25805 * match.pd: Likewise in address comparison pattern.
25806 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
25807
25808 2018-01-15 Richard Biener <rguenther@suse.de>
25809
25810 PR lto/83804
25811 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
25812 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
25813 Reset type names to their identifier if their TYPE_DECL doesn't
25814 have linkage (and thus is used for ODR and devirt).
25815 (save_debug_info_for_decl): Remove.
25816 (save_debug_info_for_type): Likewise.
25817 (add_tree_to_fld_list): Adjust.
25818 * tree-pretty-print.c (dump_generic_node): Make dumping of
25819 type names more robust.
25820
25821 2018-01-15 Richard Biener <rguenther@suse.de>
25822
25823 * BASE-VER: Bump to 8.0.1.
25824
25825 2018-01-14 Martin Sebor <msebor@redhat.com>
25826
25827 PR other/83508
25828 * builtins.c (check_access): Avoid warning when the no-warning bit
25829 is set.
25830
25831 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
25832
25833 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
25834 * ira-color (allocno_hard_regs_compare): Likewise.
25835
25836 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
25837
25838 PR target/83013
25839 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
25840 Use .pushsection/.popsection.
25841
25842 2018-01-14 Martin Sebor <msebor@redhat.com>
25843
25844 PR c++/81327
25845 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
25846
25847 2018-01-14 Jakub Jelinek <jakub@redhat.com>
25848
25849 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
25850 entry from extra_headers.
25851 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
25852 extra_headers, make the list bitwise identical to the i?86-*-* one.
25853
25854 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25855
25856 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
25857 -mcmodel=large with -mindirect-branch=thunk,
25858 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
25859 -mfunction-return=thunk-extern.
25860 * doc/invoke.texi: Document -mcmodel=large is incompatible with
25861 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
25862 -mfunction-return=thunk and -mfunction-return=thunk-extern.
25863
25864 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25865
25866 * config/i386/i386.c (print_reg): Print the name of the full
25867 integer register without '%'.
25868 (ix86_print_operand): Handle 'V'.
25869 * doc/extend.texi: Document 'V' modifier.
25870
25871 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25872
25873 * config/i386/constraints.md (Bs): Disallow memory operand for
25874 -mindirect-branch-register.
25875 (Bw): Likewise.
25876 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25877 (GOT_memory_operand): Likewise.
25878 (call_insn_operand): Likewise.
25879 (sibcall_insn_operand): Likewise.
25880 (GOT32_symbol_operand): Likewise.
25881 * config/i386/i386.md (indirect_jump): Call convert_memory_address
25882 for -mindirect-branch-register.
25883 (tablejump): Likewise.
25884 (*sibcall_memory): Likewise.
25885 (*sibcall_value_memory): Likewise.
25886 Disallow peepholes of indirect call and jump via memory for
25887 -mindirect-branch-register.
25888 (*call_pop): Replace m with Bw.
25889 (*call_value_pop): Likewise.
25890 (*sibcall_pop_memory): Replace m with Bs.
25891 * config/i386/i386.opt (mindirect-branch-register): New option.
25892 * doc/invoke.texi: Document -mindirect-branch-register option.
25893
25894 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25895
25896 * config/i386/i386-protos.h (ix86_output_function_return): New.
25897 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
25898 set function_return_type.
25899 (indirect_thunk_name): Add ret_p to indicate thunk for function
25900 return.
25901 (output_indirect_thunk_function): Pass false to
25902 indirect_thunk_name.
25903 (ix86_output_indirect_branch_via_reg): Likewise.
25904 (ix86_output_indirect_branch_via_push): Likewise.
25905 (output_indirect_thunk_function): Create alias for function
25906 return thunk if regno < 0.
25907 (ix86_output_function_return): New function.
25908 (ix86_handle_fndecl_attribute): Handle function_return.
25909 (ix86_attribute_table): Add function_return.
25910 * config/i386/i386.h (machine_function): Add
25911 function_return_type.
25912 * config/i386/i386.md (simple_return_internal): Use
25913 ix86_output_function_return.
25914 (simple_return_internal_long): Likewise.
25915 * config/i386/i386.opt (mfunction-return=): New option.
25916 (indirect_branch): Mention -mfunction-return=.
25917 * doc/extend.texi: Document function_return function attribute.
25918 * doc/invoke.texi: Document -mfunction-return= option.
25919
25920 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25921
25922 * config/i386/i386-opts.h (indirect_branch): New.
25923 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
25924 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
25925 with local indirect jump when converting indirect call and jump.
25926 (ix86_set_indirect_branch_type): New.
25927 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
25928 (indirectlabelno): New.
25929 (indirect_thunk_needed): Likewise.
25930 (indirect_thunk_bnd_needed): Likewise.
25931 (indirect_thunks_used): Likewise.
25932 (indirect_thunks_bnd_used): Likewise.
25933 (INDIRECT_LABEL): Likewise.
25934 (indirect_thunk_name): Likewise.
25935 (output_indirect_thunk): Likewise.
25936 (output_indirect_thunk_function): Likewise.
25937 (ix86_output_indirect_branch_via_reg): Likewise.
25938 (ix86_output_indirect_branch_via_push): Likewise.
25939 (ix86_output_indirect_branch): Likewise.
25940 (ix86_output_indirect_jmp): Likewise.
25941 (ix86_code_end): Call output_indirect_thunk_function if needed.
25942 (ix86_output_call_insn): Call ix86_output_indirect_branch if
25943 needed.
25944 (ix86_handle_fndecl_attribute): Handle indirect_branch.
25945 (ix86_attribute_table): Add indirect_branch.
25946 * config/i386/i386.h (machine_function): Add indirect_branch_type
25947 and has_local_indirect_jump.
25948 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
25949 to true.
25950 (tablejump): Likewise.
25951 (*indirect_jump): Use ix86_output_indirect_jmp.
25952 (*tablejump_1): Likewise.
25953 (simple_return_indirect_internal): Likewise.
25954 * config/i386/i386.opt (mindirect-branch=): New option.
25955 (indirect_branch): New.
25956 (keep): Likewise.
25957 (thunk): Likewise.
25958 (thunk-inline): Likewise.
25959 (thunk-extern): Likewise.
25960 * doc/extend.texi: Document indirect_branch function attribute.
25961 * doc/invoke.texi: Document -mindirect-branch= option.
25962
25963 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
25964
25965 PR ipa/83051
25966 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
25967
25968 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
25969
25970 * ipa-inline.c (want_inline_small_function_p): Return false if
25971 inlining has already failed with CIF_FINAL_ERROR.
25972 (update_caller_keys): Call want_inline_small_function_p before
25973 can_inline_edge_p.
25974 (update_callee_keys): Likewise.
25975
25976 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25977
25978 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
25979 New function.
25980 (rs6000_quadword_masked_address_p): Likewise.
25981 (quad_aligned_load_p): Likewise.
25982 (quad_aligned_store_p): Likewise.
25983 (const_load_sequence_p): Add comment to describe the outer-most loop.
25984 (mimic_memory_attributes_and_flags): New function.
25985 (rs6000_gen_stvx): Likewise.
25986 (replace_swapped_aligned_store): Likewise.
25987 (rs6000_gen_lvx): Likewise.
25988 (replace_swapped_aligned_load): Likewise.
25989 (replace_swapped_load_constant): Capitalize argument name in
25990 comment describing this function.
25991 (rs6000_analyze_swaps): Add a third pass to search for vector loads
25992 and stores that access quad-word aligned addresses and replace
25993 with stvx or lvx instructions when appropriate.
25994 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
25995 New function prototype.
25996 (rs6000_quadword_masked_address_p): Likewise.
25997 (rs6000_gen_lvx): Likewise.
25998 (rs6000_gen_stvx): Likewise.
25999 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
26000 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
26001 when memory address is aligned.
26002 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
26003 this split to select lvx instruction when memory address is aligned.
26004 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
26005 instruction when memory address is aligned.
26006 (*vsx_le_perm_load_v16qi): Likewise.
26007 (four unnamed splitters): Modify to select the stvx instruction
26008 when memory is aligned.
26009
26010 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
26011
26012 * predict.c (determine_unlikely_bbs): Handle correctly BBs
26013 which appears in the queue multiple times.
26014
26015 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26016 Alan Hayward <alan.hayward@arm.com>
26017 David Sherwood <david.sherwood@arm.com>
26018
26019 * tree-vectorizer.h (vec_lower_bound): New structure.
26020 (_loop_vec_info): Add check_nonzero and lower_bounds.
26021 (LOOP_VINFO_CHECK_NONZERO): New macro.
26022 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
26023 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
26024 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
26025 fields. Make seg_len the distance travelled, not including the
26026 access size.
26027 (dr_direction_indicator): Declare.
26028 (dr_zero_step_indicator): Likewise.
26029 (dr_known_forward_stride_p): Likewise.
26030 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
26031 tree-ssanames.h.
26032 (runtime_alias_check_p): Allow runtime alias checks with
26033 variable strides.
26034 (operator ==): Compare access_size and align.
26035 (prune_runtime_alias_test_list): Rework for new distinction between
26036 the access_size and seg_len.
26037 (create_intersect_range_checks_index): Likewise. Cope with polynomial
26038 segment lengths.
26039 (get_segment_min_max): New function.
26040 (create_intersect_range_checks): Use it.
26041 (dr_step_indicator): New function.
26042 (dr_direction_indicator): Likewise.
26043 (dr_zero_step_indicator): Likewise.
26044 (dr_known_forward_stride_p): Likewise.
26045 * tree-loop-distribution.c (data_ref_segment_size): Return
26046 DR_STEP * (niters - 1).
26047 (compute_alias_check_pairs): Update call to the dr_with_seg_len
26048 constructor.
26049 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
26050 (vect_preserves_scalar_order_p): New function, split out from...
26051 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
26052 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
26053 (vect_vfa_access_size): New function.
26054 (vect_vfa_align): Likewise.
26055 (vect_compile_time_alias): Take access_size_a and access_b arguments.
26056 (dump_lower_bound): New function.
26057 (vect_check_lower_bound): Likewise.
26058 (vect_small_gap_p): Likewise.
26059 (vectorizable_with_step_bound_p): Likewise.
26060 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
26061 depencies if the vectorization factor is 1. Convert the checks
26062 for nonzero steps into checks on the bounds of DR_STEP. Try using
26063 a bunds check for variable steps if the minimum required step is
26064 relatively small. Update calls to the dr_with_seg_len
26065 constructor and to vect_compile_time_alias.
26066 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
26067 function.
26068 (vect_loop_versioning): Call it.
26069 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
26070 when retrying.
26071 (vect_estimate_min_profitable_iters): Account for any bounds checks.
26072
26073 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26074 Alan Hayward <alan.hayward@arm.com>
26075 David Sherwood <david.sherwood@arm.com>
26076
26077 * doc/sourcebuild.texi (vect_scatter_store): Document.
26078 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
26079 optabs.
26080 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
26081 Document.
26082 * genopinit.c (main): Add supports_vec_scatter_store and
26083 supports_vec_scatter_store_cached to target_optabs.
26084 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
26085 IFN_MASK_SCATTER_STORE.
26086 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
26087 functions.
26088 * internal-fn.h (internal_store_fn_p): Declare.
26089 (internal_fn_stored_value_index): Likewise.
26090 * internal-fn.c (scatter_store_direct): New macro.
26091 (expand_scatter_store_optab_fn): New function.
26092 (direct_scatter_store_optab_supported_p): New macro.
26093 (internal_store_fn_p): New function.
26094 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
26095 IFN_MASK_SCATTER_STORE.
26096 (internal_fn_mask_index): Likewise.
26097 (internal_fn_stored_value_index): New function.
26098 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
26099 for scatter stores.
26100 * optabs-query.h (supports_vec_scatter_store_p): Declare.
26101 * optabs-query.c (supports_vec_scatter_store_p): New function.
26102 * tree-vectorizer.h (vect_get_store_rhs): Declare.
26103 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
26104 true for scatter stores.
26105 (vect_gather_scatter_fn_p): Handle scatter stores too.
26106 (vect_check_gather_scatter): Consider using scatter stores if
26107 supports_vec_scatter_store_p.
26108 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
26109 scatter stores too.
26110 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
26111 internal_fn_stored_value_index.
26112 (check_load_store_masking): Handle scatter stores too.
26113 (vect_get_store_rhs): Make public.
26114 (vectorizable_call): Use internal_store_fn_p.
26115 (vectorizable_store): Handle scatter store internal functions.
26116 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
26117 when deciding whether the end of the group has been reached.
26118 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
26119 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
26120 (mask_scatter_store<mode>): New insns.
26121
26122 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26123 Alan Hayward <alan.hayward@arm.com>
26124 David Sherwood <david.sherwood@arm.com>
26125
26126 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
26127 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
26128 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
26129 function.
26130 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
26131 Use vect_truncate_gather_scatter_offset if we can't treat the
26132 operation as a normal gather load or scatter store.
26133 (get_group_load_store_type): Take the gather_scatter_info
26134 as argument. Try using a gather load or scatter store for
26135 single-element groups.
26136 (get_load_store_type): Update calls to get_group_load_store_type
26137 and vect_use_strided_gather_scatters_p.
26138
26139 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26140 Alan Hayward <alan.hayward@arm.com>
26141 David Sherwood <david.sherwood@arm.com>
26142
26143 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
26144 optional tree argument.
26145 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
26146 null target hooks.
26147 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
26148 but continue to use the current value as a fallback.
26149 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
26150 to compare the updates.
26151 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
26152 (get_load_store_type): Use it when handling a strided access.
26153 (vect_get_strided_load_store_ops): New function.
26154 (vect_get_data_ptr_increment): Likewise.
26155 (vectorizable_load): Handle strided gather loads. Always pass
26156 a step to vect_create_data_ref_ptr and bump_vector_ptr.
26157
26158 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26159 Alan Hayward <alan.hayward@arm.com>
26160 David Sherwood <david.sherwood@arm.com>
26161
26162 * doc/md.texi (gather_load@var{m}): Document.
26163 (mask_gather_load@var{m}): Likewise.
26164 * genopinit.c (main): Add supports_vec_gather_load and
26165 supports_vec_gather_load_cached to target_optabs.
26166 * optabs-tree.c (init_tree_optimization_optabs): Use
26167 ggc_cleared_alloc to allocate target_optabs.
26168 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
26169 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
26170 functions.
26171 * internal-fn.h (internal_load_fn_p): Declare.
26172 (internal_gather_scatter_fn_p): Likewise.
26173 (internal_fn_mask_index): Likewise.
26174 (internal_gather_scatter_fn_supported_p): Likewise.
26175 * internal-fn.c (gather_load_direct): New macro.
26176 (expand_gather_load_optab_fn): New function.
26177 (direct_gather_load_optab_supported_p): New macro.
26178 (direct_internal_fn_optab): New function.
26179 (internal_load_fn_p): Likewise.
26180 (internal_gather_scatter_fn_p): Likewise.
26181 (internal_fn_mask_index): Likewise.
26182 (internal_gather_scatter_fn_supported_p): Likewise.
26183 * optabs-query.c (supports_at_least_one_mode_p): New function.
26184 (supports_vec_gather_load_p): Likewise.
26185 * optabs-query.h (supports_vec_gather_load_p): Declare.
26186 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
26187 and memory_type field.
26188 (NUM_PATTERNS): Bump to 15.
26189 * tree-vect-data-refs.c: Include internal-fn.h.
26190 (vect_gather_scatter_fn_p): New function.
26191 (vect_describe_gather_scatter_call): Likewise.
26192 (vect_check_gather_scatter): Try using internal functions for
26193 gather loads. Recognize existing calls to a gather load function.
26194 (vect_analyze_data_refs): Consider using gather loads if
26195 supports_vec_gather_load_p.
26196 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
26197 (vect_get_gather_scatter_offset_type): Likewise.
26198 (vect_convert_mask_for_vectype): Likewise.
26199 (vect_add_conversion_to_patterm): Likewise.
26200 (vect_try_gather_scatter_pattern): Likewise.
26201 (vect_recog_gather_scatter_pattern): New pattern recognizer.
26202 (vect_vect_recog_func_ptrs): Add it.
26203 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
26204 internal_fn_mask_index and internal_gather_scatter_fn_p.
26205 (check_load_store_masking): Take the gather_scatter_info as an
26206 argument and handle gather loads.
26207 (vect_get_gather_scatter_ops): New function.
26208 (vectorizable_call): Check internal_load_fn_p.
26209 (vectorizable_load): Likewise. Handle gather load internal
26210 functions.
26211 (vectorizable_store): Update call to check_load_store_masking.
26212 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
26213 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
26214 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
26215 (aarch64_gather_scale_operand_d): New predicates.
26216 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
26217 (mask_gather_load<mode>): New insns.
26218
26219 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26220 Alan Hayward <alan.hayward@arm.com>
26221 David Sherwood <david.sherwood@arm.com>
26222
26223 * optabs.def (fold_left_plus_optab): New optab.
26224 * doc/md.texi (fold_left_plus_@var{m}): Document.
26225 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
26226 * internal-fn.c (fold_left_direct): Define.
26227 (expand_fold_left_optab_fn): Likewise.
26228 (direct_fold_left_optab_supported_p): Likewise.
26229 * fold-const-call.c (fold_const_fold_left): New function.
26230 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
26231 * tree-parloops.c (valid_reduction_p): New function.
26232 (gather_scalar_reductions): Use it.
26233 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
26234 (vect_finish_replace_stmt): Declare.
26235 * tree-vect-loop.c (fold_left_reduction_fn): New function.
26236 (needs_fold_left_reduction_p): New function, split out from...
26237 (vect_is_simple_reduction): ...here. Accept reductions that
26238 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
26239 (vect_force_simple_reduction): Also store the reduction type in
26240 the assignment's STMT_VINFO_REDUC_TYPE.
26241 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
26242 (merge_with_identity): New function.
26243 (vect_expand_fold_left): Likewise.
26244 (vectorize_fold_left_reduction): Likewise.
26245 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
26246 scalar phi in place for it. Check for target support and reject
26247 cases that would reassociate the operation. Defer the transform
26248 phase to vectorize_fold_left_reduction.
26249 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
26250 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
26251 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
26252
26253 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26254
26255 * tree-if-conv.c (predicate_mem_writes): Remove redundant
26256 call to ifc_temp_var.
26257
26258 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26259 Alan Hayward <alan.hayward@arm.com>
26260 David Sherwood <david.sherwood@arm.com>
26261
26262 * target.def (legitimize_address_displacement): Take the original
26263 offset as a poly_int.
26264 * targhooks.h (default_legitimize_address_displacement): Update
26265 accordingly.
26266 * targhooks.c (default_legitimize_address_displacement): Likewise.
26267 * doc/tm.texi: Regenerate.
26268 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
26269 as an argument, moving assert of ad->disp == ad->disp_term to...
26270 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
26271 Try calling targetm.legitimize_address_displacement before expanding
26272 the address rather than afterwards, and adjust for the new interface.
26273 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
26274 Match the new hook interface. Handle SVE addresses.
26275 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
26276 new hook interface.
26277
26278 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26279
26280 * Makefile.in (OBJS): Add early-remat.o.
26281 * target.def (select_early_remat_modes): New hook.
26282 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
26283 * doc/tm.texi: Regenerate.
26284 * targhooks.h (default_select_early_remat_modes): Declare.
26285 * targhooks.c (default_select_early_remat_modes): New function.
26286 * timevar.def (TV_EARLY_REMAT): New timevar.
26287 * passes.def (pass_early_remat): New pass.
26288 * tree-pass.h (make_pass_early_remat): Declare.
26289 * early-remat.c: New file.
26290 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
26291 function.
26292 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
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-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
26299 vfm1 with a bound_epilog parameter.
26300 (vect_do_peeling): Update calls accordingly, and move the prologue
26301 call earlier in the function. Treat the base bound_epilog as 0 for
26302 fully-masked loops and retain vf - 1 for other loops. Add 1 to
26303 this base when peeling for gaps.
26304 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
26305 with fully-masked loops.
26306 (vect_estimate_min_profitable_iters): Handle the single peeled
26307 iteration in that case.
26308
26309 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26310 Alan Hayward <alan.hayward@arm.com>
26311 David Sherwood <david.sherwood@arm.com>
26312
26313 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
26314 single-element interleaving even if the size is not a power of 2.
26315 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
26316 accesses for single-element interleaving if the group size is
26317 not a power of 2.
26318
26319 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26320 Alan Hayward <alan.hayward@arm.com>
26321 David Sherwood <david.sherwood@arm.com>
26322
26323 * doc/md.texi (fold_extract_last_@var{m}): Document.
26324 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
26325 * optabs.def (fold_extract_last_optab): New optab.
26326 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
26327 * internal-fn.c (fold_extract_direct): New macro.
26328 (expand_fold_extract_optab_fn): Likewise.
26329 (direct_fold_extract_optab_supported_p): Likewise.
26330 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
26331 * tree-vect-loop.c (vect_model_reduction_cost): Handle
26332 EXTRACT_LAST_REDUCTION.
26333 (get_initial_def_for_reduction): Do not create an initial vector
26334 for EXTRACT_LAST_REDUCTION reductions.
26335 (vectorizable_reduction): Leave the scalar phi in place for
26336 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
26337 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
26338 epilogue code for EXTRACT_LAST_REDUCTION and defer the
26339 transform phase to vectorizable_condition.
26340 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
26341 split out from...
26342 (vect_finish_stmt_generation): ...here.
26343 (vect_finish_replace_stmt): New function.
26344 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
26345 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
26346 pattern.
26347 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
26348
26349 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26350 Alan Hayward <alan.hayward@arm.com>
26351 David Sherwood <david.sherwood@arm.com>
26352
26353 * doc/md.texi (extract_last_@var{m}): Document.
26354 * optabs.def (extract_last_optab): New optab.
26355 * internal-fn.def (EXTRACT_LAST): New internal function.
26356 * internal-fn.c (cond_unary_direct): New macro.
26357 (expand_cond_unary_optab_fn): Likewise.
26358 (direct_cond_unary_optab_supported_p): Likewise.
26359 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
26360 loops using EXTRACT_LAST.
26361 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
26362 (extract_last_<mode>): ...this optab.
26363 (vec_extract<mode><Vel>): Update accordingly.
26364
26365 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26366 Alan Hayward <alan.hayward@arm.com>
26367 David Sherwood <david.sherwood@arm.com>
26368
26369 * target.def (empty_mask_is_expensive): New hook.
26370 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
26371 * doc/tm.texi: Regenerate.
26372 * targhooks.h (default_empty_mask_is_expensive): Declare.
26373 * targhooks.c (default_empty_mask_is_expensive): New function.
26374 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
26375 if the target says that empty masks are expensive.
26376 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
26377 New function.
26378 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
26379
26380 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26381 Alan Hayward <alan.hayward@arm.com>
26382 David Sherwood <david.sherwood@arm.com>
26383
26384 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
26385 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
26386 (vect_use_loop_mask_for_alignment_p): New function.
26387 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
26388 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
26389 niters_skip argument. Make sure that the first niters_skip elements
26390 of the first iteration are inactive.
26391 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
26392 Update call to vect_set_loop_masks_directly.
26393 (get_misalign_in_elems): New function, split out from...
26394 (vect_gen_prolog_loop_niters): ...here.
26395 (vect_update_init_of_dr): Take a code argument that specifies whether
26396 the adjustment should be added or subtracted.
26397 (vect_update_init_of_drs): Likewise.
26398 (vect_prepare_for_masked_peels): New function.
26399 (vect_do_peeling): Skip prologue peeling if we're using a mask
26400 instead. Update call to vect_update_inits_of_drs.
26401 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26402 mask_skip_niters.
26403 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
26404 alignment. Do not include the number of peeled iterations in
26405 the minimum threshold in that case.
26406 (vectorizable_induction): Adjust the start value down by
26407 LOOP_VINFO_MASK_SKIP_NITERS iterations.
26408 (vect_transform_loop): Call vect_prepare_for_masked_peels.
26409 Take the number of skipped iterations into account when calculating
26410 the loop bounds.
26411 * tree-vect-stmts.c (vect_gen_while_not): New function.
26412
26413 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26414 Alan Hayward <alan.hayward@arm.com>
26415 David Sherwood <david.sherwood@arm.com>
26416
26417 * doc/sourcebuild.texi (vect_fully_masked): Document.
26418 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
26419 default value to 0.
26420 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
26421 split out from...
26422 (vect_analyze_loop_2): ...here. Don't check the vectorization
26423 factor against the number of loop iterations if the loop is
26424 fully-masked.
26425
26426 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26427 Alan Hayward <alan.hayward@arm.com>
26428 David Sherwood <david.sherwood@arm.com>
26429
26430 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
26431 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
26432 (dump_groups): Update accordingly.
26433 (iv_use::mem_type): New member variable.
26434 (address_p): New function.
26435 (record_use): Add a mem_type argument and initialize the new
26436 mem_type field.
26437 (record_group_use): Add a mem_type argument. Use address_p.
26438 Remove obsolete null checks of base_object. Update call to record_use.
26439 (find_interesting_uses_op): Update call to record_group_use.
26440 (find_interesting_uses_cond): Likewise.
26441 (find_interesting_uses_address): Likewise.
26442 (get_mem_type_for_internal_fn): New function.
26443 (find_address_like_use): Likewise.
26444 (find_interesting_uses_stmt): Try find_address_like_use before
26445 calling find_interesting_uses_op.
26446 (addr_offset_valid_p): Use the iv mem_type field as the type
26447 of the addressed memory.
26448 (add_autoinc_candidates): Likewise.
26449 (get_address_cost): Likewise.
26450 (split_small_address_groups_p): Use address_p.
26451 (split_address_groups): Likewise.
26452 (add_iv_candidate_for_use): Likewise.
26453 (autoinc_possible_for_pair): Likewise.
26454 (rewrite_groups): Likewise.
26455 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
26456 (determine_group_iv_cost): Update after split of USE_ADDRESS.
26457 (get_alias_ptr_type_for_ptr_address): New function.
26458 (rewrite_use_address): Rewrite address uses in calls that were
26459 identified by find_address_like_use.
26460
26461 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26462 Alan Hayward <alan.hayward@arm.com>
26463 David Sherwood <david.sherwood@arm.com>
26464
26465 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
26466 TARGET_MEM_REFs.
26467 * gimple-expr.h (is_gimple_addressable: Likewise.
26468 * gimple-expr.c (is_gimple_address): Likewise.
26469 * internal-fn.c (expand_call_mem_ref): New function.
26470 (expand_mask_load_optab_fn): Use it.
26471 (expand_mask_store_optab_fn): Likewise.
26472
26473 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26474 Alan Hayward <alan.hayward@arm.com>
26475 David Sherwood <david.sherwood@arm.com>
26476
26477 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
26478 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
26479 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
26480 (cond_umax@var{mode}): Document.
26481 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
26482 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
26483 (cond_umin_optab, cond_umax_optab): New optabs.
26484 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
26485 (COND_IOR, COND_XOR): New internal functions.
26486 * internal-fn.h (get_conditional_internal_fn): Declare.
26487 * internal-fn.c (cond_binary_direct): New macro.
26488 (expand_cond_binary_optab_fn): Likewise.
26489 (direct_cond_binary_optab_supported_p): Likewise.
26490 (get_conditional_internal_fn): New function.
26491 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
26492 Cope with reduction statements that are vectorized as calls rather
26493 than assignments.
26494 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
26495 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
26496 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
26497 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
26498 (UNSPEC_COND_EOR): New unspecs.
26499 (optab): Add mappings for them.
26500 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
26501 (sve_int_op, sve_fp_op): New int attributes.
26502
26503 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26504 Alan Hayward <alan.hayward@arm.com>
26505 David Sherwood <david.sherwood@arm.com>
26506
26507 * optabs.def (while_ult_optab): New optab.
26508 * doc/md.texi (while_ult@var{m}@var{n}): Document.
26509 * internal-fn.def (WHILE_ULT): New internal function.
26510 * internal-fn.h (direct_internal_fn_supported_p): New override
26511 that takes two types as argument.
26512 * internal-fn.c (while_direct): New macro.
26513 (expand_while_optab_fn): New function.
26514 (convert_optab_supported_p): Likewise.
26515 (direct_while_optab_supported_p): New macro.
26516 * wide-int.h (wi::udiv_ceil): New function.
26517 * tree-vectorizer.h (rgroup_masks): New structure.
26518 (vec_loop_masks): New typedef.
26519 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
26520 and fully_masked_p.
26521 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
26522 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
26523 (vect_max_vf): New function.
26524 (slpeel_make_loop_iterate_ntimes): Delete.
26525 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
26526 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
26527 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
26528 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
26529 internal-fn.h, stor-layout.h and optabs-query.h.
26530 (vect_set_loop_mask): New function.
26531 (add_preheader_seq): Likewise.
26532 (add_header_seq): Likewise.
26533 (interleave_supported_p): Likewise.
26534 (vect_maybe_permute_loop_masks): Likewise.
26535 (vect_set_loop_masks_directly): Likewise.
26536 (vect_set_loop_condition_masked): Likewise.
26537 (vect_set_loop_condition_unmasked): New function, split out from
26538 slpeel_make_loop_iterate_ntimes.
26539 (slpeel_make_loop_iterate_ntimes): Rename to..
26540 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
26541 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
26542 (vect_do_peeling): Update call accordingly.
26543 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
26544 loops.
26545 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26546 mask_compare_type, can_fully_mask_p and fully_masked_p.
26547 (release_vec_loop_masks): New function.
26548 (_loop_vec_info): Use it to free the loop masks.
26549 (can_produce_all_loop_masks_p): New function.
26550 (vect_get_max_nscalars_per_iter): Likewise.
26551 (vect_verify_full_masking): Likewise.
26552 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
26553 retries, and free the mask rgroups before retrying. Check loop-wide
26554 reasons for disallowing fully-masked loops. Make the final decision
26555 about whether use a fully-masked loop or not.
26556 (vect_estimate_min_profitable_iters): Do not assume that peeling
26557 for the number of iterations will be needed for fully-masked loops.
26558 (vectorizable_reduction): Disable fully-masked loops.
26559 (vectorizable_live_operation): Likewise.
26560 (vect_halve_mask_nunits): New function.
26561 (vect_double_mask_nunits): Likewise.
26562 (vect_record_loop_mask): Likewise.
26563 (vect_get_loop_mask): Likewise.
26564 (vect_transform_loop): Handle the case in which the final loop
26565 iteration might handle a partial vector. Call vect_set_loop_condition
26566 instead of slpeel_make_loop_iterate_ntimes.
26567 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
26568 (check_load_store_masking): New function.
26569 (prepare_load_store_mask): Likewise.
26570 (vectorizable_store): Handle fully-masked loops.
26571 (vectorizable_load): Likewise.
26572 (supportable_widening_operation): Use vect_halve_mask_nunits for
26573 booleans.
26574 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
26575 (vect_gen_while): New function.
26576 * config/aarch64/aarch64.md (umax<mode>3): New expander.
26577 (aarch64_uqdec<mode>): New insn.
26578
26579 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26580 Alan Hayward <alan.hayward@arm.com>
26581 David Sherwood <david.sherwood@arm.com>
26582
26583 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
26584 (reduc_xor_scal_optab): New optabs.
26585 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
26586 (reduc_xor_scal_@var{m}): Document.
26587 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
26588 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
26589 internal functions.
26590 * fold-const-call.c (fold_const_call): Handle them.
26591 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
26592 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
26593 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
26594 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
26595 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
26596 (UNSPEC_XORV): New unspecs.
26597 (optab): Add entries for them.
26598 (BITWISEV): New int iterator.
26599 (bit_reduc_op): New int attributes.
26600
26601 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26602 Alan Hayward <alan.hayward@arm.com>
26603 David Sherwood <david.sherwood@arm.com>
26604
26605 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
26606 * internal-fn.def (VEC_SHL_INSERT): New internal function.
26607 * optabs.def (vec_shl_insert_optab): New optab.
26608 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
26609 (duplicate_and_interleave): Likewise.
26610 * tree-vect-loop.c: Include internal-fn.h.
26611 (neutral_op_for_slp_reduction): New function, split out from
26612 get_initial_defs_for_reduction.
26613 (get_initial_def_for_reduction): Handle option 2 for variable-length
26614 vectors by loading the neutral value into a vector and then shifting
26615 the initial value into element 0.
26616 (get_initial_defs_for_reduction): Replace the code argument with
26617 the neutral value calculated by neutral_op_for_slp_reduction.
26618 Use gimple_build_vector for constant-length vectors.
26619 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
26620 but the first group_size elements have a neutral value.
26621 Use duplicate_and_interleave otherwise.
26622 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
26623 Update call to get_initial_defs_for_reduction. Handle SLP
26624 reductions for variable-length vectors by creating one vector
26625 result for each scalar result, with the elements associated
26626 with other scalar results stubbed out with the neutral value.
26627 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
26628 Require IFN_VEC_SHL_INSERT for double reductions on
26629 variable-length vectors, or SLP reductions that have
26630 a neutral value. Require can_duplicate_and_interleave_p
26631 support for variable-length unchained SLP reductions if there
26632 is no neutral value, such as for MIN/MAX reductions. Also require
26633 the number of vector elements to be a multiple of the number of
26634 SLP statements when doing variable-length unchained SLP reductions.
26635 Update call to vect_create_epilog_for_reduction.
26636 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
26637 and remove initial values.
26638 (duplicate_and_interleave): Make public.
26639 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
26640 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
26641
26642 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26643 Alan Hayward <alan.hayward@arm.com>
26644 David Sherwood <david.sherwood@arm.com>
26645
26646 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
26647 (can_duplicate_and_interleave_p): New function.
26648 (vect_get_and_check_slp_defs): Take the vector of statements
26649 rather than just the current one. Remove excess parentheses.
26650 Restriction rejectinon of vect_constant_def and vect_external_def
26651 for variable-length vectors to boolean types, or types for which
26652 can_duplicate_and_interleave_p is false.
26653 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
26654 (duplicate_and_interleave): New function.
26655 (vect_get_constant_vectors): Use gimple_build_vector for
26656 constant-length vectors and suitable variable-length constant
26657 vectors. Use duplicate_and_interleave for other variable-length
26658 vectors. Don't defer the update when inserting new statements.
26659
26660 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26661 Alan Hayward <alan.hayward@arm.com>
26662 David Sherwood <david.sherwood@arm.com>
26663
26664 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
26665 min_profitable_iters doesn't go negative.
26666
26667 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26668 Alan Hayward <alan.hayward@arm.com>
26669 David Sherwood <david.sherwood@arm.com>
26670
26671 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
26672 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
26673 * optabs.def (vec_mask_load_lanes_optab): New optab.
26674 (vec_mask_store_lanes_optab): Likewise.
26675 * internal-fn.def (MASK_LOAD_LANES): New internal function.
26676 (MASK_STORE_LANES): Likewise.
26677 * internal-fn.c (mask_load_lanes_direct): New macro.
26678 (mask_store_lanes_direct): Likewise.
26679 (expand_mask_load_optab_fn): Handle masked operations.
26680 (expand_mask_load_lanes_optab_fn): New macro.
26681 (expand_mask_store_optab_fn): Handle masked operations.
26682 (expand_mask_store_lanes_optab_fn): New macro.
26683 (direct_mask_load_lanes_optab_supported_p): Likewise.
26684 (direct_mask_store_lanes_optab_supported_p): Likewise.
26685 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
26686 parameter.
26687 (vect_load_lanes_supported): Likewise.
26688 * tree-vect-data-refs.c (strip_conversion): New function.
26689 (can_group_stmts_p): Likewise.
26690 (vect_analyze_data_ref_accesses): Use it instead of checking
26691 for a pair of assignments.
26692 (vect_store_lanes_supported): Take a masked_p parameter.
26693 (vect_load_lanes_supported): Likewise.
26694 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
26695 vect_store_lanes_supported and vect_load_lanes_supported.
26696 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
26697 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
26698 parameter. Don't allow gaps for masked accesses.
26699 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
26700 and vect_load_lanes_supported.
26701 (get_load_store_type): Take a masked_p parameter and update
26702 call to get_group_load_store_type.
26703 (vectorizable_store): Update call to get_load_store_type.
26704 Handle IFN_MASK_STORE_LANES.
26705 (vectorizable_load): Update call to get_load_store_type.
26706 Handle IFN_MASK_LOAD_LANES.
26707
26708 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26709 Alan Hayward <alan.hayward@arm.com>
26710 David Sherwood <david.sherwood@arm.com>
26711
26712 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
26713 modes for SVE.
26714 * config/aarch64/aarch64-protos.h
26715 (aarch64_sve_struct_memory_operand_p): Declare.
26716 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
26717 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
26718 (VPRED, vpred): Handle SVE structure modes.
26719 * config/aarch64/constraints.md (Utx): New constraint.
26720 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
26721 (aarch64_sve_struct_nonimmediate_operand): New predicates.
26722 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
26723 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
26724 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
26725 structure modes. Split into pieces after RA.
26726 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
26727 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
26728 New patterns.
26729 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
26730 SVE structure modes.
26731 (aarch64_classify_address): Likewise.
26732 (sizetochar): Move earlier in file.
26733 (aarch64_print_operand): Handle SVE register lists.
26734 (aarch64_array_mode): New function.
26735 (aarch64_sve_struct_memory_operand_p): Likewise.
26736 (TARGET_ARRAY_MODE): Redefine.
26737
26738 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26739 Alan Hayward <alan.hayward@arm.com>
26740 David Sherwood <david.sherwood@arm.com>
26741
26742 * target.def (array_mode): New target hook.
26743 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
26744 * doc/tm.texi: Regenerate.
26745 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
26746 * hooks.c (hook_optmode_mode_uhwi_none): New function.
26747 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
26748 targetm.array_mode.
26749 * stor-layout.c (mode_for_array): Likewise. Support polynomial
26750 type sizes.
26751
26752 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26753 Alan Hayward <alan.hayward@arm.com>
26754 David Sherwood <david.sherwood@arm.com>
26755
26756 * fold-const.c (fold_binary_loc): Check the argument types
26757 rather than the result type when testing for a vector operation.
26758
26759 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26760
26761 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
26762 * doc/tm.texi: Regenerate.
26763
26764 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26765 Alan Hayward <alan.hayward@arm.com>
26766 David Sherwood <david.sherwood@arm.com>
26767
26768 * doc/invoke.texi (-msve-vector-bits=): Document new option.
26769 (sve): Document new AArch64 extension.
26770 * doc/md.texi (w): Extend the description of the AArch64
26771 constraint to include SVE vectors.
26772 (Upl, Upa): Document new AArch64 predicate constraints.
26773 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
26774 enum.
26775 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
26776 (msve-vector-bits=): New option.
26777 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
26778 SVE when these are disabled.
26779 (sve): New extension.
26780 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
26781 modes. Adjust their number of units based on aarch64_sve_vg.
26782 (MAX_BITSIZE_MODE_ANY_MODE): Define.
26783 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
26784 aarch64_addr_query_type.
26785 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
26786 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
26787 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
26788 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
26789 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
26790 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
26791 (aarch64_simd_imm_zero_p): Delete.
26792 (aarch64_check_zero_based_sve_index_immediate): Declare.
26793 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26794 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26795 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26796 (aarch64_sve_float_mul_immediate_p): Likewise.
26797 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26798 rather than an rtx.
26799 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
26800 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
26801 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
26802 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
26803 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
26804 (aarch64_regmode_natural_size): Likewise.
26805 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
26806 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
26807 left one place.
26808 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
26809 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
26810 for VG and the SVE predicate registers.
26811 (V_ALIASES): Add a "z"-prefixed alias.
26812 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
26813 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
26814 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
26815 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
26816 (REG_CLASS_NAMES): Add entries for them.
26817 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
26818 and the predicate registers.
26819 (aarch64_sve_vg): Declare.
26820 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
26821 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
26822 (REGMODE_NATURAL_SIZE): Define.
26823 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
26824 SVE macros.
26825 * config/aarch64/aarch64.c: Include cfgrtl.h.
26826 (simd_immediate_info): Add a constructor for series vectors,
26827 and an associated step field.
26828 (aarch64_sve_vg): New variable.
26829 (aarch64_dbx_register_number): Handle VG and the predicate registers.
26830 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
26831 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
26832 (VEC_ANY_DATA, VEC_STRUCT): New constants.
26833 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
26834 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
26835 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
26836 (aarch64_get_mask_mode): New functions.
26837 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
26838 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
26839 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
26840 predicate modes and predicate registers. Explicitly restrict
26841 GPRs to modes of 16 bytes or smaller. Only allow FP registers
26842 to store a vector mode if it is recognized by
26843 aarch64_classify_vector_mode.
26844 (aarch64_regmode_natural_size): New function.
26845 (aarch64_hard_regno_caller_save_mode): Return the original mode
26846 for predicates.
26847 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
26848 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
26849 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
26850 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
26851 functions.
26852 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
26853 does not overlap dest if the function is frame-related. Handle
26854 SVE constants.
26855 (aarch64_split_add_offset): New function.
26856 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
26857 them aarch64_add_offset.
26858 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
26859 and update call to aarch64_sub_sp.
26860 (aarch64_add_cfa_expression): New function.
26861 (aarch64_expand_prologue): Pass extra temporary registers to the
26862 functions above. Handle the case in which we need to emit new
26863 DW_CFA_expressions for registers that were originally saved
26864 relative to the stack pointer, but now have to be expressed
26865 relative to the frame pointer.
26866 (aarch64_output_mi_thunk): Pass extra temporary registers to the
26867 functions above.
26868 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
26869 IP0 and IP1 values for SVE frames.
26870 (aarch64_expand_vec_series): New function.
26871 (aarch64_expand_sve_widened_duplicate): Likewise.
26872 (aarch64_expand_sve_const_vector): Likewise.
26873 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
26874 Handle SVE constants. Use emit_move_insn to move a force_const_mem
26875 into the register, rather than emitting a SET directly.
26876 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
26877 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
26878 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
26879 (offset_9bit_signed_scaled_p): New functions.
26880 (aarch64_replicate_bitmask_imm): New function.
26881 (aarch64_bitmask_imm): Use it.
26882 (aarch64_cannot_force_const_mem): Reject expressions involving
26883 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
26884 (aarch64_classify_index): Handle SVE indices, by requiring
26885 a plain register index with a scale that matches the element size.
26886 (aarch64_classify_address): Handle SVE addresses. Assert that
26887 the mode of the address is VOIDmode or an integer mode.
26888 Update call to aarch64_classify_symbol.
26889 (aarch64_classify_symbolic_expression): Update call to
26890 aarch64_classify_symbol.
26891 (aarch64_const_vec_all_in_range_p): New function.
26892 (aarch64_print_vector_float_operand): Likewise.
26893 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
26894 "vN" for FP registers with SVE modes. Handle (const ...) vectors
26895 and the FP immediates 1.0 and 0.5.
26896 (aarch64_print_address_internal): Handle SVE addresses.
26897 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
26898 (aarch64_regno_regclass): Handle predicate registers.
26899 (aarch64_secondary_reload): Handle big-endian reloads of SVE
26900 data modes.
26901 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
26902 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
26903 (aarch64_convert_sve_vector_bits): New function.
26904 (aarch64_override_options): Use it to handle -msve-vector-bits=.
26905 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26906 rather than an rtx.
26907 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
26908 Handle SVE vector and predicate modes. Accept VL-based constants
26909 that need only one temporary register, and VL offsets that require
26910 no temporary registers.
26911 (aarch64_conditional_register_usage): Mark the predicate registers
26912 as fixed if SVE isn't available.
26913 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
26914 Return true for SVE vector and predicate modes.
26915 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
26916 rather than an unsigned int. Handle SVE modes.
26917 (aarch64_preferred_simd_mode): Update call accordingly. Handle
26918 SVE modes.
26919 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
26920 if SVE is enabled.
26921 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26922 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26923 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26924 (aarch64_sve_float_mul_immediate_p): New functions.
26925 (aarch64_sve_valid_immediate): New function.
26926 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
26927 Explicitly reject structure modes. Check for INDEX constants.
26928 Handle PTRUE and PFALSE constants.
26929 (aarch64_check_zero_based_sve_index_immediate): New function.
26930 (aarch64_simd_imm_zero_p): Delete.
26931 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
26932 vector modes. Accept constants in the range of CNT[BHWD].
26933 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
26934 ask for an Advanced SIMD mode.
26935 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
26936 (aarch64_simd_vector_alignment): Handle SVE predicates.
26937 (aarch64_vectorize_preferred_vector_alignment): New function.
26938 (aarch64_simd_vector_alignment_reachable): Use it instead of
26939 the vector size.
26940 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
26941 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
26942 functions.
26943 (MAX_VECT_LEN): Delete.
26944 (expand_vec_perm_d): Add a vec_flags field.
26945 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
26946 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
26947 (aarch64_evpc_ext): Don't apply a big-endian lane correction
26948 for SVE modes.
26949 (aarch64_evpc_rev): Rename to...
26950 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
26951 (aarch64_evpc_rev_global): New function.
26952 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
26953 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
26954 MAX_VECT_LEN.
26955 (aarch64_evpc_sve_tbl): New function.
26956 (aarch64_expand_vec_perm_const_1): Update after rename of
26957 aarch64_evpc_rev. Handle SVE permutes too, trying
26958 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
26959 than aarch64_evpc_tbl.
26960 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
26961 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
26962 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
26963 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
26964 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
26965 (aarch64_expand_sve_vcond): New functions.
26966 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
26967 of aarch64_vector_mode_p.
26968 (aarch64_dwarf_poly_indeterminate_value): New function.
26969 (aarch64_compute_pressure_classes): Likewise.
26970 (aarch64_can_change_mode_class): Likewise.
26971 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
26972 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
26973 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
26974 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
26975 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
26976 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
26977 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
26978 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
26979 constraints.
26980 (Dn, Dl, Dr): Accept const as well as const_vector.
26981 (Dz): Likewise. Compare against CONST0_RTX.
26982 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
26983 of "vector" where appropriate.
26984 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
26985 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
26986 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
26987 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
26988 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
26989 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
26990 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
26991 (v_int_equiv): Extend to SVE modes.
26992 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
26993 mode attributes.
26994 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
26995 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
26996 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
26997 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
26998 (SVE_COND_FP_CMP): New int iterators.
26999 (perm_hilo): Handle the new unpack unspecs.
27000 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
27001 attributes.
27002 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
27003 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
27004 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
27005 (aarch64_equality_operator, aarch64_constant_vector_operand)
27006 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
27007 (aarch64_sve_nonimmediate_operand): Likewise.
27008 (aarch64_sve_general_operand): Likewise.
27009 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
27010 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
27011 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
27012 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
27013 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
27014 (aarch64_sve_float_arith_immediate): Likewise.
27015 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
27016 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
27017 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
27018 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
27019 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
27020 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
27021 (aarch64_sve_float_arith_operand): Likewise.
27022 (aarch64_sve_float_arith_with_sub_operand): Likewise.
27023 (aarch64_sve_float_mul_operand): Likewise.
27024 (aarch64_sve_vec_perm_operand): Likewise.
27025 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
27026 (aarch64_mov_operand): Accept const_poly_int and const_vector.
27027 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
27028 as well as const_vector.
27029 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
27030 in file. Use CONST0_RTX and CONSTM1_RTX.
27031 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
27032 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
27033 Use aarch64_simd_imm_zero.
27034 * config/aarch64/aarch64-sve.md: New file.
27035 * config/aarch64/aarch64.md: Include it.
27036 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
27037 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
27038 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
27039 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
27040 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
27041 (sve): New attribute.
27042 (enabled): Disable instructions with the sve attribute unless
27043 TARGET_SVE.
27044 (movqi, movhi): Pass CONST_POLY_INT operaneds through
27045 aarch64_expand_mov_immediate.
27046 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
27047 CNT[BHSD] immediates.
27048 (movti): Split CONST_POLY_INT moves into two halves.
27049 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
27050 Split additions that need a temporary here if the destination
27051 is the stack pointer.
27052 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
27053 (*add<mode>3_poly_1): New instruction.
27054 (set_clobber_cc): New expander.
27055
27056 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
27057
27058 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
27059 parameter and use it instead of GET_MODE_SIZE (innermode). Use
27060 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
27061 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
27062 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
27063 Change innermode from fixed_mode_size to machine_mode.
27064 (simplify_subreg): Update call accordingly. Handle a constant-sized
27065 subreg of a variable-length CONST_VECTOR.
27066
27067 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
27068 Alan Hayward <alan.hayward@arm.com>
27069 David Sherwood <david.sherwood@arm.com>
27070
27071 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
27072 (add_offset_to_base): New function, split out from...
27073 (create_mem_ref): ...here. When handling a scale other than 1,
27074 check first whether the address is valid without the offset.
27075 Add it into the base if so, leaving the index and scale as-is.
27076
27077 2018-01-12 Jakub Jelinek <jakub@redhat.com>
27078
27079 PR c++/83778
27080 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
27081 fold_for_warn before checking if arg2 is INTEGER_CST.
27082
27083 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
27084
27085 * config/rs6000/predicates.md (load_multiple_operation): Delete.
27086 (store_multiple_operation): Delete.
27087 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
27088 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
27089 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
27090 guarded by TARGET_STRING.
27091 (rs6000_output_load_multiple): Delete.
27092 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
27093 OPTION_MASK_STRING / TARGET_STRING handling.
27094 (print_operand) <'N', 'O'>: Add comment that these are unused now.
27095 (const rs6000_opt_masks) <"string">: Change mask to 0.
27096 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
27097 (MASK_STRING): Delete.
27098 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
27099 parts. Simplify.
27100 (load_multiple): Delete.
27101 (*ldmsi8): Delete.
27102 (*ldmsi7): Delete.
27103 (*ldmsi6): Delete.
27104 (*ldmsi5): Delete.
27105 (*ldmsi4): Delete.
27106 (*ldmsi3): Delete.
27107 (store_multiple): Delete.
27108 (*stmsi8): Delete.
27109 (*stmsi7): Delete.
27110 (*stmsi6): Delete.
27111 (*stmsi5): Delete.
27112 (*stmsi4): Delete.
27113 (*stmsi3): Delete.
27114 (movmemsi_8reg): Delete.
27115 (corresponding unnamed define_insn): Delete.
27116 (movmemsi_6reg): Delete.
27117 (corresponding unnamed define_insn): Delete.
27118 (movmemsi_4reg): Delete.
27119 (corresponding unnamed define_insn): Delete.
27120 (movmemsi_2reg): Delete.
27121 (corresponding unnamed define_insn): Delete.
27122 (movmemsi_1reg): Delete.
27123 (corresponding unnamed define_insn): Delete.
27124 * config/rs6000/rs6000.opt (mno-string): New.
27125 (mstring): Replace by deprecation warning stub.
27126 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
27127
27128 2018-01-12 Jakub Jelinek <jakub@redhat.com>
27129
27130 * regrename.c (regrename_do_replace): If replacing the same
27131 reg multiple times, try to reuse last created gen_raw_REG.
27132
27133 PR debug/81155
27134 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
27135 main to workaround a bug in GDB.
27136
27137 2018-01-12 Tom de Vries <tom@codesourcery.com>
27138
27139 PR target/83737
27140 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
27141
27142 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
27143
27144 PR rtl-optimization/80481
27145 * ira-color.c (get_cap_member): New function.
27146 (allocnos_conflict_by_live_ranges_p): Use it.
27147 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
27148 (setup_slot_coalesced_allocno_live_ranges): Ditto.
27149
27150 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
27151
27152 PR target/83628
27153 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
27154 (*saddl_se_1): Ditto.
27155 (*ssubsi_1): Ditto.
27156 (*ssubl_se_1): Ditto.
27157
27158 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27159
27160 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
27161 rather than wi::to_widest for DR_INITs.
27162 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
27163 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
27164 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
27165 INTEGER_CSTs.
27166 (vect_analyze_group_access_1): Note that here.
27167
27168 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27169
27170 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
27171 polynomial type sizes.
27172
27173 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27174
27175 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
27176 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
27177 (gimple_add_tmp_var): Likewise.
27178
27179 2018-01-12 Martin Liska <mliska@suse.cz>
27180
27181 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
27182 (gimple_alloc_sizes): Likewise.
27183 (dump_gimple_statistics): Use PRIu64 in printf format.
27184 * gimple.h: Change uint64_t to int.
27185
27186 2018-01-12 Martin Liska <mliska@suse.cz>
27187
27188 * tree-core.h: Use uint64_t instead of int.
27189 * tree.c (tree_node_counts): Likewise.
27190 (tree_node_sizes): Likewise.
27191 (dump_tree_statistics): Use PRIu64 in printf format.
27192
27193 2018-01-12 Martin Liska <mliska@suse.cz>
27194
27195 * Makefile.in: As qsort_chk is implemented in vec.c, add
27196 vec.o to linkage of gencfn-macros.
27197 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
27198 passing the info to record_node_allocation_statistics.
27199 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
27200 and pass the info.
27201 * ggc-common.c (struct ggc_usage): Add operator== and use
27202 it in operator< and compare function.
27203 * mem-stats.h (struct mem_usage): Likewise.
27204 * vec.c (struct vec_usage): Remove operator< and compare
27205 function. Can be simply inherited.
27206
27207 2018-01-12 Martin Jambor <mjambor@suse.cz>
27208
27209 PR target/81616
27210 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
27211 * tree-ssa-math-opts.c: Include domwalk.h.
27212 (convert_mult_to_fma_1): New function.
27213 (fma_transformation_info): New type.
27214 (fma_deferring_state): Likewise.
27215 (cancel_fma_deferring): New function.
27216 (result_of_phi): Likewise.
27217 (last_fma_candidate_feeds_initial_phi): Likewise.
27218 (convert_mult_to_fma): Added deferring logic, split actual
27219 transformation to convert_mult_to_fma_1.
27220 (math_opts_dom_walker): New type.
27221 (math_opts_dom_walker::after_dom_children): New method, body moved
27222 here from pass_optimize_widening_mul::execute, added deferring logic
27223 bits.
27224 (pass_optimize_widening_mul::execute): Moved most of code to
27225 math_opts_dom_walker::after_dom_children.
27226 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
27227 * config/i386/i386.c (ix86_option_override_internal): Added
27228 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
27229
27230 2018-01-12 Richard Biener <rguenther@suse.de>
27231
27232 PR debug/83157
27233 * dwarf2out.c (gen_variable_die): Do not reset old_die for
27234 inline instance vars.
27235
27236 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
27237
27238 PR target/81819
27239 * config/rx/rx.c (rx_is_restricted_memory_address):
27240 Handle SUBREG case.
27241
27242 2018-01-12 Richard Biener <rguenther@suse.de>
27243
27244 PR tree-optimization/80846
27245 * target.def (split_reduction): New target hook.
27246 * targhooks.c (default_split_reduction): New function.
27247 * targhooks.h (default_split_reduction): Declare.
27248 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
27249 target requests first reduce vectors by combining low and high
27250 parts.
27251 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
27252 (get_vectype_for_scalar_type_and_size): Export.
27253 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
27254 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
27255 * doc/tm.texi: Regenerate.
27256 * config/i386/i386.c (ix86_split_reduction): Implement
27257 TARGET_VECTORIZE_SPLIT_REDUCTION.
27258
27259 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27260
27261 PR target/83368
27262 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
27263 in PIC mode except for TARGET_VXWORKS_RTP.
27264 * config/sparc/sparc.c: Include cfgrtl.h.
27265 (TARGET_INIT_PIC_REG): Define.
27266 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
27267 (sparc_pic_register_p): New predicate.
27268 (sparc_legitimate_address_p): Use it.
27269 (sparc_legitimize_pic_address): Likewise.
27270 (sparc_delegitimize_address): Likewise.
27271 (sparc_mode_dependent_address_p): Likewise.
27272 (gen_load_pcrel_sym): Remove 4th parameter.
27273 (load_got_register): Adjust call to above. Remove obsolete stuff.
27274 (sparc_expand_prologue): Do not call load_got_register here.
27275 (sparc_flat_expand_prologue): Likewise.
27276 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
27277 (sparc_use_pseudo_pic_reg): New function.
27278 (sparc_init_pic_reg): Likewise.
27279 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
27280 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
27281
27282 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
27283
27284 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
27285 Add item for branch_cost.
27286
27287 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27288
27289 PR rtl-optimization/83565
27290 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
27291 not extend the result to a larger mode for rotate operations.
27292 (num_sign_bit_copies1): Likewise.
27293
27294 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
27295
27296 PR target/40411
27297 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
27298 -symbolic.
27299 Use values-Xc.o for -pedantic.
27300 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
27301
27302 2018-01-12 Martin Liska <mliska@suse.cz>
27303
27304 PR ipa/83054
27305 * ipa-devirt.c (final_warning_record::grow_type_warnings):
27306 New function.
27307 (possible_polymorphic_call_targets): Use it.
27308 (ipa_devirt): Likewise.
27309
27310 2018-01-12 Martin Liska <mliska@suse.cz>
27311
27312 * profile-count.h (enum profile_quality): Use 0 as invalid
27313 enum value of profile_quality.
27314
27315 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
27316
27317 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
27318 -mext-string options.
27319
27320 2018-01-12 Richard Biener <rguenther@suse.de>
27321
27322 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
27323 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
27324 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
27325 Likewise.
27326 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
27327
27328 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
27329
27330 * configure.ac (--with-long-double-format): Add support for the
27331 configuration option to change the default long double format on
27332 PowerPC systems.
27333 * config.gcc (powerpc*-linux*-*): Likewise.
27334 * configure: Regenerate.
27335 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
27336 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
27337 used without modification.
27338
27339 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27340
27341 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
27342 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
27343 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
27344 MISC_BUILTIN_SPEC_BARRIER.
27345 (rs6000_init_builtins): Likewise.
27346 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
27347 enum value.
27348 (speculation_barrier): New define_insn.
27349 * doc/extend.texi: Document __builtin_speculation_barrier.
27350
27351 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27352
27353 PR target/83203
27354 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
27355 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
27356 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
27357 iterators.
27358 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
27359 integral modes instead of "ss" and "sd".
27360 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
27361 vectors with 32-bit and 64-bit elements.
27362 (vecdupssescalarmodesuffix): New mode attribute.
27363 (vec_dup<mode>): Use it.
27364
27365 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
27366
27367 PR target/83330
27368 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
27369 frame if argument is passed on stack.
27370
27371 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27372
27373 PR target/82682
27374 * ree.c (combine_reaching_defs): Optimize also
27375 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
27376 reg2=any_extend(exp); reg1=reg2;, formatting fix.
27377
27378 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27379
27380 PR middle-end/83189
27381 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
27382
27383 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27384
27385 PR middle-end/83718
27386 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
27387 after they are computed.
27388
27389 2018-01-11 Bin Cheng <bin.cheng@arm.com>
27390
27391 PR tree-optimization/83695
27392 * gimple-loop-linterchange.cc
27393 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
27394 reset cached scev information after interchange.
27395 (pass_linterchange::execute): Remove call to scev_reset_htab.
27396
27397 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27398
27399 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
27400 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
27401 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
27402 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
27403 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
27404 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
27405 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
27406 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
27407 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
27408 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
27409 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
27410 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
27411 (V_lane_reg): Likewise.
27412 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
27413 New define_expand.
27414 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
27415 (vfmal_lane_low<mode>_intrinsic,
27416 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
27417 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
27418 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
27419 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
27420 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
27421 vfmsl_lane_high<mode>_intrinsic): New define_insns.
27422
27423 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27424
27425 * config/arm/arm-cpus.in (fp16fml): New feature.
27426 (ALL_SIMD): Add fp16fml.
27427 (armv8.2-a): Add fp16fml as an option.
27428 (armv8.3-a): Likewise.
27429 (armv8.4-a): Add fp16fml as part of fp16.
27430 * config/arm/arm.h (TARGET_FP16FML): Define.
27431 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
27432 when appropriate.
27433 * config/arm/arm-modes.def (V2HF): Define.
27434 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
27435 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
27436 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
27437 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
27438 vfmsl_low, vfmsl_high): New set of builtins.
27439 * config/arm/iterators.md (PLUSMINUS): New code iterator.
27440 (vfml_op): New code attribute.
27441 (VFMLHALVES): New int iterator.
27442 (VFML, VFMLSEL): New mode attributes.
27443 (V_reg): Define mapping for V2HF.
27444 (V_hi, V_lo): New mode attributes.
27445 (VF_constraint): Likewise.
27446 (vfml_half, vfml_half_selector): New int attributes.
27447 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
27448 define_expand.
27449 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
27450 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
27451 New define_insn.
27452 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
27453 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
27454 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
27455 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
27456 documentation.
27457 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
27458 Document new effective target and option set.
27459
27460 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27461
27462 * config/arm/arm-cpus.in (armv8_4): New feature.
27463 (ARMv8_4a): New fgroup.
27464 (armv8.4-a): New arch.
27465 * config/arm/arm-tables.opt: Regenerate.
27466 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
27467 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
27468 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
27469 Add matching rules for -march=armv8.4-a and extensions.
27470 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
27471
27472 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
27473
27474 PR target/81821
27475 * config/rx/rx.md (BW): New mode attribute.
27476 (sync_lock_test_and_setsi): Add mode suffix to insn output.
27477
27478 2018-01-11 Richard Biener <rguenther@suse.de>
27479
27480 PR tree-optimization/83435
27481 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
27482 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
27483 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
27484
27485 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27486 Alan Hayward <alan.hayward@arm.com>
27487 David Sherwood <david.sherwood@arm.com>
27488
27489 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
27490 field.
27491 (aarch64_classify_address): Initialize it. Track polynomial offsets.
27492 (aarch64_print_address_internal): Use it to check for a zero offset.
27493
27494 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27495 Alan Hayward <alan.hayward@arm.com>
27496 David Sherwood <david.sherwood@arm.com>
27497
27498 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
27499 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
27500 Return a poly_int64 rather than a HOST_WIDE_INT.
27501 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
27502 rather than a HOST_WIDE_INT.
27503 * config/aarch64/aarch64.h (aarch64_frame): Protect with
27504 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
27505 hard_fp_offset, frame_size, initial_adjust, callee_offset and
27506 final_offset from HOST_WIDE_INT to poly_int64.
27507 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
27508 to_constant when getting the number of units in an Advanced SIMD
27509 mode.
27510 (aarch64_builtin_vectorized_function): Check for a constant number
27511 of units.
27512 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
27513 GET_MODE_SIZE.
27514 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
27515 attribute instead of GET_MODE_NUNITS.
27516 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
27517 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
27518 GET_MODE_SIZE for fixed-size registers.
27519 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
27520 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
27521 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
27522 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
27523 (aarch64_print_operand, aarch64_print_address_internal)
27524 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
27525 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
27526 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
27527 Handle polynomial GET_MODE_SIZE.
27528 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
27529 wider than SImode without modification.
27530 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
27531 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
27532 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
27533 passing and returning SVE modes.
27534 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
27535 rather than GEN_INT.
27536 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
27537 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
27538 (aarch64_allocate_and_probe_stack_space): Likewise.
27539 (aarch64_layout_frame): Cope with polynomial offsets.
27540 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
27541 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
27542 polynomial offsets.
27543 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
27544 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
27545 poly_int64 rather than a HOST_WIDE_INT.
27546 (aarch64_get_separate_components, aarch64_process_components)
27547 (aarch64_expand_prologue, aarch64_expand_epilogue)
27548 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
27549 (aarch64_anchor_offset): New function, split out from...
27550 (aarch64_legitimize_address): ...here.
27551 (aarch64_builtin_vectorization_cost): Handle polynomial
27552 TYPE_VECTOR_SUBPARTS.
27553 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
27554 GET_MODE_NUNITS.
27555 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
27556 number of elements from the PARALLEL rather than the mode.
27557 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
27558 rather than GET_MODE_BITSIZE.
27559 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
27560 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
27561 (aarch64_expand_vec_perm_const_1): Handle polynomial
27562 d->perm.length () and d->perm elements.
27563 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
27564 Apply to_constant to d->perm elements.
27565 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
27566 polynomial CONST_VECTOR_NUNITS.
27567 (aarch64_move_pointer): Take amount as a poly_int64 rather
27568 than an int.
27569 (aarch64_progress_pointer): Avoid temporary variable.
27570 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
27571 the mode attribute instead of GET_MODE.
27572
27573 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27574 Alan Hayward <alan.hayward@arm.com>
27575 David Sherwood <david.sherwood@arm.com>
27576
27577 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
27578 x exists before using it.
27579 (aarch64_add_constant_internal): Rename to...
27580 (aarch64_add_offset_1): ...this. Replace regnum with separate
27581 src and dest rtxes. Handle the case in which they're different,
27582 including when the offset is zero. Replace scratchreg with an rtx.
27583 Use 2 additions if there is no spare register into which we can
27584 move a 16-bit constant.
27585 (aarch64_add_constant): Delete.
27586 (aarch64_add_offset): Replace reg with separate src and dest
27587 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
27588 Use aarch64_add_offset_1.
27589 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
27590 an rtx rather than an int. Take the delta as a poly_int64
27591 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
27592 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
27593 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
27594 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
27595 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
27596 and aarch64_add_sp.
27597 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
27598 aarch64_add_constant.
27599
27600 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27601
27602 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
27603 Use scalar_float_mode.
27604
27605 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27606
27607 * config/aarch64/aarch64-simd.md
27608 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
27609 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
27610 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
27611 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
27612 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
27613 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
27614 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
27615 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
27616 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
27617 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
27618
27619 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27620
27621 PR target/83514
27622 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
27623 targ_options->x_arm_arch_string is non NULL.
27624
27625 2018-01-11 Tamar Christina <tamar.christina@arm.com>
27626
27627 * config/aarch64/aarch64.h
27628 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
27629
27630 2018-01-11 Sudakshina Das <sudi.das@arm.com>
27631
27632 PR target/82096
27633 * expmed.c (emit_store_flag_force): Swap if const op0
27634 and change VOIDmode to mode of op0.
27635
27636 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27637
27638 PR rtl-optimization/83761
27639 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
27640 than bytes to mode_for_size.
27641
27642 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27643
27644 PR middle-end/83189
27645 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
27646 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
27647 profile.
27648
27649 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27650
27651 PR middle-end/83575
27652 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
27653 when in layout mode.
27654 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
27655 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
27656 partition fixup.
27657
27658 2018-01-10 Michael Collison <michael.collison@arm.com>
27659
27660 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
27661 * config/aarch64/aarch64-option-extension.def: Add
27662 AARCH64_OPT_EXTENSION of 'fp16fml'.
27663 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27664 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
27665 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
27666 * config/aarch64/constraints.md (Ui7): New constraint.
27667 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
27668 (VFMLA_SEL_W): Ditto.
27669 (f16quad): Ditto.
27670 (f16mac1): Ditto.
27671 (VFMLA16_LOW): New int iterator.
27672 (VFMLA16_HIGH): Ditto.
27673 (UNSPEC_FMLAL): New unspec.
27674 (UNSPEC_FMLSL): Ditto.
27675 (UNSPEC_FMLAL2): Ditto.
27676 (UNSPEC_FMLSL2): Ditto.
27677 (f16mac): New code attribute.
27678 * config/aarch64/aarch64-simd-builtins.def
27679 (aarch64_fmlal_lowv2sf): Ditto.
27680 (aarch64_fmlsl_lowv2sf): Ditto.
27681 (aarch64_fmlalq_lowv4sf): Ditto.
27682 (aarch64_fmlslq_lowv4sf): Ditto.
27683 (aarch64_fmlal_highv2sf): Ditto.
27684 (aarch64_fmlsl_highv2sf): Ditto.
27685 (aarch64_fmlalq_highv4sf): Ditto.
27686 (aarch64_fmlslq_highv4sf): Ditto.
27687 (aarch64_fmlal_lane_lowv2sf): Ditto.
27688 (aarch64_fmlsl_lane_lowv2sf): Ditto.
27689 (aarch64_fmlal_laneq_lowv2sf): Ditto.
27690 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
27691 (aarch64_fmlalq_lane_lowv4sf): Ditto.
27692 (aarch64_fmlsl_lane_lowv4sf): Ditto.
27693 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
27694 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
27695 (aarch64_fmlal_lane_highv2sf): Ditto.
27696 (aarch64_fmlsl_lane_highv2sf): Ditto.
27697 (aarch64_fmlal_laneq_highv2sf): Ditto.
27698 (aarch64_fmlsl_laneq_highv2sf): Ditto.
27699 (aarch64_fmlalq_lane_highv4sf): Ditto.
27700 (aarch64_fmlsl_lane_highv4sf): Ditto.
27701 (aarch64_fmlalq_laneq_highv4sf): Ditto.
27702 (aarch64_fmlsl_laneq_highv4sf): Ditto.
27703 * config/aarch64/aarch64-simd.md:
27704 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
27705 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27706 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
27707 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27708 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
27709 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
27710 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
27711 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
27712 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
27713 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
27714 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
27715 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
27716 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
27717 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
27718 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
27719 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
27720 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
27721 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
27722 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
27723 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
27724 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
27725 (vfmlsl_low_u32): Ditto.
27726 (vfmlalq_low_u32): Ditto.
27727 (vfmlslq_low_u32): Ditto.
27728 (vfmlal_high_u32): Ditto.
27729 (vfmlsl_high_u32): Ditto.
27730 (vfmlalq_high_u32): Ditto.
27731 (vfmlslq_high_u32): Ditto.
27732 (vfmlal_lane_low_u32): Ditto.
27733 (vfmlsl_lane_low_u32): Ditto.
27734 (vfmlal_laneq_low_u32): Ditto.
27735 (vfmlsl_laneq_low_u32): Ditto.
27736 (vfmlalq_lane_low_u32): Ditto.
27737 (vfmlslq_lane_low_u32): Ditto.
27738 (vfmlalq_laneq_low_u32): Ditto.
27739 (vfmlslq_laneq_low_u32): Ditto.
27740 (vfmlal_lane_high_u32): Ditto.
27741 (vfmlsl_lane_high_u32): Ditto.
27742 (vfmlal_laneq_high_u32): Ditto.
27743 (vfmlsl_laneq_high_u32): Ditto.
27744 (vfmlalq_lane_high_u32): Ditto.
27745 (vfmlslq_lane_high_u32): Ditto.
27746 (vfmlalq_laneq_high_u32): Ditto.
27747 (vfmlslq_laneq_high_u32): Ditto.
27748 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
27749 (AARCH64_FL_FOR_ARCH8_4): New.
27750 (AARCH64_ISA_F16FML): New ISA flag.
27751 (TARGET_F16FML): New feature flag for fp16fml.
27752 (doc/invoke.texi): Document new fp16fml option.
27753
27754 2018-01-10 Michael Collison <michael.collison@arm.com>
27755
27756 * config/aarch64/aarch64-builtins.c:
27757 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
27758 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27759 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
27760 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
27761 (AARCH64_ISA_SHA3): New ISA flag.
27762 (TARGET_SHA3): New feature flag for sha3.
27763 * config/aarch64/iterators.md (sha512_op): New int attribute.
27764 (CRYPTO_SHA512): New int iterator.
27765 (UNSPEC_SHA512H): New unspec.
27766 (UNSPEC_SHA512H2): Ditto.
27767 (UNSPEC_SHA512SU0): Ditto.
27768 (UNSPEC_SHA512SU1): Ditto.
27769 * config/aarch64/aarch64-simd-builtins.def
27770 (aarch64_crypto_sha512hqv2di): New builtin.
27771 (aarch64_crypto_sha512h2qv2di): Ditto.
27772 (aarch64_crypto_sha512su0qv2di): Ditto.
27773 (aarch64_crypto_sha512su1qv2di): Ditto.
27774 (aarch64_eor3qv8hi): Ditto.
27775 (aarch64_rax1qv2di): Ditto.
27776 (aarch64_xarqv2di): Ditto.
27777 (aarch64_bcaxqv8hi): Ditto.
27778 * config/aarch64/aarch64-simd.md:
27779 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
27780 (aarch64_crypto_sha512su0qv2di): Ditto.
27781 (aarch64_crypto_sha512su1qv2di): Ditto.
27782 (aarch64_eor3qv8hi): Ditto.
27783 (aarch64_rax1qv2di): Ditto.
27784 (aarch64_xarqv2di): Ditto.
27785 (aarch64_bcaxqv8hi): Ditto.
27786 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
27787 (vsha512h2q_u64): Ditto.
27788 (vsha512su0q_u64): Ditto.
27789 (vsha512su1q_u64): Ditto.
27790 (veor3q_u16): Ditto.
27791 (vrax1q_u64): Ditto.
27792 (vxarq_u64): Ditto.
27793 (vbcaxq_u16): Ditto.
27794 * config/arm/types.md (crypto_sha512): New type attribute.
27795 (crypto_sha3): Ditto.
27796 (doc/invoke.texi): Document new sha3 option.
27797
27798 2018-01-10 Michael Collison <michael.collison@arm.com>
27799
27800 * config/aarch64/aarch64-builtins.c:
27801 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
27802 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27803 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
27804 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
27805 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
27806 (AARCH64_ISA_SM4): New ISA flag.
27807 (TARGET_SM4): New feature flag for sm4.
27808 * config/aarch64/aarch64-simd-builtins.def
27809 (aarch64_sm3ss1qv4si): Ditto.
27810 (aarch64_sm3tt1aq4si): Ditto.
27811 (aarch64_sm3tt1bq4si): Ditto.
27812 (aarch64_sm3tt2aq4si): Ditto.
27813 (aarch64_sm3tt2bq4si): Ditto.
27814 (aarch64_sm3partw1qv4si): Ditto.
27815 (aarch64_sm3partw2qv4si): Ditto.
27816 (aarch64_sm4eqv4si): Ditto.
27817 (aarch64_sm4ekeyqv4si): Ditto.
27818 * config/aarch64/aarch64-simd.md:
27819 (aarch64_sm3ss1qv4si): Ditto.
27820 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
27821 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
27822 (aarch64_sm4eqv4si): Ditto.
27823 (aarch64_sm4ekeyqv4si): Ditto.
27824 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
27825 (sm3part_op): Ditto.
27826 (CRYPTO_SM3TT): Ditto.
27827 (CRYPTO_SM3PART): Ditto.
27828 (UNSPEC_SM3SS1): New unspec.
27829 (UNSPEC_SM3TT1A): Ditto.
27830 (UNSPEC_SM3TT1B): Ditto.
27831 (UNSPEC_SM3TT2A): Ditto.
27832 (UNSPEC_SM3TT2B): Ditto.
27833 (UNSPEC_SM3PARTW1): Ditto.
27834 (UNSPEC_SM3PARTW2): Ditto.
27835 (UNSPEC_SM4E): Ditto.
27836 (UNSPEC_SM4EKEY): Ditto.
27837 * config/aarch64/constraints.md (Ui2): New constraint.
27838 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
27839 * config/arm/types.md (crypto_sm3): New type attribute.
27840 (crypto_sm4): Ditto.
27841 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
27842 (vsm3tt1aq_u32): Ditto.
27843 (vsm3tt1bq_u32): Ditto.
27844 (vsm3tt2aq_u32): Ditto.
27845 (vsm3tt2bq_u32): Ditto.
27846 (vsm3partw1q_u32): Ditto.
27847 (vsm3partw2q_u32): Ditto.
27848 (vsm4eq_u32): Ditto.
27849 (vsm4ekeyq_u32): Ditto.
27850 (doc/invoke.texi): Document new sm4 option.
27851
27852 2018-01-10 Michael Collison <michael.collison@arm.com>
27853
27854 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
27855 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
27856 (AARCH64_FL_FOR_ARCH8_4): New.
27857 (AARCH64_FL_V8_4): New flag.
27858 (doc/invoke.texi): Document new armv8.4-a option.
27859
27860 2018-01-10 Michael Collison <michael.collison@arm.com>
27861
27862 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27863 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
27864 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
27865 * config/aarch64/aarch64-option-extension.def: Add
27866 AARCH64_OPT_EXTENSION of 'sha2'.
27867 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
27868 (crypto): Disable sha2 and aes if crypto disabled.
27869 (crypto): Enable aes and sha2 if enabled.
27870 (simd): Disable sha2 and aes if simd disabled.
27871 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
27872 New flags.
27873 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
27874 (TARGET_SHA2): New feature flag for sha2.
27875 (TARGET_AES): New feature flag for aes.
27876 * config/aarch64/aarch64-simd.md:
27877 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
27878 conditional on TARGET_AES.
27879 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
27880 (aarch64_crypto_sha1hsi): Make pattern conditional
27881 on TARGET_SHA2.
27882 (aarch64_crypto_sha1hv4si): Ditto.
27883 (aarch64_be_crypto_sha1hv4si): Ditto.
27884 (aarch64_crypto_sha1su1v4si): Ditto.
27885 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
27886 (aarch64_crypto_sha1su0v4si): Ditto.
27887 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
27888 (aarch64_crypto_sha256su0v4si): Ditto.
27889 (aarch64_crypto_sha256su1v4si): Ditto.
27890 (doc/invoke.texi): Document new aes and sha2 options.
27891
27892 2018-01-10 Martin Sebor <msebor@redhat.com>
27893
27894 PR tree-optimization/83781
27895 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
27896 as string arrays.
27897
27898 2018-01-11 Martin Sebor <msebor@gmail.com>
27899 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27900
27901 PR tree-optimization/83501
27902 PR tree-optimization/81703
27903
27904 * tree-ssa-strlen.c (get_string_cst): Rename...
27905 (get_string_len): ...to this. Handle global constants.
27906 (handle_char_store): Adjust.
27907
27908 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
27909 Jim Wilson <jimw@sifive.com>
27910
27911 * config/riscv/riscv-protos.h (riscv_output_return): New.
27912 * config/riscv/riscv.c (struct machine_function): New naked_p field.
27913 (riscv_attribute_table, riscv_output_return),
27914 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
27915 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
27916 (riscv_compute_frame_info): Only compute frame->mask if not a naked
27917 function.
27918 (riscv_expand_prologue): Add early return for naked function.
27919 (riscv_expand_epilogue): Likewise.
27920 (riscv_function_ok_for_sibcall): Return false for naked function.
27921 (riscv_set_current_function): New.
27922 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
27923 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
27924 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
27925 * doc/extend.texi (RISC-V Function Attributes): New.
27926
27927 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
27928
27929 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
27930 check for 128-bit long double before checking TCmode.
27931 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
27932 128-bit long doubles before checking TFmode or TCmode.
27933 (FLOAT128_IBM_P): Likewise.
27934
27935 2018-01-10 Martin Sebor <msebor@redhat.com>
27936
27937 PR tree-optimization/83671
27938 * builtins.c (c_strlen): Unconditionally return zero for the empty
27939 string.
27940 Use -Warray-bounds for warnings.
27941 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
27942 for non-constant array indices with COMPONENT_REF, arrays of
27943 arrays, and pointers to arrays.
27944 (gimple_fold_builtin_strlen): Determine and set length range for
27945 non-constant character arrays.
27946
27947 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
27948
27949 PR middle-end/81897
27950 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
27951 empty blocks.
27952
27953 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
27954
27955 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
27956
27957 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27958
27959 PR target/83399
27960 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
27961 VECTOR_MEM_ALTIVEC_OR_VSX_P.
27962 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
27963 indexed_or_indirect_operand predicate.
27964 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
27965 (*vsx_le_perm_load_v8hi): Likewise.
27966 (*vsx_le_perm_load_v16qi): Likewise.
27967 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
27968 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
27969 (*vsx_le_perm_store_v8hi): Likewise.
27970 (*vsx_le_perm_store_v16qi): Likewise.
27971 (eight unnamed splitters): Likewise.
27972
27973 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27974
27975 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
27976 * config/rs6000/emmintrin.h: Likewise.
27977 * config/rs6000/mmintrin.h: Likewise.
27978 * config/rs6000/xmmintrin.h: Likewise.
27979
27980 2018-01-10 David Malcolm <dmalcolm@redhat.com>
27981
27982 PR c++/43486
27983 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
27984 "public_flag".
27985 * tree.c (tree_nop_conversion): Return true for location wrapper
27986 nodes.
27987 (maybe_wrap_with_location): New function.
27988 (selftest::check_strip_nops): New function.
27989 (selftest::test_location_wrappers): New function.
27990 (selftest::tree_c_tests): Call it.
27991 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
27992 (maybe_wrap_with_location): New decl.
27993 (EXPR_LOCATION_WRAPPER_P): New macro.
27994 (location_wrapper_p): New inline function.
27995 (tree_strip_any_location_wrapper): New inline function.
27996
27997 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
27998
27999 PR target/83735
28000 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
28001 stack_realign_offset for the largest alignment of stack slot
28002 actually used.
28003 (ix86_find_max_used_stack_alignment): New function.
28004 (ix86_finalize_stack_frame_flags): Use it. Set
28005 max_used_stack_alignment if we don't realign stack.
28006 * config/i386/i386.h (machine_function): Add
28007 max_used_stack_alignment.
28008
28009 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
28010
28011 * config/arm/arm.opt (-mbranch-cost): New option.
28012 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
28013 account.
28014
28015 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
28016
28017 PR target/83629
28018 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
28019 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
28020
28021 2018-01-10 Richard Biener <rguenther@suse.de>
28022
28023 PR debug/83765
28024 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
28025 early out so it also covers the case where we have a non-NULL
28026 origin.
28027
28028 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
28029
28030 PR tree-optimization/83753
28031 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
28032 for non-strided grouped accesses if the number of elements is 1.
28033
28034 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
28035
28036 PR target/81616
28037 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
28038 * i386.h (TARGET_USE_GATHER): Define.
28039 * x86-tune.def (X86_TUNE_USE_GATHER): New.
28040
28041 2018-01-10 Martin Liska <mliska@suse.cz>
28042
28043 PR bootstrap/82831
28044 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
28045 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
28046 partitioning.
28047 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
28048 CLEANUP_NO_PARTITIONING is not set.
28049
28050 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
28051
28052 * doc/rtl.texi: Remove documentation of (const ...) wrappers
28053 for vectors, as a partial revert of r254296.
28054 * rtl.h (const_vec_p): Delete.
28055 (const_vec_duplicate_p): Don't test for vector CONSTs.
28056 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
28057 * expmed.c (make_tree): Likewise.
28058
28059 Revert:
28060 * common.md (E, F): Use CONSTANT_P instead of checking for
28061 CONST_VECTOR.
28062 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
28063 checking for CONST_VECTOR.
28064
28065 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28066
28067 PR middle-end/83575
28068 * predict.c (force_edge_cold): Handle in more sane way edges
28069 with no prediction.
28070
28071 2018-01-09 Carl Love <cel@us.ibm.com>
28072
28073 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
28074 V4SI, V4SF types.
28075 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
28076 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
28077 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
28078 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
28079 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
28080 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
28081 * config/rs6000/rs6000-protos.h: Add extern defition for
28082 rs6000_generate_float2_double_code.
28083 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
28084 function.
28085 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
28086 (float2_v2df): Add define_expand.
28087
28088 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
28089
28090 PR target/83628
28091 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
28092 op_mode in the force_to_mode call.
28093
28094 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28095
28096 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
28097 instead of checking each element individually.
28098 (aarch64_evpc_uzp): Likewise.
28099 (aarch64_evpc_zip): Likewise.
28100 (aarch64_evpc_ext): Likewise.
28101 (aarch64_evpc_rev): Likewise.
28102 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
28103 instead of checking each element individually. Return true without
28104 generating rtl if
28105 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
28106 whether all selected elements come from the same input, instead of
28107 checking each element individually. Remove calls to gen_rtx_REG,
28108 start_sequence and end_sequence and instead assert that no rtl is
28109 generated.
28110
28111 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28112
28113 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
28114 order of HIGH and CONST checks.
28115
28116 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28117
28118 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
28119 if the destination isn't an SSA_NAME.
28120
28121 2018-01-09 Richard Biener <rguenther@suse.de>
28122
28123 PR tree-optimization/83668
28124 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
28125 move prologue...
28126 (canonicalize_loop_form): ... here, renamed from ...
28127 (canonicalize_loop_closed_ssa_form): ... this and amended to
28128 swap successor edges for loop exit blocks to make us use
28129 the RPO order we need for initial schedule generation.
28130
28131 2018-01-09 Joseph Myers <joseph@codesourcery.com>
28132
28133 PR tree-optimization/64811
28134 * match.pd: When optimizing comparisons with Inf, avoid
28135 introducing or losing exceptions from comparisons with NaN.
28136
28137 2018-01-09 Martin Liska <mliska@suse.cz>
28138
28139 PR sanitizer/82517
28140 * asan.c (shadow_mem_size): Add gcc_assert.
28141
28142 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
28143
28144 Don't save registers in main().
28145
28146 PR target/83738
28147 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
28148 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
28149 * config/avr/avr.c (avr_set_current_function): Don't error if
28150 naked, OS_task or OS_main are specified at the same time.
28151 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
28152 OS_main.
28153 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
28154 attribute.
28155 * common/config/avr/avr-common.c (avr_option_optimization_table):
28156 Switch on -mmain-is-OS_task for optimizing compilations.
28157
28158 2018-01-09 Richard Biener <rguenther@suse.de>
28159
28160 PR tree-optimization/83572
28161 * graphite.c: Include cfganal.h.
28162 (graphite_transform_loops): Connect infinite loops to exit
28163 and remove fake edges at the end.
28164
28165 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28166
28167 * ipa-inline.c (edge_badness): Revert accidental checkin.
28168
28169 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28170
28171 PR ipa/80763
28172 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
28173 symbols; not inline clones.
28174
28175 2018-01-09 Jakub Jelinek <jakub@redhat.com>
28176
28177 PR target/83507
28178 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
28179 hard registers. Formatting fixes.
28180
28181 PR preprocessor/83722
28182 * gcc.c (try_generate_repro): Pass
28183 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
28184 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
28185 do_report_bug.
28186
28187 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
28188 Kito Cheng <kito.cheng@gmail.com>
28189
28190 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
28191 (riscv_leaf_function_p): Delete.
28192 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
28193
28194 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28195
28196 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
28197 function.
28198 (do_ifelse): New function.
28199 (do_isel): New function.
28200 (do_sub3): New function.
28201 (do_add3): New function.
28202 (do_load_mask_compare): New function.
28203 (do_overlap_load_compare): New function.
28204 (expand_compare_loop): New function.
28205 (expand_block_compare): Call expand_compare_loop() when appropriate.
28206 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
28207 option description.
28208 (-mblock-compare-inline-loop-limit): New option.
28209
28210 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
28211
28212 PR target/83677
28213 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
28214 Reverse order of second and third operands in first alternative.
28215 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
28216 of first and second elements in UNSPEC_VPERMR vector.
28217 (altivec_expand_vec_perm_le): Likewise.
28218
28219 2018-01-08 Jeff Law <law@redhat.com>
28220
28221 PR rtl-optimizatin/81308
28222 * tree-switch-conversion.c (cfg_altered): New file scoped static.
28223 (process_switch): If group_case_labels makes a change, then set
28224 cfg_altered.
28225 (pass_convert_switch::execute): If a switch is converted, then
28226 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
28227
28228 PR rtl-optimization/81308
28229 * recog.c (split_all_insns): Conditionally cleanup the CFG after
28230 splitting insns.
28231
28232 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
28233
28234 PR target/83663 - Revert r255946
28235 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
28236 generation for cases where splatting a value is not useful.
28237 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
28238 across a vec_duplicate and a paradoxical subreg forming a vector
28239 mode to a vec_concat.
28240
28241 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
28242
28243 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
28244 -march=armv8.3-a variants.
28245 * config/arm/t-multilib: Likewise.
28246 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
28247
28248 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28249
28250 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
28251 to generate rtl.
28252 (cceq_ior_compare_complement): Give it a name so I can use it, and
28253 change boolean_or_operator predicate to boolean_operator so it can
28254 be used to generate a crand.
28255 (eqne): New code iterator.
28256 (bd/bd_neg): New code_attrs.
28257 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
28258 a single define_insn.
28259 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
28260 decrement (bdnzt/bdnzf/bdzt/bdzf).
28261 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
28262 with the new names of the branch decrement patterns, and added the
28263 names of the branch decrement conditional patterns.
28264
28265 2018-01-08 Richard Biener <rguenther@suse.de>
28266
28267 PR tree-optimization/83563
28268 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
28269 cache.
28270
28271 2018-01-08 Richard Biener <rguenther@suse.de>
28272
28273 PR middle-end/83713
28274 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
28275
28276 2018-01-08 Richard Biener <rguenther@suse.de>
28277
28278 PR tree-optimization/83685
28279 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
28280 references to abnormals.
28281
28282 2018-01-08 Richard Biener <rguenther@suse.de>
28283
28284 PR lto/83719
28285 * dwarf2out.c (output_indirect_strings): Handle empty
28286 skeleton_debug_str_hash.
28287 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
28288
28289 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28290
28291 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
28292 (emit_store_direct): Likewise.
28293 (arc_trampoline_adjust_address): Likewise.
28294 (arc_asm_trampoline_template): New function.
28295 (arc_initialize_trampoline): Use asm_trampoline_template.
28296 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
28297 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
28298 * config/arc/arc.md (flush_icache): Delete pattern.
28299
28300 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28301
28302 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
28303 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
28304 munaligned-access.
28305
28306 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28307
28308 PR target/83681
28309 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
28310 by not USED_FOR_TARGET.
28311 (make_pass_resolve_sw_modes): Likewise.
28312
28313 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28314
28315 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
28316 USED_FOR_TARGET.
28317
28318 2018-01-08 Richard Biener <rguenther@suse.de>
28319
28320 PR middle-end/83580
28321 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
28322
28323 2018-01-08 Richard Biener <rguenther@suse.de>
28324
28325 PR middle-end/83517
28326 * match.pd ((t * 2) / 2) -> t): Add missing :c.
28327
28328 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
28329
28330 PR middle-end/81897
28331 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
28332 basic blocks with a small number of successors.
28333 (convert_control_dep_chain_into_preds): Improve handling of
28334 forwarder blocks.
28335 (dump_predicates): Split apart into...
28336 (dump_pred_chain): ...here...
28337 (dump_pred_info): ...and here.
28338 (can_one_predicate_be_invalidated_p): Add debugging printfs.
28339 (can_chain_union_be_invalidated_p): Improve check for invalidation
28340 of paths.
28341 (uninit_uses_cannot_happen): Avoid unnecessary if
28342 convert_control_dep_chain_into_preds yielded nothing.
28343
28344 2018-01-06 Martin Sebor <msebor@redhat.com>
28345
28346 PR tree-optimization/83640
28347 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
28348 subtracting negative offset from size.
28349 (builtin_access::overlap): Adjust offset bounds of the access to fall
28350 within the size of the object if possible.
28351
28352 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
28353
28354 PR rtl-optimization/83699
28355 * expmed.c (extract_bit_field_1): Restrict the vector usage of
28356 extract_bit_field_as_subreg to cases in which the extracted
28357 value is also a vector.
28358
28359 * lra-constraints.c (process_alt_operands): Test for the equivalence
28360 substitutions when detecting a possible reload cycle.
28361
28362 2018-01-06 Jakub Jelinek <jakub@redhat.com>
28363
28364 PR debug/83480
28365 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
28366 by default if flag_selective_schedling{,2}. Formatting fixes.
28367
28368 PR rtl-optimization/83682
28369 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
28370 if it has non-VECTOR_MODE element mode.
28371 (vec_duplicate_p): Likewise.
28372
28373 PR middle-end/83694
28374 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
28375 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
28376
28377 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28378
28379 PR target/83604
28380 * config/i386/i386-builtin.def
28381 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
28382 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
28383 Require also OPTION_MASK_ISA_AVX512F in addition to
28384 OPTION_MASK_ISA_GFNI.
28385 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
28386 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
28387 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
28388 to OPTION_MASK_ISA_GFNI.
28389 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
28390 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
28391 OPTION_MASK_ISA_AVX512BW.
28392 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
28393 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
28394 addition to OPTION_MASK_ISA_GFNI.
28395 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
28396 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
28397 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
28398 to OPTION_MASK_ISA_GFNI.
28399 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
28400 a requirement for all ISAs rather than any of them with a few
28401 exceptions.
28402 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
28403 processing.
28404 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
28405 bitmasks to be enabled with 3 exceptions, instead of requiring any
28406 enabled ISA with lots of exceptions.
28407 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
28408 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
28409 Change avx512bw in isa attribute to avx512f.
28410 * config/i386/sgxintrin.h: Add license boilerplate.
28411 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
28412 to __AVX512F__ and __AVX512VL to __AVX512VL__.
28413 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
28414 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
28415 defined.
28416 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
28417 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
28418 temporarily sse2 rather than sse if not enabled already.
28419
28420 PR target/83604
28421 * config/i386/sse.md (VI248_VLBW): Rename to ...
28422 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
28423 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
28424 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
28425 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
28426 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
28427 mode iterator instead of VI248_VLBW.
28428
28429 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
28430
28431 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
28432 (record_modified): Skip clobbers; add debug output.
28433 (param_change_prob): Use sreal frequencies.
28434
28435 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28436
28437 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
28438 punt for user-aligned variables.
28439
28440 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28441
28442 * tree-chrec.c (chrec_contains_symbols): Return true for
28443 POLY_INT_CST.
28444
28445 2018-01-05 Sudakshina Das <sudi.das@arm.com>
28446
28447 PR target/82439
28448 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
28449 of (x|y) == x for BICS pattern.
28450
28451 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28452
28453 PR tree-optimization/83605
28454 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
28455 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
28456 can throw.
28457
28458 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
28459
28460 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
28461 * config/epiphany/rtems.h: New file.
28462
28463 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28464 Uros Bizjak <ubizjak@gmail.com>
28465
28466 PR target/83554
28467 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
28468 QIreg_operand instead of register_operand predicate.
28469 * config/i386/i386.c (ix86_rop_should_change_byte_p,
28470 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
28471 comments instead of -fmitigate[-_]rop.
28472
28473 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
28474
28475 PR bootstrap/81926
28476 * cgraphunit.c (symbol_table::compile): Switch to text_section
28477 before calling assembly_start debug hook.
28478 * run-rtl-passes.c (run_rtl_passes): Likewise.
28479 Include output.h.
28480
28481 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28482
28483 * tree-vrp.c (extract_range_from_binary_expr_1): Check
28484 range_int_cst_p rather than !symbolic_range_p before calling
28485 extract_range_from_multiplicative_op_1.
28486
28487 2018-01-04 Jeff Law <law@redhat.com>
28488
28489 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
28490 redundant test in assertion.
28491
28492 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28493
28494 * doc/rtl.texi: Document machine_mode wrapper classes.
28495
28496 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28497
28498 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
28499 using tree_to_uhwi.
28500
28501 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28502
28503 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
28504 the VEC_PERM_EXPR fold to fail.
28505
28506 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28507
28508 PR debug/83585
28509 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
28510 to switched_sections.
28511
28512 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28513
28514 PR target/83680
28515 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
28516 test for d.testing.
28517
28518 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
28519
28520 PR target/83387
28521 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
28522 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
28523
28524 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28525
28526 PR debug/83666
28527 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
28528 is BLKmode and bitpos not zero or mode change is needed.
28529
28530 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28531
28532 PR target/83675
28533 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
28534 TARGET_VIS2.
28535
28536 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
28537
28538 PR target/83628
28539 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
28540 instead of MULT rtx. Update all corresponding splitters.
28541 (*saddl_se): Ditto.
28542 (*ssub<modesuffix>): Ditto.
28543 (*ssubl_se): Ditto.
28544 (*cmp_sadd_di): Update split patterns.
28545 (*cmp_sadd_si): Ditto.
28546 (*cmp_sadd_sidi): Ditto.
28547 (*cmp_ssub_di): Ditto.
28548 (*cmp_ssub_si): Ditto.
28549 (*cmp_ssub_sidi): Ditto.
28550 * config/alpha/predicates.md (const23_operand): New predicate.
28551 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
28552 Look for ASHIFT, not MULT inner operand.
28553 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
28554
28555 2018-01-04 Martin Liska <mliska@suse.cz>
28556
28557 PR gcov-profile/83669
28558 * gcov.c (output_intermediate_file): Add version to intermediate
28559 gcov file.
28560 * doc/gcov.texi: Document new field 'version' in intermediate
28561 file format. Fix location of '-k' option of gcov command.
28562
28563 2018-01-04 Martin Liska <mliska@suse.cz>
28564
28565 PR ipa/82352
28566 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
28567
28568 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28569
28570 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
28571
28572 2018-01-03 Martin Sebor <msebor@redhat.com>
28573
28574 PR tree-optimization/83655
28575 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
28576 checking calls with invalid arguments.
28577
28578 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28579
28580 * tree-vect-stmts.c (vect_get_store_rhs): New function.
28581 (vectorizable_mask_load_store): Delete.
28582 (vectorizable_call): Return false for masked loads and stores.
28583 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
28584 instead of gimple_assign_rhs1.
28585 (vectorizable_load): Handle IFN_MASK_LOAD.
28586 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
28587
28588 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28589
28590 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
28591 split out from..,
28592 (vectorizable_mask_load_store): ...here.
28593 (vectorizable_load): ...and here.
28594
28595 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28596
28597 * tree-vect-stmts.c (vect_build_all_ones_mask)
28598 (vect_build_zero_merge_argument): New functions, split out from...
28599 (vectorizable_load): ...here.
28600
28601 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28602
28603 * tree-vect-stmts.c (vect_check_store_rhs): New function,
28604 split out from...
28605 (vectorizable_mask_load_store): ...here.
28606 (vectorizable_store): ...and here.
28607
28608 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28609
28610 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
28611 split out from...
28612 (vectorizable_mask_load_store): ...here.
28613
28614 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28615
28616 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
28617 (vect_model_store_cost): Take a vec_load_store_type instead of a
28618 vect_def_type.
28619 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
28620 (vect_model_store_cost): Take a vec_load_store_type instead of a
28621 vect_def_type.
28622 (vectorizable_mask_load_store): Update accordingly.
28623 (vectorizable_store): Likewise.
28624 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
28625
28626 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28627
28628 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
28629 IFN_MASK_LOAD calls here rather than...
28630 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
28631
28632 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28633 Alan Hayward <alan.hayward@arm.com>
28634 David Sherwood <david.sherwood@arm.com>
28635
28636 * expmed.c (extract_bit_field_1): For vector extracts,
28637 fall back to extract_bit_field_as_subreg if vec_extract
28638 isn't available.
28639
28640 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28641 Alan Hayward <alan.hayward@arm.com>
28642 David Sherwood <david.sherwood@arm.com>
28643
28644 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
28645 they are variable or constant sized.
28646 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
28647 slots for constant-sized data.
28648
28649 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28650 Alan Hayward <alan.hayward@arm.com>
28651 David Sherwood <david.sherwood@arm.com>
28652
28653 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
28654 handling COND_EXPRs with boolean comparisons, try to find a better
28655 basis for the mask type than the boolean itself.
28656
28657 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28658
28659 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
28660 is calculated and how it can be overridden.
28661 * genmodes.c (max_bitsize_mode_any_mode): New variable.
28662 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
28663 if defined.
28664 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
28665 if nonzero.
28666
28667 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28668 Alan Hayward <alan.hayward@arm.com>
28669 David Sherwood <david.sherwood@arm.com>
28670
28671 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
28672 Remove the mode argument.
28673 (aarch64_simd_valid_immediate): Remove the mode and inverse
28674 arguments.
28675 * config/aarch64/iterators.md (bitsize): New iterator.
28676 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
28677 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
28678 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
28679 aarch64_simd_valid_immediate.
28680 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
28681 (aarch64_reg_or_bic_imm): Likewise.
28682 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
28683 with an insn_type enum and msl with a modifier_type enum.
28684 Replace element_width with a scalar_mode. Change the shift
28685 to unsigned int. Add constructors for scalar_float_mode and
28686 scalar_int_mode elements.
28687 (aarch64_vect_float_const_representable_p): Delete.
28688 (aarch64_can_const_movi_rtx_p)
28689 (aarch64_simd_scalar_immediate_valid_for_move)
28690 (aarch64_simd_make_constant): Update call to
28691 aarch64_simd_valid_immediate.
28692 (aarch64_advsimd_valid_immediate_hs): New function.
28693 (aarch64_advsimd_valid_immediate): Likewise.
28694 (aarch64_simd_valid_immediate): Remove mode and inverse
28695 arguments. Rewrite to use the above. Use const_vec_duplicate_p
28696 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
28697 and aarch64_float_const_representable_p on the result.
28698 (aarch64_output_simd_mov_immediate): Remove mode argument.
28699 Update call to aarch64_simd_valid_immediate and use of
28700 simd_immediate_info.
28701 (aarch64_output_scalar_simd_mov_immediate): Update call
28702 accordingly.
28703
28704 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28705 Alan Hayward <alan.hayward@arm.com>
28706 David Sherwood <david.sherwood@arm.com>
28707
28708 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
28709 (mode_nunits): Likewise CONST_MODE_NUNITS.
28710 * machmode.def (ADJUST_NUNITS): Document.
28711 * genmodes.c (mode_data::need_nunits_adj): New field.
28712 (blank_mode): Update accordingly.
28713 (adj_nunits): New variable.
28714 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
28715 parameter.
28716 (emit_mode_size_inline): Set need_bytesize_adj for all modes
28717 listed in adj_nunits.
28718 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
28719 listed in adj_nunits. Don't emit case statements for such modes.
28720 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
28721 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
28722 nothing if adj_nunits is nonnull.
28723 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
28724 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
28725 (emit_mode_fbit): Update use of print_maybe_const_decl.
28726 (emit_move_size): Likewise. Treat the array as non-const
28727 if adj_nunits.
28728 (emit_mode_adjustments): Handle adj_nunits.
28729
28730 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28731
28732 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
28733 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
28734 (VECTOR_MODES): Use it.
28735 (make_vector_modes): Take the prefix as an argument.
28736
28737 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28738 Alan Hayward <alan.hayward@arm.com>
28739 David Sherwood <david.sherwood@arm.com>
28740
28741 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
28742 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
28743 for MODE_VECTOR_BOOL.
28744 * machmode.def (VECTOR_BOOL_MODE): Document.
28745 * genmodes.c (VECTOR_BOOL_MODE): New macro.
28746 (make_vector_bool_mode): New function.
28747 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
28748 MODE_VECTOR_BOOL.
28749 * lto-streamer-in.c (lto_input_mode_table): Likewise.
28750 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
28751 Likewise.
28752 * stor-layout.c (int_mode_for_mode): Likewise.
28753 * tree.c (build_vector_type_for_mode): Likewise.
28754 * varasm.c (output_constant_pool_2): Likewise.
28755 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
28756 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
28757 for MODE_VECTOR_BOOL.
28758 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
28759 of mode class checks.
28760 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
28761 instead of a list of mode class checks.
28762 (expand_vector_scalar_condition): Likewise.
28763 (type_for_widest_vector_mode): Handle BImode as an inner mode.
28764
28765 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28766 Alan Hayward <alan.hayward@arm.com>
28767 David Sherwood <david.sherwood@arm.com>
28768
28769 * machmode.h (mode_size): Change from unsigned short to
28770 poly_uint16_pod.
28771 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
28772 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28773 or if measurement_type is not polynomial.
28774 (fixed_size_mode::includes_p): Check for constant-sized modes.
28775 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
28776 return a poly_uint16 rather than an unsigned short.
28777 (emit_mode_size): Change the type of mode_size from unsigned short
28778 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
28779 (emit_mode_adjustments): Cope with polynomial vector sizes.
28780 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28781 for GET_MODE_SIZE.
28782 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28783 for GET_MODE_SIZE.
28784 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
28785 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
28786 * caller-save.c (setup_save_areas): Likewise.
28787 (replace_reg_with_saved_mem): Likewise.
28788 * calls.c (emit_library_call_value_1): Likewise.
28789 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
28790 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
28791 (gen_lowpart_for_combine): Likewise.
28792 * convert.c (convert_to_integer_1): Likewise.
28793 * cse.c (equiv_constant, cse_insn): Likewise.
28794 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
28795 (cselib_subst_to_values): Likewise.
28796 * dce.c (word_dce_process_block): Likewise.
28797 * df-problems.c (df_word_lr_mark_ref): Likewise.
28798 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
28799 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
28800 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
28801 (rtl_for_decl_location): Likewise.
28802 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
28803 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
28804 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
28805 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
28806 (expand_expr_real_1): Likewise.
28807 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
28808 (pad_below): Likewise.
28809 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28810 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
28811 * ira.c (get_subreg_tracking_sizes): Likewise.
28812 * ira-build.c (ira_create_allocno_objects): Likewise.
28813 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
28814 (ira_sort_regnos_for_alter_reg): Likewise.
28815 * ira-costs.c (record_operand_costs): Likewise.
28816 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
28817 (resolve_simple_move): Likewise.
28818 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
28819 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
28820 (lra_constraints): Likewise.
28821 (CONST_POOL_OK_P): Reject variable-sized modes.
28822 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
28823 (add_pseudo_to_slot, lra_spill): Likewise.
28824 * omp-low.c (omp_clause_aligned_alignment): Likewise.
28825 * optabs-query.c (get_best_extraction_insn): Likewise.
28826 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
28827 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
28828 (expand_mult_highpart, valid_multiword_target_p): Likewise.
28829 * recog.c (offsettable_address_addr_space_p): Likewise.
28830 * regcprop.c (maybe_mode_change): Likewise.
28831 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
28832 * regrename.c (build_def_use): Likewise.
28833 * regstat.c (dump_reg_info): Likewise.
28834 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
28835 (find_reloads, find_reloads_subreg_address): Likewise.
28836 * reload1.c (eliminate_regs_1): Likewise.
28837 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
28838 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
28839 (simplify_binary_operation_1, simplify_subreg): Likewise.
28840 * targhooks.c (default_function_arg_padding): Likewise.
28841 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
28842 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
28843 (verify_gimple_assign_ternary): Likewise.
28844 * tree-inline.c (estimate_move_cost): Likewise.
28845 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28846 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
28847 (get_address_cost_ainc): Likewise.
28848 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
28849 (vect_supportable_dr_alignment): Likewise.
28850 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28851 (vectorizable_reduction): Likewise.
28852 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
28853 (vectorizable_operation, vectorizable_load): Likewise.
28854 * tree.c (build_same_sized_truth_vector_type): Likewise.
28855 * valtrack.c (cleanup_auto_inc_dec): Likewise.
28856 * var-tracking.c (emit_note_insn_var_location): Likewise.
28857 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
28858 (ADDR_VEC_ALIGN): Likewise.
28859
28860 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28861 Alan Hayward <alan.hayward@arm.com>
28862 David Sherwood <david.sherwood@arm.com>
28863
28864 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
28865 unsigned short.
28866 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28867 or if measurement_type is polynomial.
28868 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
28869 * combine.c (make_extraction): Likewise.
28870 * dse.c (find_shift_sequence): Likewise.
28871 * dwarf2out.c (mem_loc_descriptor): Likewise.
28872 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
28873 (extract_bit_field, extract_low_bits): Likewise.
28874 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
28875 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
28876 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
28877 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
28878 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28879 * reload.c (find_reloads): Likewise.
28880 * reload1.c (alter_reg): Likewise.
28881 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
28882 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
28883 * tree-if-conv.c (predicate_mem_writes): Likewise.
28884 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
28885 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
28886 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
28887 * valtrack.c (dead_debug_insert_temp): Likewise.
28888 * varasm.c (mergeable_constant_section): Likewise.
28889 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
28890
28891 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28892 Alan Hayward <alan.hayward@arm.com>
28893 David Sherwood <david.sherwood@arm.com>
28894
28895 * expr.c (expand_assignment): Cope with polynomial mode sizes
28896 when assigning to a CONCAT.
28897
28898 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28899 Alan Hayward <alan.hayward@arm.com>
28900 David Sherwood <david.sherwood@arm.com>
28901
28902 * machmode.h (mode_precision): Change from unsigned short to
28903 poly_uint16_pod.
28904 (mode_to_precision): Return a poly_uint16 rather than an unsigned
28905 short.
28906 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
28907 or if measurement_type is not polynomial.
28908 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
28909 in which the mode is already known to be a scalar_int_mode.
28910 * genmodes.c (emit_mode_precision): Change the type of mode_precision
28911 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
28912 initializer.
28913 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28914 for GET_MODE_PRECISION.
28915 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28916 for GET_MODE_PRECISION.
28917 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
28918 as polynomial.
28919 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
28920 (expand_field_assignment, make_extraction): Likewise.
28921 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
28922 (get_last_value): Likewise.
28923 * convert.c (convert_to_integer_1): Likewise.
28924 * cse.c (cse_insn): Likewise.
28925 * expr.c (expand_expr_real_1): Likewise.
28926 * lra-constraints.c (simplify_operand_subreg): Likewise.
28927 * optabs-query.c (can_atomic_load_p): Likewise.
28928 * optabs.c (expand_atomic_load): Likewise.
28929 (expand_atomic_store): Likewise.
28930 * ree.c (combine_reaching_defs): Likewise.
28931 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
28932 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
28933 * tree.h (type_has_mode_precision_p): Likewise.
28934 * ubsan.c (instrument_si_overflow): Likewise.
28935
28936 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28937 Alan Hayward <alan.hayward@arm.com>
28938 David Sherwood <david.sherwood@arm.com>
28939
28940 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
28941 polynomial numbers of units.
28942 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
28943 (valid_vector_subparts_p): New function.
28944 (build_vector_type): Remove temporary shim and take the number
28945 of units as a poly_uint64 rather than an int.
28946 (build_opaque_vector_type): Take the number of units as a
28947 poly_uint64 rather than an int.
28948 * tree.c (build_vector_from_ctor): Handle polynomial
28949 TYPE_VECTOR_SUBPARTS.
28950 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
28951 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
28952 (build_vector_from_val): If the number of units is variable,
28953 use build_vec_duplicate_cst for constant operands and
28954 VEC_DUPLICATE_EXPR otherwise.
28955 (make_vector_type): Remove temporary is_constant ().
28956 (build_vector_type, build_opaque_vector_type): Take the number of
28957 units as a poly_uint64 rather than an int.
28958 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
28959 VECTOR_CST_NELTS.
28960 * cfgexpand.c (expand_debug_expr): Likewise.
28961 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
28962 (store_constructor, expand_expr_real_1): Likewise.
28963 (const_scalar_mask_from_tree): Likewise.
28964 * fold-const-call.c (fold_const_reduction): Likewise.
28965 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
28966 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
28967 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
28968 (fold_relational_const): Likewise.
28969 (native_interpret_vector): Likewise. Change the size from an
28970 int to an unsigned int.
28971 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
28972 TYPE_VECTOR_SUBPARTS.
28973 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
28974 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
28975 duplicating a non-constant operand into a variable-length vector.
28976 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
28977 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
28978 * ipa-icf.c (sem_variable::equals): Likewise.
28979 * match.pd: Likewise.
28980 * omp-simd-clone.c (simd_clone_subparts): Likewise.
28981 * print-tree.c (print_node): Likewise.
28982 * stor-layout.c (layout_type): Likewise.
28983 * targhooks.c (default_builtin_vectorization_cost): Likewise.
28984 * tree-cfg.c (verify_gimple_comparison): Likewise.
28985 (verify_gimple_assign_binary): Likewise.
28986 (verify_gimple_assign_ternary): Likewise.
28987 (verify_gimple_assign_single): Likewise.
28988 * tree-pretty-print.c (dump_generic_node): Likewise.
28989 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28990 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
28991 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
28992 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
28993 (vect_shift_permute_load_chain): Likewise.
28994 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
28995 (expand_vector_condition, optimize_vector_constructor): Likewise.
28996 (lower_vec_perm, get_compute_type): Likewise.
28997 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28998 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
28999 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
29000 (vect_recog_mask_conversion_pattern): Likewise.
29001 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
29002 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
29003 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29004 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
29005 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
29006 (vectorizable_shift, vectorizable_operation, vectorizable_store)
29007 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
29008 (supportable_widening_operation): Likewise.
29009 (supportable_narrowing_operation): Likewise.
29010 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
29011 Likewise.
29012 * varasm.c (output_constant): Likewise.
29013
29014 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29015 Alan Hayward <alan.hayward@arm.com>
29016 David Sherwood <david.sherwood@arm.com>
29017
29018 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
29019 so that both the length == 3 and length != 3 cases set up their
29020 own permute vectors. Add comments explaining why we know the
29021 number of elements is constant.
29022 (vect_permute_load_chain): Likewise.
29023
29024 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29025 Alan Hayward <alan.hayward@arm.com>
29026 David Sherwood <david.sherwood@arm.com>
29027
29028 * machmode.h (mode_nunits): Change from unsigned char to
29029 poly_uint16_pod.
29030 (ONLY_FIXED_SIZE_MODES): New macro.
29031 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
29032 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
29033 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
29034 New typedefs.
29035 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
29036 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
29037 or if measurement_type is not polynomial.
29038 * genmodes.c (ZERO_COEFFS): New macro.
29039 (emit_mode_nunits_inline): Make mode_nunits_inline return a
29040 poly_uint16.
29041 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
29042 Use ZERO_COEFFS when emitting initializers.
29043 * data-streamer.h (bp_pack_poly_value): New function.
29044 (bp_unpack_poly_value): Likewise.
29045 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
29046 for GET_MODE_NUNITS.
29047 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
29048 for GET_MODE_NUNITS.
29049 * tree.c (make_vector_type): Remove temporary shim and make
29050 the real function take the number of units as a poly_uint64
29051 rather than an int.
29052 (build_vector_type_for_mode): Handle polynomial nunits.
29053 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
29054 * emit-rtl.c (const_vec_series_p_1): Likewise.
29055 (gen_rtx_CONST_VECTOR): Likewise.
29056 * fold-const.c (test_vec_duplicate_folding): Likewise.
29057 * genrecog.c (validate_pattern): Likewise.
29058 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
29059 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
29060 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
29061 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
29062 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
29063 * rtlanal.c (subreg_get_info): Likewise.
29064 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
29065 (vect_grouped_load_supported): Likewise.
29066 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
29067 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
29068 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
29069 (simplify_const_unary_operation, simplify_binary_operation_1)
29070 (simplify_const_binary_operation, simplify_ternary_operation)
29071 (test_vector_ops_duplicate, test_vector_ops): Likewise.
29072 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
29073 instead of CONST_VECTOR_NUNITS.
29074 * varasm.c (output_constant_pool_2): Likewise.
29075 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
29076 explicit-encoded elements in the XVEC for variable-length vectors.
29077
29078 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29079
29080 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
29081
29082 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29083 Alan Hayward <alan.hayward@arm.com>
29084 David Sherwood <david.sherwood@arm.com>
29085
29086 * coretypes.h (fixed_size_mode): Declare.
29087 (fixed_size_mode_pod): New typedef.
29088 * builtins.h (target_builtins::x_apply_args_mode)
29089 (target_builtins::x_apply_result_mode): Change type to
29090 fixed_size_mode_pod.
29091 * builtins.c (apply_args_size, apply_result_size, result_vector)
29092 (expand_builtin_apply_args_1, expand_builtin_apply)
29093 (expand_builtin_return): Update accordingly.
29094
29095 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29096
29097 * cse.c (hash_rtx_cb): Hash only the encoded elements.
29098 * cselib.c (cselib_hash_rtx): Likewise.
29099 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
29100 CONST_VECTOR encoding.
29101
29102 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29103 Jeff Law <law@redhat.com>
29104
29105 PR target/83641
29106 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
29107 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
29108 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
29109 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
29110
29111 PR target/83641
29112 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
29113 explicitly probe *sp in a noreturn function if there were any callee
29114 register saves or frame pointer is needed.
29115
29116 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29117
29118 PR debug/83621
29119 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
29120 BLKmode for ternary, binary or unary expressions.
29121
29122 PR debug/83645
29123 * var-tracking.c (delete_vta_debug_insn): New inline function.
29124 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
29125 insns from get_insns () to NULL instead of each bb separately.
29126 Use delete_vta_debug_insn. No longer static.
29127 (vt_debug_insns_local, variable_tracking_main_1): Adjust
29128 delete_vta_debug_insns callers.
29129 * rtl.h (delete_vta_debug_insns): Declare.
29130 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
29131 instead of variable_tracking_main.
29132
29133 2018-01-03 Martin Sebor <msebor@redhat.com>
29134
29135 PR tree-optimization/83603
29136 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
29137 arguments past the endof the argument list in functions declared
29138 without a prototype.
29139 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
29140 Avoid checking when arguments are null.
29141
29142 2018-01-03 Martin Sebor <msebor@redhat.com>
29143
29144 PR c/83559
29145 * doc/extend.texi (attribute const): Fix a typo.
29146 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
29147 issuing -Wsuggest-attribute for void functions.
29148
29149 2018-01-03 Martin Sebor <msebor@redhat.com>
29150
29151 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
29152 offset_int::from instead of wide_int::to_shwi.
29153 (maybe_diag_overlap): Remove assertion.
29154 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
29155 * gimple-ssa-sprintf.c (format_directive): Same.
29156 (parse_directive): Same.
29157 (sprintf_dom_walker::compute_format_length): Same.
29158 (try_substitute_return_value): Same.
29159
29160 2018-01-03 Jeff Law <law@redhat.com>
29161
29162 PR middle-end/83654
29163 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
29164 non-constant residual for zero at runtime and avoid probing in
29165 that case. Reorganize code for trailing problem to mirror handling
29166 of the residual.
29167
29168 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
29169
29170 PR tree-optimization/83501
29171 * tree-ssa-strlen.c (get_string_cst): New.
29172 (handle_char_store): Call get_string_cst.
29173
29174 2018-01-03 Martin Liska <mliska@suse.cz>
29175
29176 PR tree-optimization/83593
29177 * tree-ssa-strlen.c: Include tree-cfg.h.
29178 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
29179 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
29180 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
29181 to false.
29182 (strlen_dom_walker::before_dom_children): Call
29183 gimple_purge_dead_eh_edges. Dump tranformation with details
29184 dump flags.
29185 (strlen_dom_walker::before_dom_children): Update call by adding
29186 new argument cleanup_eh.
29187 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
29188
29189 2018-01-03 Martin Liska <mliska@suse.cz>
29190
29191 PR ipa/83549
29192 * cif-code.def (VARIADIC_THUNK): New enum value.
29193 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
29194 thunks.
29195
29196 2018-01-03 Jan Beulich <jbeulich@suse.com>
29197
29198 * sse.md (mov<mode>_internal): Tighten condition for when to use
29199 vmovdqu<ssescalarsize> for TI and OI modes.
29200
29201 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29202
29203 Update copyright years.
29204
29205 2018-01-03 Martin Liska <mliska@suse.cz>
29206
29207 PR ipa/83594
29208 * ipa-visibility.c (function_and_variable_visibility): Skip
29209 functions with noipa attribure.
29210
29211 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29212
29213 * gcc.c (process_command): Update copyright notice dates.
29214 * gcov-dump.c (print_version): Ditto.
29215 * gcov.c (print_version): Ditto.
29216 * gcov-tool.c (print_version): Ditto.
29217 * gengtype.c (create_file): Ditto.
29218 * doc/cpp.texi: Bump @copying's copyright year.
29219 * doc/cppinternals.texi: Ditto.
29220 * doc/gcc.texi: Ditto.
29221 * doc/gccint.texi: Ditto.
29222 * doc/gcov.texi: Ditto.
29223 * doc/install.texi: Ditto.
29224 * doc/invoke.texi: Ditto.
29225
29226 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29227
29228 * vector-builder.h (vector_builder::m_full_nelts): Change from
29229 unsigned int to poly_uint64.
29230 (vector_builder::full_nelts): Update prototype accordingly.
29231 (vector_builder::new_vector): Likewise.
29232 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
29233 (vector_builder::operator ==): Likewise.
29234 (vector_builder::finalize): Likewise.
29235 * int-vector-builder.h (int_vector_builder::int_vector_builder):
29236 Take the number of elements as a poly_uint64 rather than an
29237 unsigned int.
29238 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
29239 from unsigned int to poly_uint64.
29240 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
29241 (vec_perm_indices::new_vector): Likewise.
29242 (vec_perm_indices::length): Likewise.
29243 (vec_perm_indices::nelts_per_input): Likewise.
29244 (vec_perm_indices::input_nelts): Likewise.
29245 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
29246 number of elements per input as a poly_uint64 rather than an
29247 unsigned int. Use the original encoding for variable-length
29248 vectors, rather than clamping each individual element.
29249 For the second and subsequent elements in each pattern,
29250 clamp the step and base before clamping their sum.
29251 (vec_perm_indices::series_p): Handle polynomial element counts.
29252 (vec_perm_indices::all_in_range_p): Likewise.
29253 (vec_perm_indices_to_tree): Likewise.
29254 (vec_perm_indices_to_rtx): Likewise.
29255 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
29256 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
29257 (tree_vector_builder::new_binary_operation): Handle polynomial
29258 element counts. Return false if we need to know the number
29259 of elements at compile time.
29260 * fold-const.c (fold_vec_perm): Punt if the number of elements
29261 isn't known at compile time.
29262
29263 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29264
29265 * vec-perm-indices.h (vec_perm_builder): Change element type
29266 from HOST_WIDE_INT to poly_int64.
29267 (vec_perm_indices::element_type): Update accordingly.
29268 (vec_perm_indices::clamp): Handle polynomial element_types.
29269 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29270 (vec_perm_indices::all_in_range_p): Likewise.
29271 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
29272 than shwi trees.
29273 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
29274 polynomial vec_perm_indices element types.
29275 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
29276 * fold-const.c (fold_vec_perm): Likewise.
29277 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
29278 * tree-vect-generic.c (lower_vec_perm): Likewise.
29279 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29280 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
29281 element type to HOST_WIDE_INT.
29282
29283 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29284 Alan Hayward <alan.hayward@arm.com>
29285 David Sherwood <david.sherwood@arm.com>
29286
29287 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
29288 rather than an int. Use plus_constant.
29289 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
29290 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
29291
29292 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29293 Alan Hayward <alan.hayward@arm.com>
29294 David Sherwood <david.sherwood@arm.com>
29295
29296 * calls.c (emit_call_1, expand_call): Change struct_value_size from
29297 a HOST_WIDE_INT to a poly_int64.
29298
29299 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29300 Alan Hayward <alan.hayward@arm.com>
29301 David Sherwood <david.sherwood@arm.com>
29302
29303 * calls.c (load_register_parameters): Cope with polynomial
29304 mode sizes. Require a constant size for BLKmode parameters
29305 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
29306 forces a parameter to be padded at the lsb end in order to
29307 fill a complete number of words, require the parameter size
29308 to be ordered wrt UNITS_PER_WORD.
29309
29310 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29311 Alan Hayward <alan.hayward@arm.com>
29312 David Sherwood <david.sherwood@arm.com>
29313
29314 * reload1.c (spill_stack_slot_width): Change element type
29315 from unsigned int to poly_uint64_pod.
29316 (alter_reg): Treat mode sizes as polynomial.
29317
29318 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29319 Alan Hayward <alan.hayward@arm.com>
29320 David Sherwood <david.sherwood@arm.com>
29321
29322 * reload.c (complex_word_subreg_p): New function.
29323 (reload_inner_reg_of_subreg, push_reload): Use it.
29324
29325 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29326 Alan Hayward <alan.hayward@arm.com>
29327 David Sherwood <david.sherwood@arm.com>
29328
29329 * lra-constraints.c (process_alt_operands): Reject matched
29330 operands whose sizes aren't ordered.
29331 (match_reload): Refer to this check here.
29332
29333 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29334 Alan Hayward <alan.hayward@arm.com>
29335 David Sherwood <david.sherwood@arm.com>
29336
29337 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
29338 that the mode size is in the set {1, 2, 4, 8, 16}.
29339
29340 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29341 Alan Hayward <alan.hayward@arm.com>
29342 David Sherwood <david.sherwood@arm.com>
29343
29344 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
29345 Use plus_constant instead of gen_rtx_PLUS.
29346
29347 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29348 Alan Hayward <alan.hayward@arm.com>
29349 David Sherwood <david.sherwood@arm.com>
29350
29351 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
29352 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
29353 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
29354 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
29355 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
29356 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
29357 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
29358 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
29359 * config/i386/i386.c (ix86_push_rounding): ...this new function.
29360 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
29361 a poly_int64.
29362 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
29363 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
29364 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
29365 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
29366 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
29367 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
29368 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
29369 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
29370 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
29371 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
29372 function.
29373 * expr.c (emit_move_resolve_push): Treat the input and result
29374 of PUSH_ROUNDING as a poly_int64.
29375 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
29376 (emit_push_insn): Likewise.
29377 * lra-eliminations.c (mark_not_eliminable): Likewise.
29378 * recog.c (push_operand): Likewise.
29379 * reload1.c (elimination_effects): Likewise.
29380 * rtlanal.c (nonzero_bits1): Likewise.
29381 * calls.c (store_one_arg): Likewise. Require the padding to be
29382 known at compile time.
29383
29384 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29385 Alan Hayward <alan.hayward@arm.com>
29386 David Sherwood <david.sherwood@arm.com>
29387
29388 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
29389 Use plus_constant instead of gen_rtx_PLUS.
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 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
29396 rather than an int.
29397
29398 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29399 Alan Hayward <alan.hayward@arm.com>
29400 David Sherwood <david.sherwood@arm.com>
29401
29402 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
29403 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
29404 via stack temporaries. Treat the mode size as polynomial too.
29405
29406 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29407 Alan Hayward <alan.hayward@arm.com>
29408 David Sherwood <david.sherwood@arm.com>
29409
29410 * expr.c (expand_expr_real_2): When handling conversions involving
29411 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
29412 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
29413 as a poly_uint64 too.
29414
29415 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29416 Alan Hayward <alan.hayward@arm.com>
29417 David Sherwood <david.sherwood@arm.com>
29418
29419 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
29420
29421 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29422 Alan Hayward <alan.hayward@arm.com>
29423 David Sherwood <david.sherwood@arm.com>
29424
29425 * combine.c (can_change_dest_mode): Handle polynomial
29426 REGMODE_NATURAL_SIZE.
29427 * expmed.c (store_bit_field_1): Likewise.
29428 * expr.c (store_constructor): Likewise.
29429 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
29430 and polynomial REGMODE_NATURAL_SIZE.
29431 (gen_lowpart_common): Likewise.
29432 * reginfo.c (record_subregs_of_mode): Likewise.
29433 * rtlanal.c (read_modify_subreg_p): Likewise.
29434
29435 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29436 Alan Hayward <alan.hayward@arm.com>
29437 David Sherwood <david.sherwood@arm.com>
29438
29439 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
29440 numbers of elements.
29441
29442 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29443 Alan Hayward <alan.hayward@arm.com>
29444 David Sherwood <david.sherwood@arm.com>
29445
29446 * match.pd: Cope with polynomial numbers of vector elements.
29447
29448 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29449 Alan Hayward <alan.hayward@arm.com>
29450 David Sherwood <david.sherwood@arm.com>
29451
29452 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
29453 in a POINTER_PLUS_EXPR.
29454
29455 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29456 Alan Hayward <alan.hayward@arm.com>
29457 David Sherwood <david.sherwood@arm.com>
29458
29459 * omp-simd-clone.c (simd_clone_subparts): New function.
29460 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
29461 (ipa_simd_modify_function_body): Likewise.
29462
29463 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29464 Alan Hayward <alan.hayward@arm.com>
29465 David Sherwood <david.sherwood@arm.com>
29466
29467 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
29468 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
29469 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
29470 (expand_vector_condition, vector_element): Likewise.
29471 (subparts_gt): New function.
29472 (get_compute_type): Use subparts_gt.
29473 (count_type_subparts): Delete.
29474 (expand_vector_operations_1): Use subparts_gt instead of
29475 count_type_subparts.
29476
29477 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29478 Alan Hayward <alan.hayward@arm.com>
29479 David Sherwood <david.sherwood@arm.com>
29480
29481 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
29482 (vect_compile_time_alias): ...this new function. Do the calculation
29483 on poly_ints rather than trees.
29484 (vect_prune_runtime_alias_test_list): Update call accordingly.
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-slp.c (vect_build_slp_tree_1): Handle polynomial
29491 numbers of units.
29492 (vect_schedule_slp_instance): Likewise.
29493
29494 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29495 Alan Hayward <alan.hayward@arm.com>
29496 David Sherwood <david.sherwood@arm.com>
29497
29498 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
29499 constant and extern definitions for variable-length vectors.
29500 (vect_get_constant_vectors): Note that the number of units
29501 is known to be constant.
29502
29503 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29504 Alan Hayward <alan.hayward@arm.com>
29505 David Sherwood <david.sherwood@arm.com>
29506
29507 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
29508 of units as polynomial. Choose between WIDE and NARROW based
29509 on multiple_p.
29510
29511 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29512 Alan Hayward <alan.hayward@arm.com>
29513 David Sherwood <david.sherwood@arm.com>
29514
29515 * tree-vect-stmts.c (simd_clone_subparts): New function.
29516 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
29517
29518 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29519 Alan Hayward <alan.hayward@arm.com>
29520 David Sherwood <david.sherwood@arm.com>
29521
29522 * tree-vect-stmts.c (vectorizable_call): Treat the number of
29523 vectors as polynomial. Use build_index_vector for
29524 IFN_GOMP_SIMD_LANE.
29525
29526 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29527 Alan Hayward <alan.hayward@arm.com>
29528 David Sherwood <david.sherwood@arm.com>
29529
29530 * tree-vect-stmts.c (get_load_store_type): Treat the number of
29531 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
29532 for variable-length vectors.
29533 (vectorizable_mask_load_store): Treat the number of units as
29534 polynomial, asserting that it is constant if the condition has
29535 already been enforced.
29536 (vectorizable_store, vectorizable_load): Likewise.
29537
29538 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29539 Alan Hayward <alan.hayward@arm.com>
29540 David Sherwood <david.sherwood@arm.com>
29541
29542 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
29543 of units as polynomial. Punt if we can't tell at compile time
29544 which vector contains the final result.
29545
29546 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29547 Alan Hayward <alan.hayward@arm.com>
29548 David Sherwood <david.sherwood@arm.com>
29549
29550 * tree-vect-loop.c (vectorizable_induction): Treat the number
29551 of units as polynomial. Punt on SLP inductions. Use an integer
29552 VEC_SERIES_EXPR for variable-length integer reductions. Use a
29553 cast of such a series for variable-length floating-point
29554 reductions.
29555
29556 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29557 Alan Hayward <alan.hayward@arm.com>
29558 David Sherwood <david.sherwood@arm.com>
29559
29560 * tree.h (build_index_vector): Declare.
29561 * tree.c (build_index_vector): New function.
29562 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
29563 of units as polynomial, forcibly converting it to a constant if
29564 vectorizable_reduction has already enforced the condition.
29565 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
29566 to create a {1,2,3,...} vector.
29567 (vectorizable_reduction): Treat the number of units as polynomial.
29568 Choose vectype_in based on the largest scalar element size rather
29569 than the smallest number of units. Enforce the restrictions
29570 relied on above.
29571
29572 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29573 Alan Hayward <alan.hayward@arm.com>
29574 David Sherwood <david.sherwood@arm.com>
29575
29576 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
29577 number of units as polynomial.
29578
29579 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29580 Alan Hayward <alan.hayward@arm.com>
29581 David Sherwood <david.sherwood@arm.com>
29582
29583 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
29584 * target.def (autovectorize_vector_sizes): Return the vector sizes
29585 by pointer, using vector_sizes rather than a bitmask.
29586 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
29587 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
29588 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
29589 Likewise.
29590 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
29591 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
29592 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
29593 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
29594 * omp-general.c (omp_max_vf): Likewise.
29595 * omp-low.c (omp_clause_aligned_alignment): Likewise.
29596 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
29597 * tree-vect-loop.c (vect_analyze_loop): Likewise.
29598 * tree-vect-slp.c (vect_slp_bb): Likewise.
29599 * doc/tm.texi: Regenerate.
29600 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
29601 to a poly_uint64.
29602 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
29603 the vector size as a poly_uint64 rather than an unsigned int.
29604 (current_vector_size): Change from an unsigned int to a poly_uint64.
29605 (get_vectype_for_scalar_type): Update accordingly.
29606 * tree.h (build_truth_vector_type): Take the size and number of
29607 units as a poly_uint64 rather than an unsigned int.
29608 (build_vector_type): Add a temporary overload that takes
29609 the number of units as a poly_uint64 rather than an unsigned int.
29610 * tree.c (make_vector_type): Likewise.
29611 (build_truth_vector_type): Take the number of units as a poly_uint64
29612 rather than an unsigned int.
29613
29614 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29615 Alan Hayward <alan.hayward@arm.com>
29616 David Sherwood <david.sherwood@arm.com>
29617
29618 * target.def (get_mask_mode): Take the number of units and length
29619 as poly_uint64s rather than unsigned ints.
29620 * targhooks.h (default_get_mask_mode): Update accordingly.
29621 * targhooks.c (default_get_mask_mode): Likewise.
29622 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
29623 * doc/tm.texi: Regenerate.
29624
29625 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29626 Alan Hayward <alan.hayward@arm.com>
29627 David Sherwood <david.sherwood@arm.com>
29628
29629 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
29630 * omp-general.c (omp_max_vf): Likewise.
29631 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
29632 (expand_omp_simd): Handle polynomial safelen.
29633 * omp-low.c (omplow_simd_context): Add a default constructor.
29634 (omplow_simd_context::max_vf): Change from int to poly_uint64.
29635 (lower_rec_simd_input_clauses): Update accordingly.
29636 (lower_rec_input_clauses): Likewise.
29637
29638 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29639 Alan Hayward <alan.hayward@arm.com>
29640 David Sherwood <david.sherwood@arm.com>
29641
29642 * tree-vectorizer.h (vect_nunits_for_cost): New function.
29643 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
29644 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
29645 (vect_analyze_slp_cost): Likewise.
29646 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
29647 (vect_model_load_cost): Likewise.
29648
29649 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29650 Alan Hayward <alan.hayward@arm.com>
29651 David Sherwood <david.sherwood@arm.com>
29652
29653 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
29654 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
29655 from an unsigned int * to a poly_uint64_pod *.
29656 (calculate_unrolling_factor): New function.
29657 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
29658
29659 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29660 Alan Hayward <alan.hayward@arm.com>
29661 David Sherwood <david.sherwood@arm.com>
29662
29663 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
29664 from an unsigned int to a poly_uint64.
29665 (_loop_vec_info::slp_unrolling_factor): Likewise.
29666 (_loop_vec_info::vectorization_factor): Change from an int
29667 to a poly_uint64.
29668 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
29669 (vect_get_num_vectors): New function.
29670 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
29671 (vect_get_num_copies): Use vect_get_num_vectors.
29672 (vect_analyze_data_ref_dependences): Change max_vf from an int *
29673 to an unsigned int *.
29674 (vect_analyze_data_refs): Change min_vf from an int * to a
29675 poly_uint64 *.
29676 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29677 than an unsigned HOST_WIDE_INT.
29678 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
29679 (vect_analyze_data_ref_dependence): Change max_vf from an int *
29680 to an unsigned int *.
29681 (vect_analyze_data_ref_dependences): Likewise.
29682 (vect_compute_data_ref_alignment): Handle polynomial vf.
29683 (vect_enhance_data_refs_alignment): Likewise.
29684 (vect_prune_runtime_alias_test_list): Likewise.
29685 (vect_shift_permute_load_chain): Likewise.
29686 (vect_supportable_dr_alignment): Likewise.
29687 (dependence_distance_ge_vf): Take the vectorization factor as a
29688 poly_uint64 rather than an unsigned HOST_WIDE_INT.
29689 (vect_analyze_data_refs): Change min_vf from an int * to a
29690 poly_uint64 *.
29691 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
29692 vfm1 as a poly_uint64 rather than an int. Make the same change
29693 for the returned bound_scalar.
29694 (vect_gen_vector_loop_niters): Handle polynomial vf.
29695 (vect_do_peeling): Likewise. Update call to
29696 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
29697 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
29698 be constant.
29699 * tree-vect-loop.c (vect_determine_vectorization_factor)
29700 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
29701 (vect_get_known_peeling_cost): Likewise.
29702 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
29703 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
29704 (vect_transform_loop): Likewise. Use the lowest possible VF when
29705 updating the upper bounds of the loop.
29706 (vect_min_worthwhile_factor): Make static. Return an unsigned int
29707 rather than an int.
29708 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
29709 polynomial unroll factors.
29710 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
29711 (vect_make_slp_decision): Likewise.
29712 (vect_supported_load_permutation_p): Likewise, and polynomial
29713 vf too.
29714 (vect_analyze_slp_cost): Handle polynomial vf.
29715 (vect_slp_analyze_node_operations): Likewise.
29716 (vect_slp_analyze_bb_1): Likewise.
29717 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29718 than an unsigned HOST_WIDE_INT.
29719 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
29720 (vectorizable_load): Handle polynomial vf.
29721 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
29722 a poly_uint64.
29723 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
29724
29725 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29726 Alan Hayward <alan.hayward@arm.com>
29727 David Sherwood <david.sherwood@arm.com>
29728
29729 * match.pd: Handle bit operations involving three constants
29730 and try to fold one pair.
29731
29732 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29733
29734 * tree-vect-loop-manip.c: Include gimple-fold.h.
29735 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
29736 niters_maybe_zero parameters. Handle other cases besides a step of 1.
29737 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
29738 Add a path that uses a step of VF instead of 1, but disable it
29739 for now.
29740 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
29741 and niters_no_overflow parameters. Update calls to
29742 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
29743 Create a new SSA name if the latter choses to use a ste other
29744 than zero, and return it via niters_vector_mult_vf_var.
29745 * tree-vect-loop.c (vect_transform_loop): Update calls to
29746 vect_do_peeling, vect_gen_vector_loop_niters and
29747 slpeel_make_loop_iterate_ntimes.
29748 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
29749 (vect_gen_vector_loop_niters): Update declarations after above changes.
29750
29751 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
29752
29753 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
29754 128-bit round to integer instructions.
29755 (ceil<mode>2): Likewise.
29756 (btrunc<mode>2): Likewise.
29757 (round<mode>2): Likewise.
29758
29759 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
29760
29761 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
29762 unaligned VSX load/store on P8/P9.
29763 (expand_block_clear): Allow the use of unaligned VSX
29764 load/store on P8/P9.
29765
29766 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
29767
29768 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
29769 New function.
29770 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
29771 swap associated with both a load and a store.
29772
29773 2018-01-02 Andrew Waterman <andrew@sifive.com>
29774
29775 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
29776 * config/riscv/riscv.md (clear_cache): Use it.
29777
29778 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
29779
29780 * web.c: Remove out-of-date comment.
29781
29782 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29783
29784 * expr.c (fixup_args_size_notes): Check that any existing
29785 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
29786 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
29787 (emit_single_push_insn): ...here.
29788
29789 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29790
29791 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
29792 (const_vector_encoded_nelts): New function.
29793 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
29794 (const_vector_int_elt, const_vector_elt): Declare.
29795 * emit-rtl.c (const_vector_int_elt_1): New function.
29796 (const_vector_elt): Likewise.
29797 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
29798 of CONST_VECTOR_ELT.
29799
29800 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29801
29802 * expr.c: Include rtx-vector-builder.h.
29803 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
29804 directly on the tree encoding.
29805 (const_vector_from_tree): Likewise.
29806 * optabs.c: Include rtx-vector-builder.h.
29807 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
29808 sequence of "u" values.
29809 * vec-perm-indices.c: Include rtx-vector-builder.h.
29810 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
29811 directly on the vec_perm_indices encoding.
29812
29813 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29814
29815 * doc/rtl.texi (const_vector): Describe new encoding scheme.
29816 * Makefile.in (OBJS): Add rtx-vector-builder.o.
29817 * rtx-vector-builder.h: New file.
29818 * rtx-vector-builder.c: Likewise.
29819 * rtl.h (rtx_def::u2): Add a const_vector field.
29820 (CONST_VECTOR_NPATTERNS): New macro.
29821 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
29822 (CONST_VECTOR_DUPLICATE_P): Likewise.
29823 (CONST_VECTOR_STEPPED_P): Likewise.
29824 (CONST_VECTOR_ENCODED_ELT): Likewise.
29825 (const_vec_duplicate_p): Check for a duplicated vector encoding.
29826 (unwrap_const_vec_duplicate): Likewise.
29827 (const_vec_series_p): Check for a non-duplicated vector encoding.
29828 Say that the function only returns true for integer vectors.
29829 * emit-rtl.c: Include rtx-vector-builder.h.
29830 (gen_const_vec_duplicate_1): Delete.
29831 (gen_const_vector): Call gen_const_vec_duplicate instead of
29832 gen_const_vec_duplicate_1.
29833 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
29834 (gen_const_vec_duplicate): Use rtx_vector_builder.
29835 (gen_const_vec_series): Likewise.
29836 (gen_rtx_CONST_VECTOR): Likewise.
29837 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
29838 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29839 Build a new vector rather than modifying a CONST_VECTOR in-place.
29840 (handle_special_swappables): Update call accordingly.
29841 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
29842 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29843 Build a new vector rather than modifying a CONST_VECTOR in-place.
29844 (handle_special_swappables): Update call accordingly.
29845
29846 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29847
29848 * simplify-rtx.c (simplify_const_binary_operation): Use
29849 CONST_VECTOR_ELT instead of XVECEXP.
29850
29851 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29852
29853 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
29854 the selector elements to be different from the data elements
29855 if the selector is a VECTOR_CST.
29856 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
29857 ssizetype for the selector.
29858
29859 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29860
29861 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
29862 before testing each element individually.
29863 * tree-vect-generic.c (lower_vec_perm): Likewise.
29864
29865 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29866
29867 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
29868 * selftest-run-tests.c (selftest::run_tests): Call it.
29869 * vector-builder.h (vector_builder::operator ==): New function.
29870 (vector_builder::operator !=): Likewise.
29871 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
29872 (vec_perm_indices::all_from_input_p): New function.
29873 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29874 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
29875 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
29876 instead of reading the VECTOR_CST directly. Detect whether both
29877 vector inputs are the same before constructing the vec_perm_indices,
29878 and update the number of inputs argument accordingly. Use the
29879 utility functions added above. Only construct sel2 if we need to.
29880
29881 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29882
29883 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
29884 the broadcast of the low byte.
29885 (expand_mult_highpart): Use an explicit encoding for the permutes.
29886 * optabs-query.c (can_mult_highpart_p): Likewise.
29887 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
29888 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29889 (vectorizable_bswap): Likewise.
29890 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
29891 explicit encoding for the power-of-2 permutes.
29892 (vect_permute_store_chain): Likewise.
29893 (vect_grouped_load_supported): Likewise.
29894 (vect_permute_load_chain): Likewise.
29895
29896 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29897
29898 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
29899 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
29900 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
29901 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29902 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
29903 (vect_gen_perm_mask_any): Likewise.
29904
29905 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29906
29907 * int-vector-builder.h: New file.
29908 * vec-perm-indices.h: Include int-vector-builder.h.
29909 (vec_perm_indices): Redefine as an int_vector_builder.
29910 (auto_vec_perm_indices): Delete.
29911 (vec_perm_builder): Redefine as a stand-alone class.
29912 (vec_perm_indices::vec_perm_indices): New function.
29913 (vec_perm_indices::clamp): Likewise.
29914 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
29915 (vec_perm_indices::new_vector): New function.
29916 (vec_perm_indices::new_expanded_vector): Update for new
29917 vec_perm_indices class.
29918 (vec_perm_indices::rotate_inputs): New function.
29919 (vec_perm_indices::all_in_range_p): Operate directly on the
29920 encoded form, without computing elided elements.
29921 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
29922 encoding. Update for new vec_perm_indices class.
29923 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
29924 the given vec_perm_builder.
29925 (expand_vec_perm_var): Update vec_perm_builder constructor.
29926 (expand_mult_highpart): Use vec_perm_builder instead of
29927 auto_vec_perm_indices.
29928 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
29929 vec_perm_indices instead of auto_vec_perm_indices. Use a single
29930 or double series encoding as appropriate.
29931 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
29932 vec_perm_indices instead of auto_vec_perm_indices.
29933 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
29934 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
29935 (vect_permute_store_chain): Likewise.
29936 (vect_grouped_load_supported): Likewise.
29937 (vect_permute_load_chain): Likewise.
29938 (vect_shift_permute_load_chain): Likewise.
29939 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
29940 (vect_transform_slp_perm_load): Likewise.
29941 (vect_schedule_slp_instance): Likewise.
29942 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29943 (vectorizable_mask_load_store): Likewise.
29944 (vectorizable_bswap): Likewise.
29945 (vectorizable_store): Likewise.
29946 (vectorizable_load): Likewise.
29947 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
29948 vec_perm_indices instead of auto_vec_perm_indices. Use
29949 tree_to_vec_perm_builder to read the vector from a tree.
29950 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
29951 vec_perm_builder instead of a vec_perm_indices.
29952 (have_whole_vector_shift): Use vec_perm_builder and
29953 vec_perm_indices instead of auto_vec_perm_indices. Leave the
29954 truncation to calc_vec_perm_mask_for_shift.
29955 (vect_create_epilog_for_reduction): Likewise.
29956 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
29957 from auto_vec_perm_indices to vec_perm_indices.
29958 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29959 instead of changing individual elements.
29960 (aarch64_vectorize_vec_perm_const): Use new_vector to install
29961 the vector in d.perm.
29962 * config/arm/arm.c (expand_vec_perm_d::perm): Change
29963 from auto_vec_perm_indices to vec_perm_indices.
29964 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29965 instead of changing individual elements.
29966 (arm_vectorize_vec_perm_const): Use new_vector to install
29967 the vector in d.perm.
29968 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
29969 Update vec_perm_builder constructor.
29970 (rs6000_expand_interleave): Likewise.
29971 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
29972 (rs6000_expand_interleave): Likewise.
29973
29974 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29975
29976 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
29977 to qimode could truncate the indices.
29978 * optabs.c (expand_vec_perm_var): Likewise.
29979
29980 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29981
29982 * Makefile.in (OBJS): Add vec-perm-indices.o.
29983 * vec-perm-indices.h: New file.
29984 * vec-perm-indices.c: Likewise.
29985 * target.h (vec_perm_indices): Replace with a forward class
29986 declaration.
29987 (auto_vec_perm_indices): Move to vec-perm-indices.h.
29988 * optabs.h: Include vec-perm-indices.h.
29989 (expand_vec_perm): Delete.
29990 (selector_fits_mode_p, expand_vec_perm_var): Declare.
29991 (expand_vec_perm_const): Declare.
29992 * target.def (vec_perm_const_ok): Replace with...
29993 (vec_perm_const): ...this new hook.
29994 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
29995 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
29996 * doc/tm.texi: Regenerate.
29997 * optabs.def (vec_perm_const): Delete.
29998 * doc/md.texi (vec_perm_const): Likewise.
29999 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
30000 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
30001 expand_vec_perm for constant permutation vectors. Assert that
30002 the mode of variable permutation vectors is the integer equivalent
30003 of the mode that is being permuted.
30004 * optabs-query.h (selector_fits_mode_p): Declare.
30005 * optabs-query.c: Include vec-perm-indices.h.
30006 (selector_fits_mode_p): New function.
30007 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
30008 is defined, instead of checking whether the vec_perm_const_optab
30009 exists. Use targetm.vectorize.vec_perm_const instead of
30010 targetm.vectorize.vec_perm_const_ok. Check whether the indices
30011 fit in the vector mode before using a variable permute.
30012 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
30013 vec_perm_indices instead of an rtx.
30014 (expand_vec_perm): Replace with...
30015 (expand_vec_perm_const): ...this new function. Take the selector
30016 as a vec_perm_indices rather than an rtx. Also take the mode of
30017 the selector. Update call to shift_amt_for_vec_perm_mask.
30018 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
30019 Use vec_perm_indices::new_expanded_vector to expand the original
30020 selector into bytes. Check whether the indices fit in the vector
30021 mode before using a variable permute.
30022 (expand_vec_perm_var): Make global.
30023 (expand_mult_highpart): Use expand_vec_perm_const.
30024 * fold-const.c: Includes vec-perm-indices.h.
30025 * tree-ssa-forwprop.c: Likewise.
30026 * tree-vect-data-refs.c: Likewise.
30027 * tree-vect-generic.c: Likewise.
30028 * tree-vect-loop.c: Likewise.
30029 * tree-vect-slp.c: Likewise.
30030 * tree-vect-stmts.c: Likewise.
30031 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
30032 Delete.
30033 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
30034 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
30035 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
30036 (aarch64_vectorize_vec_perm_const): ...this new function.
30037 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
30038 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30039 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
30040 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
30041 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
30042 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30043 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
30044 into...
30045 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
30046 check for NEON modes.
30047 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
30048 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
30049 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
30050 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
30051 into...
30052 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
30053 the old VEC_PERM_CONST conditions.
30054 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
30055 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
30056 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
30057 (ia64_vectorize_vec_perm_const_ok): Merge into...
30058 (ia64_vectorize_vec_perm_const): ...this new function.
30059 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
30060 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
30061 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
30062 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
30063 * config/mips/mips.c (mips_expand_vec_perm_const)
30064 (mips_vectorize_vec_perm_const_ok): Merge into...
30065 (mips_vectorize_vec_perm_const): ...this new function.
30066 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
30067 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
30068 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
30069 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
30070 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
30071 (rs6000_expand_vec_perm_const): Delete.
30072 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
30073 Delete.
30074 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30075 (altivec_expand_vec_perm_const_le): Take each operand individually.
30076 Operate on constant selectors rather than rtxes.
30077 (altivec_expand_vec_perm_const): Likewise. Update call to
30078 altivec_expand_vec_perm_const_le.
30079 (rs6000_expand_vec_perm_const): Delete.
30080 (rs6000_vectorize_vec_perm_const_ok): Delete.
30081 (rs6000_vectorize_vec_perm_const): New function.
30082 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
30083 an element count and rtx array.
30084 (rs6000_expand_extract_even): Update call accordingly.
30085 (rs6000_expand_interleave): Likewise.
30086 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
30087 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
30088 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
30089 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
30090 (rs6000_expand_vec_perm_const): Delete.
30091 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
30092 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30093 (altivec_expand_vec_perm_const_le): Take each operand individually.
30094 Operate on constant selectors rather than rtxes.
30095 (altivec_expand_vec_perm_const): Likewise. Update call to
30096 altivec_expand_vec_perm_const_le.
30097 (rs6000_expand_vec_perm_const): Delete.
30098 (rs6000_vectorize_vec_perm_const_ok): Delete.
30099 (rs6000_vectorize_vec_perm_const): New function. Remove stray
30100 reference to the SPE evmerge intructions.
30101 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
30102 an element count and rtx array.
30103 (rs6000_expand_extract_even): Update call accordingly.
30104 (rs6000_expand_interleave): Likewise.
30105 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
30106 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
30107 new function.
30108 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30109
30110 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30111
30112 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
30113 vector mode and that that mode matches the mode of the data
30114 being permuted.
30115 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
30116 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
30117 directly using expand_vec_perm_1 when forcing selectors into
30118 registers.
30119 (expand_vec_perm_var): New function, split out from expand_vec_perm.
30120
30121 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30122
30123 * optabs-query.h (can_vec_perm_p): Delete.
30124 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
30125 * optabs-query.c (can_vec_perm_p): Split into...
30126 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
30127 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
30128 particular selector is valid.
30129 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
30130 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
30131 (vect_grouped_load_supported): Likewise.
30132 (vect_shift_permute_load_chain): Likewise.
30133 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
30134 (vect_transform_slp_perm_load): Likewise.
30135 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
30136 (vectorizable_bswap): Likewise.
30137 (vect_gen_perm_mask_checked): Likewise.
30138 * fold-const.c (fold_ternary_loc): Likewise. Don't take
30139 implementations of variable permutation vectors into account
30140 when deciding which selector to use.
30141 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
30142 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
30143 with a false third argument.
30144 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
30145 to test whether the constant selector is valid and can_vec_perm_var_p
30146 to test whether a variable selector is valid.
30147
30148 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30149
30150 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
30151 * optabs-query.c (can_vec_perm_p): Likewise.
30152 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
30153 instead of vec_perm_indices.
30154 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
30155 (vect_gen_perm_mask_checked): Likewise,
30156 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
30157 (vect_gen_perm_mask_checked): Likewise,
30158
30159 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30160
30161 * optabs-query.h (qimode_for_vec_perm): Declare.
30162 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
30163 (qimode_for_vec_perm): ...this new function.
30164 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
30165
30166 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
30167
30168 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
30169 does not have a conditional at the top.
30170
30171 2018-01-02 Richard Biener <rguenther@suse.de>
30172
30173 * ipa-inline.c (big_speedup_p): Fix expression.
30174
30175 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30176
30177 PR target/81616
30178 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
30179 for generic 4->6.
30180
30181 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30182
30183 PR target/81616
30184 Generic tuning.
30185 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
30186 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
30187 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
30188 cond_taken_branch_cost 3->4.
30189
30190 2018-01-01 Jakub Jelinek <jakub@redhat.com>
30191
30192 PR tree-optimization/83581
30193 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
30194 TODO_cleanup_cfg if any changes have been made.
30195
30196 PR middle-end/83608
30197 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
30198 convert_modes if target mode has the right side, but different mode
30199 class.
30200
30201 PR middle-end/83609
30202 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
30203 last argument when extracting from CONCAT. If either from_real or
30204 from_imag is NULL, use expansion through memory. If result is not
30205 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
30206 the parts directly to inner mode, if even that fails, use expansion
30207 through memory.
30208
30209 PR middle-end/83623
30210 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
30211 check for bswap in mode rather than HImode and use that in expand_unop
30212 too.
30213 \f
30214 Copyright (C) 2018 Free Software Foundation, Inc.
30215
30216 Copying and distribution of this file, with or without modification,
30217 are permitted in any medium without royalty provided the copyright
30218 notice and this notice are preserved.