re PR middle-end/87852 (FAIL: gcc.c-torture/execute/pr53465.c)
[gcc.git] / gcc / ChangeLog
1 2018-11-05 Richard Biener <rguenther@suse.de>
2
3 PR rtl-optimization/87852
4 * fwprop.c (use_killed_between): Only consider single-defs of the
5 use whose definition statement dominates the use.
6
7 2018-11-05 Martin Liska <mliska@suse.cz>
8
9 PR web/87829
10 * doc/invoke.texi: Remove options that are
11 not disabled with -Os.
12
13 2018-11-05 Martin Liska <mliska@suse.cz>
14
15 PR c/87811
16 * doc/extend.texi: Update constrain about the last argument
17 of __builtin_expect_with_probability.
18
19 2018-11-05 Martin Liska <mliska@suse.cz>
20
21 PR c/87811
22 * predict.c (expr_expected_value_1): Verify
23 that last argument is a real constants and emit
24 error.
25
26 2018-11-05 Martin Liska <mliska@suse.cz>
27
28 PR gcov-profile/77698
29 * ipa-profile.c (ipa_profile): Adjust hotness threshold
30 only in LTO mode.
31
32 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
33
34 PR tree-optimization/86572
35 * builtins.c (c_strlen): Handle negative offsets in a safe way.
36
37 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
38
39 PR tree-optimization/87672
40 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
41 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
42
43 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
44
45 PR middle-end/58372
46 * cfgexpand.c (pass_expand::execute): Move the call to
47 finish_eh_generation in front of the call to expand_stack_alignment.
48
49 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
50
51 * common/config/i386/i386-common.c (processor_alias_table): Add
52 znver2 entry.
53 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
54 (case ${target}): Add znver2.
55 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
56 -march=native recognize znver2 processors.
57 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
58 * config/i386/i386.c (m_znver2): New definition.
59 (m_ZNVER): New definition.
60 (m_AMD_MULTIPLE): Includes m_znver2.
61 (processor_cost_table): Add znver2 entry.
62 (processor_target_table): Add znver2 entry.
63 (get_builtin_code_for_version): Set priority for
64 PROCESSOR_ZNVER2.
65 (processor_model): Add M_AMDFAM17H_ZNVER2.
66 (arch_names_table): Ditto.
67 (ix86_reassociation_width): Include znver2.
68 * config/i386/i386.h (TARGET_znver2): New definition.
69 (struct ix86_size_cost): Add TARGET_ZNVER2.
70 (enum processor_type): Add PROCESSOR_ZNVER2.
71 * config/i386/i386.md (define_attr "cpu"): Add znver2.
72 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
73 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
74 (ix86_adjust_cost): Add znver2.
75 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
76 * gcc/doc/extend.texi: Add details about znver2.
77 * gcc/doc/invoke.texi: Add details about znver2.
78
79 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
80
81 PR target/87079
82
83 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
84 pattern.
85
86 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
87
88 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
89 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
90
91 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
92
93 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
94 shrink-wrapping when -mtrack-speculation.
95
96 2018-11-02 Richard Biener <rguenther@suse.de>
97
98 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
99 (pop_cost_one_pair): Do not free pair.
100 (pop_best_coalesce): Likewise.
101 (create_coalesce_list): Initialize obstack.
102 (delete_coalesce_list): Free obstack.
103 (find_coalesce_pair): Obstack-allocate coalesce pairs.
104 (add_cost_one_coalesce): Likewise.
105 (struct live_track): Remove bitmap pointer indirections.
106 (new_live_track): Adjust.
107 (delete_live_track): Likewise.
108 (live_track_remove_partition): Likewise.
109 (live_track_add_partition): Likewise.
110 (live_track_live_p): Likewise.
111 (live_track_process_def): Likewise.
112 (live_track_clear_base_vars): Likewise.
113
114 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
115
116 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
117 * configure: Regenerate.
118 * config.in: Regenerate.
119 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
120 HAVE_AS_REGISTER_PSEUDO_OP guard.
121 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
122 !HAVE_AS_REGISTER_PSEUDO_OP support.
123 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
124 guard.
125
126 2018-11-02 Richard Biener <rguenther@suse.de>
127
128 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
129 with is_type_die.
130
131 2018-11-02 Richard Biener <rguenther@suse.de>
132
133 PR tree-optimization/87776
134 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
135 executable when iterating but running into rpo-vn-max-loop-depth
136 and not eliding the iteration.
137
138 2018-11-30 Jan Hubicka <jh@suse.cz>
139
140 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
141 TYPE_DECL.
142
143 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
144
145 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
146 prototype.
147 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
148 Combine with rs6000_address_for_fpconvert.
149 (rs6000_address_for_fpconvert): Combine with
150 rs6000_force_indexed_or_indirect_mem.
151 (rs6000_expand_vector_init): Change function call from
152 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
153 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
154 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
155 (floatsi<mode>2_lfiwax_mem): Ditto.
156 (floatunssi<mode>2_lfiwzx): Ditto.
157 (floatunssi<mode>2_lfiwzx_mem): Ditto.
158 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
159 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
160 (fix_trunc<mode>si2_stfiwx): Ditto.
161 (fixuns_trunc<mode>si2_stfiwx): Ditto.
162 (float_<mode>si2_hw): Ditto.
163 (floatuns_<mode>si2_hw): Ditto.
164 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
165 (vsx_splat_<mode>): Ditto.
166
167 2018-11-01 Joseph Myers <joseph@codesourcery.com>
168
169 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
170 at end of assembler input text.
171 * configure: Regenerate.
172
173 2018-11-01 Jakub Jelinek <jakub@redhat.com>
174
175 PR tree-optimization/87826
176 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
177 negative or larger or equal to type's precision.
178
179 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
180
181 * opts.c (default_options_table): Do not enable
182 OPT_fdelayed_branch at -Og.
183 * doc/invoke.texi (-fdelayed-branch): Document it.
184
185 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
186
187 * optabs-libfuncs.c (build_libfunc_function_visibility):
188 New, split out from...
189 (build_libfunc_function): ... here.
190 (init_one_libfunc_visibility): New, split out from ...
191 (init_one_libfunc): ... here.
192
193 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
194 scratch register need not be early-clobber. Document the reason
195 why we cannot use ST<OP>.
196
197 2018-10-31 Joseph Myers <joseph@codesourcery.com>
198
199 PR bootstrap/82856
200 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
201 line for second argument of AC_DEFINE_UNQUOTED.
202 * doc/install.texi (Tools/packages necessary for modifying GCC):
203 Update to autoconf 2.69 and automake 1.15.1.
204 * aclocal.m4, config.in, configure: Regenerate.
205
206 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
207
208 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
209 initialization.
210
211 2018-10-31 Martin Liska <mliska@suse.cz>
212
213 PR driver/83193
214 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
215 Add new argument invalid_extension.
216 (aarch64_get_all_extension_candidates): New function.
217 (aarch64_rewrite_selected_cpu): Add NULL to function call.
218 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
219 new argument.
220 (aarch64_get_all_extension_candidates): New function.
221 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
222 argument invalid_extension.
223 (aarch64_parse_cpu): Likewise.
224 (aarch64_print_hint_for_extensions): New function.
225 (aarch64_validate_mcpu): Provide hint about invalid extension.
226 (aarch64_validate_march): Likewise.
227 (aarch64_handle_attr_arch): Pass new argument.
228 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
229 (aarch64_handle_attr_isa_flags): Likewise.
230
231 2018-10-31 Richard Biener <rguenther@suse.de>
232
233 PR middle-end/70359
234 PR middle-end/86270
235 * tree-outof-ssa.c (insert_backedge_copies): Restrict
236 copy generation to useful cases. Place the copy before
237 the definition of the backedge value when possible.
238
239 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
240
241 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
242 * config/arc/arc.c (arc_active_insn): New function.
243 (check_store_cacheline_hazard): Likewise.
244 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
245 (arc_override_options): Disable delay slot scheduler for older
246 A7.
247 (arc_store_addr_hazard_p): New implementation, old one renamed to
248 ...
249 (arc_store_addr_hazard_internal_p): Renamed.
250 (arc_reorg): Don't combine into brcc instructions which are part
251 of hardware hazard solution.
252 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
253 (tune_arc700): Likewise.
254 * config/arc/arc.opt (arc7xx): New tune value.
255 * config/arc/arc700.md: Improve A7 scheduler.
256
257 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
258
259 * config/arc/arc.c (arc_override_options): Remove
260 TARGET_COMPACT_CASESI.
261 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
262 (CASE_VECTOR_MODE): Likewise.
263 (CASE_VECTOR_PC_RELATIVE): Likewise.
264 (CASE_VECTOR_SHORTEN_MODE): Likewise.
265 (CASE_VECTOR_SHORTEN_MODE1): Delete.
266 (ADDR_VEC_ALIGN): Update.
267 (ASM_OUTPUT_CASE_LABEL): Undefine.
268 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
269 (TARGET_BI_BIH): Define.
270 (DEFAULT_BRANCH_INDEX): Likewise.
271 * config/arc/arc.md (casesi): Rework to accept BI/BIH
272 instructions, remove compact_casesi use case.
273 (casesi_compact_jump): Remove.
274 (casesi_dispatch): New pattern.
275 * config/arc/arc.opt: Add mbranch-index option. Deprecate
276 compact_casesi option.
277 * doc/invoke.texi: Document mbranch-index option.
278
279 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
280
281 * config/arc/arc.c (arc_get_tp): Remove function.
282 (arc_emit_call_tls_get_addr): Likewise.
283 (arc_call_tls_get_addr): New function.
284 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
285 * config/arc/arc.md (tls_load_tp_soft): Remove.
286 (tls_gd_get_addr): Likewise.
287
288 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
289
290 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
291 (mulsi3_600_lib): Remove pattern.
292 (umulsi3_highpart_600_lib_le): Likewise.
293 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
294 (umulsidi3): Remove call to umulsidi3_600_lib.
295 (umulsidi3_600_lib): Remove pattern.
296 (peephole2): Remove peephole using the above deprecated patterns.
297
298 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
299
300 PR target/87374
301 * config/arm/arm.c (arm_option_check_internal): Disable the combined
302 use of -mslow-flash-data and -mword-relocations.
303 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
304 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
305 flag_pic.
306 * doc/invoke.texi (-mword-relocations): Mention conflict with
307 -mslow-flash-data.
308 (-mslow-flash-data): Reciprocally.
309
310 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
311
312 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
313 16-byte modes held in GP registers to use an even regno.
314
315 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
316 (aarch64_atomic_ldop_supported_p): Remove.
317 (aarch64_gen_atomic_ldop): Remove.
318 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
319 Fully expand LSE operations here.
320 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
321 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
322 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
323 and use ATOMIC_LDOP instead; use register_operand for the input;
324 drop the split and emit insns directly.
325 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
326 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
327 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
328
329 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
330 (aarch64_gen_atomic_ldop): Don't call it.
331 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
332 Use aarch64_reg_or_zero.
333 (aarch64_atomic_exchange<ALLI>): Likewise.
334 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
335 operand 0; use aarch64_reg_or_zero for input; merge ...
336 (@aarch64_atomic_swp<ALLI>): ... this and remove.
337
338 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
339 (aarch64_split_compare_and_swap): Use it.
340 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
341 test oldval against the proper predicate.
342 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
343 Use nonmemory_operand for expected.
344 (cas_short_expected_pred): New.
345 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
346 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
347 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
348 (aarch64_plushi_operand): New.
349
350 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
351 Force oldval into the rval register for TARGET_LSE; emit the compare
352 during initial expansion so that it may be deleted if unused.
353 (aarch64_gen_atomic_cas): Remove.
354 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
355 Change =&r to +r for operand 0; use match_dup for operand 2;
356 remove is_weak and mod_f operands as unused. Drop the split
357 and merge with...
358 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
359 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
360 (@aarch64_atomic_cas<GPI>): Similarly.
361
362 2018-10-31 Richard Biener <rguenther@suse.de>
363
364 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
365 using ABSU_EXPR.
366
367 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
368
369 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
370 * config/aarch64/aarch64.md: Include saphira.md
371 * config/aarch64/saphira.md: New file for pipeline description.
372
373 2018-10-30 Martin Sebor <msebor@redhat.com>
374
375 PR middle-end/87041
376 * gimple-ssa-sprintf.c (format_directive): Use %G to include
377 inlining context.
378 (sprintf_dom_walker::compute_format_length):
379 Avoid setting POSUNDER4K here.
380 (get_destination_size): Handle null argument values.
381 (get_user_idx_format): New function.
382 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
383 functions, including user-defined with attribute format printf.
384 Use %G to include inlining context.
385 Set POSUNDER4K here.
386
387 2018-10-30 Jan Hubicka <jh@suse.cz>
388
389 * params.def (lto-partitions): Bump from 32 to 128.
390
391 2018-10-30 Jan Hubicka <jh@suse.cz>
392
393 * tree.c
394 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
395 head in file.
396 (free_lang_data_in_type): Forward declare.
397 (fld_type_variant_equal_p): New function.
398 (fld_type_variant): New function
399 (fld_incomplete_types): New hash.
400 (fld_incomplete_type_of): New function
401 (fld_simplfied-type): New function.
402 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
403 (free_lang_data): Allocate and free fld_incomplete_type; update call
404 of free_lang_data_in_decl.
405
406 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
407
408 * gcov.c (output_lines): Remove duplicate line.
409
410 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
411
412 * config/rs6000/rs6000.md (bswapdi2): Force address into register
413 if not in indexed or indirect form.
414 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
415 (bswapdi2_store): Ditto.
416 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
417 helper function.
418 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
419 Prototype for helper function.
420
421 2018-10-30 Martin Sebor <msebor@redhat.com>
422
423 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
424 (target, pragma GCC optimize, pragma GCC target): Ditto.
425
426 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
427
428 * doc/extend.texi: Fix prototype and description of
429 __builtin_expect_with_probability.
430
431 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
432
433 * cgraph.h (clone_function_name_1): Replaced by new
434 clone_function_name_numbered that takes name as string; for
435 privatize_symbol_name_1 use only.
436 (clone_function_name): Renamed to
437 clone_function_name_numbered to be explicit about numbering.
438 (clone_function_name): New two-argument function that does
439 not number its output.
440 (clone_function_name): New three-argument function that
441 takes a number to append to its output.
442 * cgraphclones.c (duplicate_thunk_for_node):
443 (clone_function_name_1): Renamed.
444 (clone_function_name_numbered): Two new functions.
445 (clone_function_name): Improved documentation.
446 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
447 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
448 * final.c (final_scan_insn_1): Use the new clone_function_name
449 without numbering.
450 * multiple_target.c (create_dispatcher_calls): Ditto.
451 (create_target_clone): Ditto.
452 * omp-expand.c (grid_expand_target_grid_body): Ditto.
453 * omp-low.c (create_omp_child_function_name): Ditto.
454 * omp-simd-clone.c (simd_clone_create): Ditto.
455 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
456 new clone_function_name without numbering.
457
458 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
459
460 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
461 Assert that the allocation size is not zero.
462
463 2018-10-30 Richard Biener <rguenther@suse.de>
464
465 PR tree-optimization/87800
466 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
467 non-induction or reduction PHIs.
468
469 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org
470
471 * config/aarch64/falkor-tag-collision-avoidance.c
472 (execute_tag_collision_avoidance): Call df_note_add_problem.
473
474 2018-10-30 Martin Liska <mliska@suse.cz>
475
476 * doc/extend.texi: Fix typo in documentation
477 of __builtin_expect_with_probability.
478
479 2018-10-29 David Malcolm <dmalcolm@redhat.com>
480
481 PR c++/87721
482 * input.c (get_substring_ranges_for_loc): Detect if
483 linemap_resolve_location gives us a NULL map, and reject
484 this case.
485
486 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
487
488 * config.gcc (xstormy16-*-elf): Set tm_d_file.
489
490 2018-10-29 David Malcolm <dmalcolm@redhat.com>
491 Martin Sebor <msebor@redhat.com>
492 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
493
494 * doc/ux.texi (Quoting): New subsection, adapted from material at
495 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
496 MartinSebor and ManuelLopezIbanez.
497 (Fix-it hints): Note that fix-it hints shouldn't be marked for
498 translation.
499
500 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
501
502 PR middle-end/87469
503 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
504 max value.
505
506 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
507
508 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
509
510 2018-10-29 Paul Koning <ni1d@arrl.net>
511
512 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
513
514 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
515
516 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
517 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
518 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
519 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
520 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
521 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
522 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
523 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
524 Change 'vector' to '__vector'.
525 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
526 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
527 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
528 _mm_avg_pu16): Likewise. And, whitespace corrections.
529
530 2018-10-29 Richard Biener <rguenther@suse.de>
531
532 PR tree-optimization/87785
533 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
534 internal defs.
535
536 2018-10-29 Olivier Hainque <hainque@adacore.com>
537
538 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
539
540 2018-10-29 Olivier Hainque <hainque@adacore.com>
541
542 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
543 ports configuration macro, defaults to "gnu".
544 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
545 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
546
547 2018-10-29 Olivier Hainque <hainque@adacore.com>
548
549 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
550
551 2018-10-29 Richard Biener <rguenther@suse.de>
552
553 PR tree-optimization/87790
554 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
555 (vect_make_slp_decision): Adjust.
556 (vect_slp_analyze_bb_1): Likewise.
557 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
558 edges.
559
560 2018-10-29 Richard Biener <rguenther@suse.de>
561
562 PR tree-optimization/87785
563 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
564 and processing.
565 (vect_build_slp_tree): Likewise.
566 (vect_gather_slp_loads): New function.
567 (vect_analyze_slp_instance): Gather loads separately from the
568 SLP tree build.
569
570 2018-10-29 Martin Liska <mliska@suse.cz>
571
572 * Makefile.in: Make dependency to json.o.
573 * doc/gcov.texi: Document new JSON format, remove
574 old intermediate format documentation.
575 * gcov.c (struct function_info): Come up with m_name and
576 m_demangled_name.
577 (function_info::function_info): Initialize it.
578 (function_info::~function_info): Release it.
579 (main): Rename flag_intermediate_format to flag_json_format.
580 (print_usage): Describe --json-format.
581 (process_args): Set flag_json_format.
582 (output_intermediate_line): Remove.
583 (output_intermediate_json_line): Likewise.
584 (get_gcov_intermediate_filename): Return new extension
585 ".gcov.json.gz".
586 (output_intermediate_file): Implement JSON emission.
587 (output_json_intermediate_file): Implement JSON emission.
588 (generate_results): Use ::get_name for function name.
589 Handle JSON output file.
590 (read_graph_file): Use ::get_name instead of cplus_demangle.
591 (read_count_file): Likewise.
592 (solve_flow_graph): Likewise.
593 (add_line_counts): Likewise.
594 (accumulate_line_counts): Use new flag_json_format.
595 (output_function_details): Use ::get_name instead of cplus_demangle.
596 (output_lines): Likewise.
597 * json.cc (test_writing_literals): Add new tests.
598 * json.h (class literal): Add new boolean constructor.
599
600 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
601
602 PR rtl-optimization/87701
603 PR rtl-optimization/87780
604 * combine.c (make_more_copies): Rewrite.
605
606 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
607
608 * doc/generic.texi (ABSU_EXPR): Document.
609 * match.pd (absu(x)*absu(x) -> x*x): Handle.
610 (absu(absu(X)) -> absu(X)): Likewise.
611 (absu(-X) -> absu(X)): Likewise.
612 (absu(X) where X is nonnegative -> X): Likewise.
613
614 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
615
616 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
617 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
618 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
619 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
620 (s-tm-texi): Also check timestamp on d-target.def.
621 (generated_files): Add TM_D_H and d-target-hooks-def.h.
622 (build/genhooks.o): Also depend on D_TARGET_DEF.
623 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
624 variables.
625 * config/aarch64/aarch64-d.c: New file.
626 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
627 Define.
628 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
629 prototype.
630 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
631 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
632 * config/arm/arm-d.c: New file.
633 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
634 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
635 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
636 * config/arm/t-arm (arm-d.o): New rule.
637 * config/default-d.c: New file.
638 * config/glibc-d.c: New file.
639 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
640 * config/i386/i386-d.c: New file.
641 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
642 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
643 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
644 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
645 * config/i386/t-i386 (i386-d.o): New rule.
646 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
647 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
648 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
649 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
650 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
651 * config/mips/mips-d.c: New file.
652 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
653 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
654 * config/mips/t-mips (mips-d.o): New rule.
655 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
656 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
657 * config/powerpcspe/powerpcspe-d.c: New file.
658 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
659 New prototype.
660 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
661 Support GNU D by using 0 as the language type.
662 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
663 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
664 * config/riscv/riscv-d.c: New file.
665 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
666 prototype.
667 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
668 * config/riscv/t-riscv (riscv-d.o): New rule.
669 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
670 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
671 * config/rs6000/rs6000-d.c: New file.
672 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
673 prototype.
674 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
675 Support GNU D by using 0 as the language type.
676 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
677 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
678 * config/s390/s390-d.c: New file.
679 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
680 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
681 * config/s390/t-s390 (s390-d.o): New rule.
682 * config/sparc/sparc-d.c: New file.
683 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
684 prototype.
685 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
686 * config/sparc/t-sparc (sparc-d.o): New rule.
687 * config/t-glibc (glibc-d.o): New rule.
688 * configure: Regenerated.
689 * configure.ac (tm_d_file): New variable.
690 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
691 * doc/contrib.texi (Contributors): Add self for the D frontend.
692 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
693 * doc/install.texi (Configuration): Mention libphobos as an option for
694 --enable-shared. Mention d as an option for --enable-languages.
695 (Testing): Mention check-d as a target.
696 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
697 name suffixes. Mention d as a -x option.
698 * doc/sourcebuild.texi (Top Level): Mention libphobos.
699 * doc/standards.texi (Standards): Add section on D language.
700 * doc/tm.texi: Regenerated.
701 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
702 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
703 * dwarf2out.c (is_dlang): New function.
704 (gen_compile_unit_die): Use DW_LANG_D for D.
705 (declare_in_namespace): Return module die for D, instead of adding
706 extra declarations into the namespace.
707 (gen_namespace_die): Generate DW_TAG_module for D.
708 (gen_decl_die): Handle CONST_DECLSs for D.
709 (dwarf2out_decl): Likewise.
710 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
711 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
712 kinds of aggregates.
713 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
714 * genhooks.c: Include d/d-target.def.
715
716 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
717
718 PR target/85669
719 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
720 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
721 (STACK_DYNAMIC_OFFSET): Likewise.
722
723 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
724
725 PR target/80024
726 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
727 error message.
728
729 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
730
731 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
732 return type and other typos.
733
734 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
735
736 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
737 a shorter sequence with fewer branches.
738 (emit_final_str_compare_gpr): Ditto.
739
740 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
741
742 * config/rs6000/tmmintrin.h: New file.
743 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
744
745 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
746
747 * config/rs6000/mmintrin.h: Enable 32bit compilation.
748 * config/rs6000/xmmintrin.h: Likewise.
749
750 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
751
752 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
753
754 2018-10-26 Richard Biener <rguenther@suse.de>
755
756 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
757 and wrapper.
758 (vect_mark_slp_stmts_relevant): Likewise.
759 (vect_detect_hybrid_slp_stmts): Likewise.
760 (vect_bb_slp_scalar_cost): Likewise.
761 (vect_remove_slp_scalar_calls): Likewise.
762
763 2018-10-26 Jan Hubicka <jh@suse.cz>
764
765 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
766 (warn_types_mismatch): Fix walk of DECL_NAME.
767 (odr_types_equivalent_p): Fix overactive assert.
768
769 2018-10-26 Richard Biener <rguenther@suse.de>
770
771 PR tree-optimization/87105
772 * tree-vectorizer.h (_slp_tree::refcnt): New member.
773 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
774 refcnt.
775 (vect_create_new_slp_node): Initialize refcnt to one.
776 (bst_traits): Move.
777 (scalar_stmts_set_t, bst_fail): Remove.
778 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
779 (vect_build_slp_tree): Add bst_map argument and lookup
780 already created SLP nodes.
781 (vect_print_slp_tree): Handle a SLP graph, print SLP node
782 addresses.
783 (vect_slp_rearrange_stmts): Handle a SLP graph.
784 (vect_analyze_slp_instance): Adjust and free SLP nodes from
785 the CSE map. Fix indenting.
786 (vect_schedule_slp_instance): Add short-cut.
787
788 2018-10-26 Martin Liska <mliska@suse.cz>
789
790 PR testsuite/86158
791 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
792 addr_expr and not with pointers.
793
794 2018-10-26 Jan Hubicka <jh@suse.cz>
795
796 * tree.c (free_lang_data_in_type): Only check main variants.
797 * ipa-devirt.c (warn_odr): Make static.
798 (types_same_for_odr): Drop strict variant.
799 (types_odr_comparable): Likewise.
800 (odr_or_derived_type_p): Look for main variants.
801 (odr_name_hasher::equal): Cleanup comment.
802 (odr_subtypes_equivalent): Add warn and warned arguments; check main
803 variants.
804 (type_variants_equivalent_p): break out from ...
805 (odr_types_equivalent): ... here; go for main variants where needed.
806 (warn_odr): ... here; turn static.
807 (warn_types_mismatch): Compare mangled names of main variants.
808 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
809 (type_with_linkage_p): Sanity check that we look at main variant.
810 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
811 * tree.h (types_same_for_odr): Drop strict argument.
812
813 2018-10-26 Richard Biener <rguenther@suse.de>
814
815 PR tree-optimization/87746
816 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
817 Simplify and fix WRT strided store groups with size not
818 equal to step in element count.
819 (vect_analyze_group_access_1): Dump the whole group.
820
821 2018-10-25 Carl Love <cel@us.ibm.com>
822
823 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
824 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
825 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
826 precicion entry for each overloaded builtin.
827 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
828 VSCEDPUO): Rename overloaded name.
829 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
830 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
831 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
832 define_expand for xscmpexqp instruction.
833 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
834
835 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
836 Jinsong Ji <jji@us.ibm.com>
837
838 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
839 function with vec_sl.
840 (_mm_slli_epi32): Likewise.
841 (_mm_slli_epi64): Likewise.
842 (_mm_srai_epi16): Replace deprecated function with vec_sra.
843 (_mm_srai_epi32): Likewise.
844 (_mm_srli_epi16): Replace deprecated function with vec_sr.
845 (_mm_srli_epi32): Likewise.
846 (_mm_srli_epi64): Likewise.
847 (_mm_sll_epi16): Replace deprecated function with vec_sl.
848 (_mm_sll_epi32): Likewise.
849 (_mm_sll_epi64): Likewise.
850 (_mm_sra_epi16): Replace deprecated function with vec_sra.
851 (_mm_sra_epi32): Likewise.
852 (_mm_srl_epi16): Replace deprecated function with vec_sr.
853 (_mm_srl_epi32): Likewise.
854 (_mm_srl_epi64): Likewise.
855
856 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
857 Jinsong Ji <jji@us.ibm.com>
858
859 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
860 comparison operators with vec_cmp* for compatibility due to
861 unfortunate history; clean up formatting and use types more
862 appropriately.
863 (_mm_sll_epi32): Likewise.
864 (_mm_sll_epi64): Likewise.
865 (_mm_srl_epi16): Likewise.
866 (_mm_srl_epi32): Likewise.
867 (_mm_srl_epi64): Likewise.
868
869 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
870 Jinsong Ji <jji@us.ibm.com>
871
872 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
873 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
874 __vector __bool int. Use vec_cmpgt in preference to deprecated
875 function vec_vcmpgtfp.
876 (_mm_max_ps): Likewise.
877
878 2018-10-25 Jeff Law <law@redhat.com>
879
880 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
881 if returning false.
882
883 2018-10-25 Martin Sebor <msebor@redhat.com>
884
885 * doc/extend.texi (aligned): Expand attribute description.
886 (Alignment): Rename section. Discuss function arguments.
887
888 2018-10-25 Jan Hubicka <jh@suse.cz>
889
890 * ipa-devirt.c (main_odr_variant): Remove.
891 (hash_odr_name, types_same_for_odr, types_odr_comparable,
892 odr_name_hasher::equal, odr_subtypes_equivalent_p):
893 Drop use of main_odr_variant.
894 (add_type_duplicate): Silence confused warnings on integer types.
895 (get_odr_type): Always look for main variant.
896 (register_odr_type): Simplify.
897
898 2018-10-25 Richard Biener <rguenther@suse.de>
899
900 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
901 Initialize ng to silence error with release checking bootstrap.
902
903 2018-10-25 Richard Biener <rguenther@suse.de>
904
905 * tree-if-conv.c: Include tree-ssa-sccvn.h.
906 (tree_if_conversion): Run CSE on the if-converted loop body.
907
908 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
909
910 * config/s390/constraints.md (ZL): New constraint.
911 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
912 operands.
913 * config/s390/s390.md (movdi_larl): Remove.
914 (movdi_64): Add the LARL alternative.
915
916 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
917
918 PR bootstrap/87747
919 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
920 (RTX_CODE_HWINT_P): New macro.
921 (rtx_code_size): Use RTX_CODE_HWINT_P ().
922
923 2018-10-25 Jan Hubicka <jh@suse.cz>
924
925 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
926 is anonymous.
927
928 2018-10-25 Richard Biener <rguenther@suse.de>
929
930 PR tree-optimization/87665
931 PR tree-optimization/87745
932 * tree-vectorizer.h (get_earlier_stmt): Remove.
933 (get_later_stmt): Pick up UID from the original non-pattern stmt.
934
935 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
936
937 * options.texi (Deprecated): Move list to Var section.
938
939 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
940 Jinsong Ji <jji@us.ibm.com>
941
942 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
943 __vector long to __vector long long.
944 (_mm_cvtpd_ps): Likewise.
945 (_mm_cvttpd_epi32): Likewise.
946 (_mm_cvtpi32_pd): Likewise.
947 (_mm_unpackhi_epi64): Likewise.
948 (_mm_unpacklo_epi64): Likewise.
949
950 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
951
952 PR rtl-optimization/87720
953 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
954
955 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
956
957 * gimple-ssa-isolate-paths.c
958 (find_implicit_erroneous_behavior): Do not change code if the
959 pass is running for warnings only.
960 (find_explicit_erroneous_behavior): Likewise.
961
962 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
963
964 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
965 Define as rs6000_mangle_decl_assembler_name.
966 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
967 long double to IEEE long double, switch the names of the long
968 double built-in functions to be <func>f128 instead of <func>l.
969
970 2018-10-24 Martin Sebor <msebor@redhat.com>
971
972 * doc/extend.texi (nonnull): List no-argument form. Reference
973 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
974
975 2018-10-24 Richard Biener <rguenther@suse.de>
976
977 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
978
979 2018-10-24 Martin Liska <mliska@suse.cz>
980
981 PR tree-optimization/84436
982 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
983 Remove.
984 (switch_conversion::contains_linear_function_p): New.
985 (switch_conversion::build_one_array): Support linear
986 transformation on input.
987 * tree-switch-conversion.h (struct switch_conversion): Add
988 contains_linear_function_p declaration.
989
990 2018-10-24 Richard Biener <rguenther@suse.de>
991
992 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
993 if its argument is CONSTANT_CLASS_P.
994
995 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
996
997 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
998 it is wrong for forward declarations.
999
1000 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
1001
1002 * config/s390/s390.c (s390_check_qrst_address): Add the missing
1003 SYMBOL_REF_P () check.
1004
1005 2018-10-24 Richard Biener <rguenther@suse.de>
1006
1007 PR tree-optimization/87105
1008 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
1009 dump classification.
1010 (vect_analyze_data_ref_accesses): Handle duplicate loads and
1011 stores by splitting the affected group after the fact.
1012 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
1013 fail the SLP build because of size constraints.
1014
1015 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1016
1017 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
1018 * configure: Regenerate.
1019 * config.in: Regenerate.
1020 * varasm.c (mergeable_string_section): Use readonly_data_section
1021 if linker doesn't support SHF_MERGE with alignment > 8.
1022 (mergeable_constant_section): Likewise.
1023
1024 2018-10-24 Richard Biener <rguenther@suse.de>
1025
1026 PR tree-optimization/84013
1027 * tree-ssa-structalias.c (struct msdi_data): New struct for
1028 marshalling data to walk_stmt_load_store_ops.
1029 (maybe_set_dependence_info): Refactor as callback for
1030 walk_stmt_load_store_ops.
1031 (compute_dependence_clique): Set restrict info on all stmt kinds.
1032
1033 2018-10-24 Martin Liska <mliska@suse.cz>
1034
1035 * cgraph.c (cgraph_node::dump):
1036 Remove reduntant dumps and make tp_first_run dump more compact.
1037
1038 2018-10-24 Richard Biener <rguenther@suse.de>
1039
1040 PR tree-optimization/87665
1041 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
1042 to reflect reality.
1043
1044 2018-10-12 Jeff Law <law@redhat.com>
1045
1046 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
1047 for H8/S.
1048
1049 2018-10-23 Richard Biener <rguenther@suse.de>
1050
1051 * tree-vrp.c (add_assert_info): Guard dump_printf with
1052 dump_enabled_p.
1053 * gimple-ssa-evrp-analyze.c
1054 (evrp_range_analyzer::record_ranges_from_incoming_edge):
1055 Use value_range::ignore_equivs_equal_p.
1056
1057 2018-10-23 Richard Biener <rguenther@suse.de>
1058
1059 PR tree-optimization/87105
1060 PR tree-optimization/87608
1061 * passes.def (pass_all_early_optimizations): Add early phi-opt
1062 after dce.
1063 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
1064 addition to debug stmts.
1065 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
1066 and abs replacement early.
1067 * tree-cfg.c (gimple_empty_block_p): Likewise.
1068
1069 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
1070
1071 PR target/86383
1072 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
1073 specified to configure.
1074 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
1075
1076 2018-10-23 Richard Biener <rguenther@suse.de>
1077
1078 PR tree-optimization/87700
1079 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
1080
1081 2018-10-23 Jakub Jelinek <jakub@redhat.com>
1082
1083 PR target/87674
1084 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
1085 second argument from __mmask16 to __mmask8.
1086 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
1087 _mm_mask_packs_epi32): Likewise.
1088 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
1089 Likewise.
1090 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
1091
1092 2018-10-23 Richard Biener <rguenther@suse.de>
1093
1094 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
1095
1096 2018-10-23 Richard Biener <rguenther@suse.de>
1097
1098 PR tree-optimization/86144
1099 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
1100 over simd attribute.
1101
1102 2018-10-23 Richard Biener <rguenther@suse.de>
1103
1104 PR tree-optimization/87693
1105 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
1106 the case we do not find the taken edge.
1107
1108 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
1109 Jinsong Ji <jji@us.ibm.com>
1110
1111 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
1112 (_mm_store_pd): Use unaligned vector type for pointer cast.
1113 (_mm_maskmoveu_si128): Likewise.
1114 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
1115 (_mm_store_ps): Use unaligned vector type for pointer cast.
1116
1117 2018-10-22 Paul Koning <ni1d@arrl.net>
1118
1119 * symtab.c (symtab_node::increase_alignment): Correct max
1120 alignment check.
1121
1122 2018-10-22 Yury Gribov <tetra2005@gmail.com>
1123
1124 PR tree-optimization/87633
1125 * match.pd: Do not generate unordered integer comparisons.
1126
1127 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1128
1129 PR rtl-optimization/87600
1130 * combine.c: Add include of expr.h.
1131 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
1132 register to a pseudo.
1133 (make_more_copies): New function, add a copy to a new pseudo after
1134 the moves from hard registers into pseudos.
1135 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
1136 later. Call make_more_copies.
1137
1138 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
1139
1140 * lra-constraints.c (process_alt_operands): New local array,
1141 matching_early_clobber. Check matching_early_clobber before
1142 decrementing reject, and set matching_early_clobber after.
1143
1144 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1145
1146 PR target/87598
1147 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
1148 call output_addr_const and hope for the best.
1149
1150 2018-10-22 Richard Biener <rguenther@suse.de>
1151
1152 * gimple-ssa-evrp-analyze.c
1153 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
1154 smarter about what ranges to use.
1155 * tree-vrp.c (add_assert_info): Dump here.
1156 (register_edge_assert_for_2): Instead of here at multiple but
1157 not all places.
1158
1159 * gcc.dg/tree-ssa/evrp12.c: New testcase.
1160 * gcc.dg/predict-6.c: Adjust.
1161 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
1162 * gcc.dg/tree-ssa/vrp02.c: Likewise.
1163 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
1164
1165 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
1166 Richard Biener <rguenther@suse.de>
1167
1168 * bitmap.h: Update data structure documentation, including a
1169 description of bitmap views as either linked-lists or splay trees.
1170 (struct bitmap_element_def): Update comments for splay tree bitmaps.
1171 (struct bitmap_head_def): Likewise.
1172 (bitmap_list_view, bitmap_tree_view): New prototypes.
1173 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
1174 tree_form fields.
1175 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
1176 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
1177 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
1178 released bitmap element here.
1179 (bitmap_element_free): Remove.
1180 (bitmap_elt_clear_from): Work on splay tree bitmaps.
1181 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
1182 this function similar ones such that linked-list bitmap implementation
1183 functions are grouped.
1184 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
1185 and moved for grouping.
1186 (bitmap_list_insert_element_after): Renamed from
1187 bitmap_elt_insert_after, and moved for grouping.
1188 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
1189 (bitmap_tree_link_left, bitmap_tree_link_right,
1190 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
1191 bitmap_tree_link_element, bitmap_tree_unlink_element,
1192 bitmap_tree_find_element): New functions for splay-tree bitmap
1193 implementation.
1194 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
1195 Renamed and moved, see above entries.
1196 (bitmap_tree_listify_from): New function to convert part of a splay
1197 tree bitmap to a linked-list bitmap.
1198 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
1199 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
1200 (bitmap_find_bit): Remove.
1201 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
1202 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
1203 Handle splay tree bitmaps.
1204 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
1205 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
1206 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
1207 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
1208 bitmap_intersect_compl_p, bitmap_ior_and_compl,
1209 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
1210 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
1211 corresponding changes to use linked-list specific bitmap_element
1212 manipulation functions as applicable for efficiency.
1213 (bitmap_tree_to_vec): New function.
1214 (debug_bitmap_elt_file): New function split out from ...
1215 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
1216 (bitmap_print): Likewise.
1217
1218 PR tree-optimization/63155
1219 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
1220 SSA edge worklists.
1221 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
1222 in tree-view.
1223
1224 2018-10-22 Martin Liska <mliska@suse.cz>
1225
1226 PR tree-optimization/87686
1227 Revert
1228 2018-08-29 Martin Liska <mliska@suse.cz>
1229
1230 * tree-switch-conversion.c (switch_conversion::expand):
1231 Strenghten assumption about gswitch statements.
1232
1233 2018-10-22 Martin Liska <mliska@suse.cz>
1234
1235 * ipa-icf.c (sem_item::compare_attributes): Remove.
1236 (sem_item::compare_referenced_symbol_properties): Use
1237 attribute_list_equal instead.
1238 (sem_function::equals_wpa): Likewise.
1239 * ipa-icf.h: Remove compare_attributes.
1240
1241 2018-10-22 Richard Biener <rguenther@suse.de>
1242
1243 PR middle-end/87682
1244 * mem-stats.h (mem_usage::operator==): Fix pasto.
1245
1246 2018-10-22 Richard Biener <rguenther@suse.de>
1247
1248 PR tree-optimization/87640
1249 * tree-vrp.c (set_value_range_with_overflow): Decompose
1250 incomplete result.
1251 (extract_range_from_binary_expr_1): Adjust.
1252
1253 2018-10-22 Martin Jambor <mjambor@suse.cz>
1254
1255 * tree-eh.h (stmt_could_throw_p): Add function parameter.
1256 (stmt_can_throw_external): Likewise.
1257 (stmt_can_throw_internal): Likewise.
1258 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
1259 (lower_eh_constructs_2): Likewise.
1260 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
1261 (stmt_can_throw_external): Likewise.
1262 (stmt_can_throw_internal): Likewise.
1263 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
1264 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
1265 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
1266 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
1267 (pass_lower_eh_dispatch::execute): Pass cfun to
1268 stmt_can_throw_external.
1269 (cleanup_empty_eh): Likewise.
1270 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
1271 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
1272 stmt_can_throw_external instead of pushing it to cfun.
1273 (symbol_table::create_edge): Likewise.
1274 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
1275 stmt_can_throw_internal.
1276 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
1277 to stmt_could_throw_p.
1278 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
1279 stmt_can_throw_internal.
1280 (pass_store_merging::execute): Likewise.
1281 * gimple-ssa-strength-reduction.c
1282 (find_candidates_dom_walker::before_dom_children): Pass cfun to
1283 stmt_could_throw_p.
1284 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
1285 stmt_can_throw_internal.
1286 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
1287 to stmt_can_throw_external.
1288 (check_stmt): Pass cfun to stmt_could_throw_p.
1289 (check_stmt): Pass cfun to stmt_can_throw_external.
1290 (pass_nothrow::execute): Likewise.
1291 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
1292 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
1293 stmt_can_throw_internal.
1294 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
1295 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
1296 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
1297 * tree-complex.c (expand_complex_libcall): Pass cfun to
1298 stmt_could_throw_p and to stmt_can_throw_internal.
1299 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
1300 * tree-inline.c (copy_edges_for_bb): Likewise.
1301 (maybe_move_debug_stmts_to_successors): Likewise.
1302 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
1303 stmt_could_throw_p.
1304 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
1305 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
1306 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
1307 stmt_can_throw_internal.
1308 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
1309 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
1310 stmt_could_throw_p.
1311 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
1312 stmt_can_throw_internal.
1313 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
1314 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
1315 stmt_could_throw_p.
1316 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
1317 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
1318 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
1319 (convert_mult_to_fma_1): Likewise.
1320 (convert_to_divmod): Likewise.
1321 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
1322 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
1323 * tree-ssa-propagate.c
1324 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
1325 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
1326 (maybe_optimize_range_tests): Likewise.
1327 (linearize_expr_tree): Likewise.
1328 (reassociate_bb): Likewise.
1329 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
1330 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
1331 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
1332 (handle_char_store): Likewise.
1333 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
1334 stmt_can_throw_internal.
1335 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
1336 stmt_could_throw_p.
1337 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
1338 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
1339 (vectorizable_simd_clone_call): Likewise.
1340 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
1341 (gimple_stringop_fixed_value): Likewise.
1342
1343 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
1344
1345 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
1346 literal pool references.
1347 (s390_check_qrst_address): Adapt to the new behavior of
1348 s390_loadrelative_operand_p ().
1349
1350 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1351
1352 PR target/72782
1353 * config/i386/sse.md (*andnot<mode>3_bcst): New.
1354
1355 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1356
1357 PR target/72782
1358 * config/i386/sse.md (*<code><mode>3_bcst): New.
1359
1360 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1361
1362 PR target/72782
1363 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
1364 V4DI, V16SI and V8DI.
1365 (*sub<mode>3<mask_name>_bcst): New.
1366 (*add<mode>3<mask_name>_bcst): Likewise.
1367
1368 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
1369 Jinsong Ji <jji@us.ibm.com>
1370
1371 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
1372 __m64 with __vector unsigned long long for compatibility.
1373 (_mm_movemask_epi8): Likewise.
1374 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
1375 (_mm_cvttps_pi32): Likewise.
1376 (_mm_cvtpi32_ps): Likewise.
1377 (_mm_cvtps_pi16): Likewise.
1378 (_mm_loadh_pi): Likewise.
1379 (_mm_storeh_pi): Likewise.
1380 (_mm_movehl_ps): Likewise.
1381 (_mm_movelh_ps): Likewise.
1382 (_mm_loadl_pi): Likewise.
1383 (_mm_storel_pi): Likewise.
1384 (_mm_movemask_ps): Likewise.
1385 (_mm_shuffle_pi16): Likewise.
1386
1387 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1388
1389 PR target/72782
1390 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
1391 __builtin_ia32_vfnmsubpd512_mask.
1392 (_mm512_mask_fnmsub_round_pd): Likewise.
1393 (_mm512_fnmsub_pd): Likewise.
1394 (_mm512_mask_fnmsub_pd): Likewise.
1395 (_mm512_maskz_fnmsub_round_pd): Use
1396 __builtin_ia32_vfnmsubpd512_maskz.
1397 (_mm512_maskz_fnmsub_pd): Likewise.
1398 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
1399 (_mm512_mask_fnmsub_round_ps): Likewise.
1400 (_mm512_fnmsub_ps): Likewise.
1401 (_mm512_mask_fnmsub_ps): Likewise.
1402 (_mm512_maskz_fnmsub_round_ps): Use
1403 __builtin_ia32_vfnmsubps512_maskz.
1404 (_mm512_maskz_fnmsub_ps): Likewise.
1405 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
1406 __builtin_ia32_vfnmsubpd256_mask.
1407 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
1408 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1409 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
1410 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1411 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1412 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
1413 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
1414 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
1415 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
1416 __builtin_ia32_vfnmsubpd.
1417 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
1418 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
1419 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
1420 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
1421 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
1422 * config/i386/i386-builtin.def: Add
1423 __builtin_ia32_vfnmsubpd256_mask,
1424 __builtin_ia32_vfnmsubpd256_maskz,
1425 __builtin_ia32_vfnmsubpd128_mask,
1426 __builtin_ia32_vfnmsubpd128_maskz,
1427 __builtin_ia32_vfnmsubps256_mask,
1428 __builtin_ia32_vfnmsubps256_maskz,
1429 __builtin_ia32_vfnmsubps128_mask,
1430 __builtin_ia32_vfnmsubps128_maskz,
1431 __builtin_ia32_vfnmsubpd512_mask,
1432 __builtin_ia32_vfnmsubpd512_maskz,
1433 __builtin_ia32_vfnmsubps512_mask,
1434 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
1435 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
1436 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
1437 __builtin_ia32_vfnmsubpd256.
1438 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
1439 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
1440 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
1441 Likewise.
1442 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
1443 Likewise.
1444 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
1445 Likewise.
1446 (fmai_vmfnmsub_<mode><round_name>): Likewise.
1447
1448 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1449
1450 PR target/72782
1451 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
1452 __builtin_ia32_vfnmaddpd512_mask.
1453 (_mm512_mask_fnmadd_round_pd): Likewise.
1454 (_mm512_fnmadd_pd): Likewise.
1455 (_mm512_mask_fnmadd_pd): Likewise.
1456 (_mm512_maskz_fnmadd_round_pd): Use
1457 __builtin_ia32_vfnmaddpd512_maskz.
1458 (_mm512_maskz_fnmadd_pd): Likewise.
1459 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
1460 (_mm512_mask_fnmadd_round_ps): Likewise.
1461 (_mm512_fnmadd_ps): Likewise.
1462 (_mm512_mask_fnmadd_ps): Likewise.
1463 (_mm512_maskz_fnmadd_round_ps): Use
1464 __builtin_ia32_vfnmaddps512_maskz.
1465 (_mm512_maskz_fnmadd_ps): Likewise.
1466 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
1467 __builtin_ia32_vfnmaddpd256_mask.
1468 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
1469 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
1470 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
1471 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1472 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1473 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
1474 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
1475 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
1476 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
1477 __builtin_ia32_vfnmaddpd.
1478 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
1479 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
1480 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
1481 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
1482 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
1483 * config/i386/i386-builtin.def: Add
1484 __builtin_ia32_vfnmaddpd256_mask,
1485 __builtin_ia32_vfnmaddpd256_maskz,
1486 __builtin_ia32_vfnmaddpd128_mask,
1487 __builtin_ia32_vfnmaddpd128_maskz,
1488 __builtin_ia32_vfnmaddps256_mask,
1489 __builtin_ia32_vfnmaddps256_maskz,
1490 __builtin_ia32_vfnmaddps128_mask,
1491 __builtin_ia32_vfnmaddps128_maskz,
1492 __builtin_ia32_vfnmaddpd512_mask,
1493 __builtin_ia32_vfnmaddpd512_maskz,
1494 __builtin_ia32_vfnmaddps512_mask,
1495 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
1496 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
1497 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
1498 __builtin_ia32_vfnmaddpd256.
1499 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
1500 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
1501 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
1502 Likewise.
1503 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
1504 Likewise.
1505 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
1506 Likewise.
1507 (fmai_vmfnmadd_<mode><round_name>): Likewise.
1508
1509 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1510
1511 PR target/72782
1512 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
1513 __builtin_ia32_vfmsubpd512_mask.
1514 (_mm512_mask_fmsub_round_pd): Likewise.
1515 (_mm512_fmsub_pd): Likewise.
1516 (_mm512_mask_fmsub_pd): Likewise.
1517 (_mm512_maskz_fmsub_round_pd): Use
1518 __builtin_ia32_vfmsubpd512_maskz.
1519 (_mm512_maskz_fmsub_pd): Likewise.
1520 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
1521 (_mm512_mask_fmsub_round_ps): Likewise.
1522 (_mm512_fmsub_ps): Likewise.
1523 (_mm512_mask_fmsub_ps): Likewise.
1524 (_mm512_maskz_fmsub_round_ps): Use
1525 __builtin_ia32_vfmsubps512_maskz.
1526 (_mm512_maskz_fmsub_ps): Likewise.
1527 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
1528 __builtin_ia32_vfmsubpd256_mask.
1529 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
1530 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1531 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
1532 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1533 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1534 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
1535 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
1536 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
1537 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
1538 __builtin_ia32_vfmsubpd.
1539 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
1540 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
1541 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
1542 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
1543 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
1544 * config/i386/i386-builtin.def: Add
1545 __builtin_ia32_vfmsubpd256_mask,
1546 __builtin_ia32_vfmsubpd256_maskz,
1547 __builtin_ia32_vfmsubpd128_mask,
1548 __builtin_ia32_vfmsubpd128_maskz,
1549 __builtin_ia32_vfmsubps256_mask,
1550 __builtin_ia32_vfmsubps256_maskz,
1551 __builtin_ia32_vfmsubps128_mask,
1552 __builtin_ia32_vfmsubps128_maskz,
1553 __builtin_ia32_vfmsubpd512_mask,
1554 __builtin_ia32_vfmsubpd512_maskz,
1555 __builtin_ia32_vfmsubps512_mask,
1556 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
1557 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
1558 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
1559 __builtin_ia32_vfmsubpd256.
1560 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
1561 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
1562 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
1563 Likewise.
1564 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
1565 Likewise.
1566 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
1567 Likewise.
1568 (fmai_vmfmsub_<mode><round_name>): Likewise.
1569
1570 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1571
1572 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
1573 Remove plus. Renamed to ...
1574 (*sub<mode>3<mask_name>_bcst): This.
1575 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
1576 (*add<mode>3<mask_name>_bcst): This.
1577
1578 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1579
1580 PR target/72782
1581 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
1582
1583 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1584
1585 PR target/87662
1586 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
1587 (_mm_or_epi32): Likewise.
1588 (_mm256_xor_epi32): Likewise.
1589 (_mm_xor_epi32): Likewise.
1590 (_mm256_or_epi64): Likewise.
1591 (_mm_or_epi64): Likewise.
1592 (_mm256_xor_epi64): Likewise.
1593 (_mm_xor_epi64): Likewise.
1594
1595 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
1596
1597 PR target/72782
1598 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
1599
1600 2018-10-20 Jakub Jelinek <jakub@redhat.com>
1601
1602 PR middle-end/87647
1603 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
1604
1605 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
1606
1607 * doc/ux.texi: Move @section directly after @node.
1608
1609 2018-10-19 Jakub Jelinek <jakub@redhat.com>
1610
1611 PR middle-end/85488
1612 PR middle-end/87649
1613 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
1614 depend closely nested inside of loop with ordered clause with
1615 a parameter.
1616
1617 2018-10-19 David Malcolm <dmalcolm@redhat.com>
1618
1619 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
1620 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
1621 * doc/ux.texi: New file.
1622
1623 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
1624
1625 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
1626 be the first CR field allocated.
1627
1628 2018-10-19 Richard Biener <rguenther@suse.de>
1629
1630 PR target/87657
1631 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
1632 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
1633
1634 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1635
1636 PR target/72782
1637 * config/i386/sse.md
1638 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
1639 (*add<mode>3<mask_name>_bcst_2): Likewise.
1640
1641 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1642
1643 * config/i386/sse.md
1644 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1645 Replace nonimmediate_operand with register_operand.
1646 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1647 Likewise.
1648 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1649 Likewise.
1650
1651 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
1652
1653 PR rtl-optimization/87596
1654 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
1655 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
1656 for instructions in FROM..TO range.
1657
1658 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
1659
1660 * cfgexpand.c (expand_one_var): Use specific wording in error message
1661 for non-local frame variables.
1662 * stor-layout.c (layout_decl): Do not issue a warning for them.
1663
1664 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
1665
1666 * haifa-sched.c (priority): Add force_recompute parameter.
1667 (apply_replacement): Call priority () with force_recompute = true.
1668 (restore_pattern): Likewise.
1669
1670 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1671
1672 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
1673 HOST_BITS_PER_WIDE_INT.
1674 (test_vector_ops_duplicate): Likewise.
1675
1676 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1677
1678 PR target/72782
1679 * config/i386/sse.md (VF_AVX512): New.
1680 (avx512bcst): Likewise.
1681 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1682 Likewise.
1683 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1684 Likewise.
1685 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1686 Likewise.
1687
1688 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
1689
1690 * doc/invoke.texi (-dumpversion): Improve grammar.
1691 (-dumpfullversion): Make more consistent with -dumpversion.
1692
1693 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
1694
1695 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
1696 Set JUMP_LABEL to the jump insn.
1697 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
1698 Predict emitted jump and add label to jump insn.
1699
1700 2018-10-18 David Malcolm <dmalcolm@redhat.com>
1701
1702 PR tree-optimization/87562
1703 * input.c (get_substring_ranges_for_loc): Use
1704 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
1705 getting the linemap for the endpoint. Verify that it's either
1706 in the same linemap as the start point's spelling location, or
1707 at least in the same file.
1708
1709 2018-10-18 Richard Biener <rguenther@suse.de>
1710
1711 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
1712 feed width-specific load/store costs through ix86_vec_cost.
1713 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
1714 (k8_cost): Likewise.
1715 (bdver_cost): Likewise.
1716 (znver1_cost): Likewise.
1717 (btver1_cost): Likewise.
1718 (btver2_cost): Likewise.
1719
1720 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1721
1722 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
1723 to simplify subreg of vec_merge.
1724
1725 2018-10-18 Richard Biener <rguenther@suse.de>
1726
1727 * config/i386/i386.c: Fix costing of vector FMA.
1728
1729 2018-10-18 Richard Biener <rguenther@suse.de>
1730
1731 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
1732 and argument.
1733 (ix86_builtin_vectorization_cost): For vec_construct properly
1734 cost insertion into SSE regs.
1735 (...): Adjust calls to ix86_vec_cost.
1736
1737 2018-10-18 Richard Biener <rguenther@suse.de>
1738
1739 PR middle-end/87087
1740 Revert
1741 2018-02-07 Richard Biener <rguenther@suse.de>
1742
1743 PR tree-optimization/84204
1744 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
1745 this place.
1746
1747 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1748
1749 PR target/87537
1750 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
1751 of vec_duplicate.
1752 (test_vector_ops_duplicate): Add test for a scalar subreg of a
1753 VEC_MERGE of a VEC_DUPLICATE.
1754
1755 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1756
1757 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
1758 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
1759 * doc/standards.texi (C Language): Document C2X.
1760 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
1761 (rl78_option_override): Handle "GNU C2X" language name.
1762
1763 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1764
1765 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
1766 Document C17 as published in 2018.
1767
1768 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
1769
1770 PR middle-end/87623
1771 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
1772 bail out if both sides do not have the same storage order.
1773
1774 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1775
1776 * bitmap.c (bitmap_head::dump): New.
1777 * bitmap.h (bitmap_head): Add dump().
1778 * gimple-ssa-evrp-analyze.c
1779 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
1780 (evrp_range_analyzer::set_ssa_range_info): Same.
1781 (evrp_range_analyzer::record_ranges_from_phis): Same.
1782 (evrp_range_analyzer::record_ranges_from_stmt): Same.
1783 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
1784 * gimple-ssa-sprintf.c (get_int_range): Same.
1785 (format_integer): Same.
1786 (sprintf_dom_walker::handle_gimple_call): Same.
1787 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
1788 (ipcp_vr_lattice::top_p): Same.
1789 (ipcp_vr_lattice::bottom_p): Same.
1790 (ipcp_vr_lattice::set_to_bottom): Same.
1791 (ipa_vr_operation_and_type_effects): Same.
1792 (propagate_vr_across_jump_function): Same.
1793 (ipcp_store_vr_results): Same.
1794 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
1795 (ipa_print_node_jump_functions_for_edge): Same.
1796 (ipa_get_value_range): Same.
1797 (ipa_compute_jump_functions_for_edge): Same.
1798 (ipa_write_jump_function): Same.
1799 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
1800 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
1801 Same.
1802 * vr-values.c (set_value_range_to_nonnegative): Same.
1803 (set_value_range_to_truthvalue): Same.
1804 (vr_values::get_value_range): Same.
1805 (vr_values::set_defs_to_varying): Same.
1806 (vr_values::update_value_range): Same.
1807 (symbolic_range_based_on_p): Same.
1808 (vr_values::op_with_boolean_value_range_p): Same.
1809 (vr_values::extract_range_for_var_from_comparison_expr): Same.
1810 (vr_values::extract_range_from_ssa_name): Same.
1811 (vr_values::extract_range_from_binary_expr): Same.
1812 (vr_values::extract_range_from_unary_expr): Same.
1813 (vr_values::extract_range_from_cond_expr): Same.
1814 (vr_values::extract_range_from_comparison): Same.
1815 (vr_values::check_for_binary_op_overflow): Same.
1816 (vr_values::extract_range_basic): Same.
1817 (vr_values::extract_range_from_assignment): Same.
1818 (compare_ranges): Same.
1819 (compare_range_with_value): Same.
1820 (vr_values::adjust_range_with_scev): Same.
1821 (vrp_valueize): Same.
1822 (vrp_valueize_1): Same.
1823 (vr_values::get_vr_for_comparison): Same.
1824 (vr_values::compare_name_with_value): Same.
1825 (vr_values::compare_names): Same.
1826 (vr_values::vrp_evaluate_conditional): Same.
1827 (find_case_label_ranges): Same.
1828 (vr_values::vrp_visit_switch_stmt): Same.
1829 (vr_values::extract_range_from_phi_node): Same.
1830 (vr_values::simplify_div_or_mod_using_ranges): Same.
1831 (vr_values::simplify_bit_ops_using_ranges): Same.
1832 (test_for_singularity): Same.
1833 (range_fits_type_p): Same.
1834 (vr_values::simplify_cond_using_ranges_1): Same.
1835 (vr_values::simplify_switch_using_ranges): Same.
1836 (vr_values::simplify_float_conversion_using_ranges): Same.
1837 (vr_values::two_valued_val_range_p): Same.
1838 (vr_values::add_equivalence): Move to value_range::equiv_add.
1839 * vr-values.h (vr_values::add_equivalence): Remove.
1840 (VR_INITIALIZER): Remove.
1841 * tree-vrp.c (value_range::set): New.
1842 (value_range::equiv_add): New.
1843 (value_range::value_range): New.
1844 (value_range::deep_copy): New.
1845 (value_range::check): New.
1846 (value_range::equal_p): New.
1847 (value_range::ignore_equivs_equal_p): New.
1848 (value_range::operator==): New.
1849 (value_range::operator!=): New.
1850 (value_range::symbolic_p): New.
1851 (value_range::numeric_p): New.
1852 (value_range::set_undefined): New.
1853 (value_range::set_varying): New.
1854 (value_range::may_contain_p): New.
1855 (value_range::equiv_clear): New.
1856 (value_range::singleton_p): New.
1857 (value_range::intersect): New.
1858 (value_range::dump): New.
1859 (value_range::set_and_canonicalize): New.
1860 (set_value_range): Adjust for value_range API.
1861 (set_value_range_to_undefined): Same.
1862 (set_value_range_to_varying): Same.
1863 (set_and_canonicalize_value_range): Same.
1864 (set_value_range_to_nonnull): Same.
1865 (set_value_range_to_null): Same.
1866 (range_is_null): Same.
1867 (range_is_nonnull): Same.
1868 (range_int_cst_p): Same.
1869 (range_int_cst_singleton_p): Same.
1870 (symbolic_range_p): Same.
1871 (range_includes_zero_p): Same.
1872 (value_range_constant_singleton): Same.
1873 (vrp_set_zero_nonzero_bits): Same.
1874 (ranges_from_anti_range): Same.
1875 (extract_range_into_wide_ints): Same.
1876 (extract_range_from_multiplicative_op): Same.
1877 (set_value_range_with_overflow): Same.
1878 (extract_range_from_binary_expr_1): Same.
1879 (extract_range_from_unary_expr): Same.
1880 (dump_value_range): Same.
1881 (debug_value_range): Same.
1882 (vrp_prop::check_array_ref): Same.
1883 (vrp_prop::check_mem_ref): Same.
1884 (vrp_prop::vrp_initialize): Same.
1885 (vrp_prop::visit_stmt): Same.
1886 (intersect_ranges): Same.
1887 (vrp_prop::visit_phi): Same.
1888 (vrp_prop::vrp_finalize): Same.
1889 (determine_value_range_1): Same.
1890 (determine_value_range): Same.
1891 (vrp_intersect_ranges_1): Rename to...
1892 (vrp_intersect_1): this.
1893 (vrp_intersect_ranges): Rename to...
1894 (value_range::intersect_helper): ...this.
1895 (vrp_meet_1): Rename to...
1896 (value_range::union_helper): ...this.
1897 (vrp_meet): Rename to...
1898 (value_range::union_): ...this.
1899 (copy_value_range): Remove.
1900 * tree-vrp.h (struct value_range): Rewrite into a proper class.
1901 (value_range::vrtype): New.
1902 (value_range::type): New.
1903 (value_range::equiv): New.
1904 (value_range::min): New.
1905 (value_range::max): New.
1906 (value_range::varying_p): New.
1907 (value_range::undefined_p): New.
1908 (value_range::null_p): New.
1909 (value_range::equiv_add): New.
1910 (copy_value_range): Remove.
1911
1912 2018-10-17 David Malcolm <dmalcolm@redhat.com>
1913
1914 * Makefile.in (SELFTEST_TARGETS): New.
1915 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
1916 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
1917 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
1918 c/Make-lang.in.
1919 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
1920 (selftest-c++-gdb, selftest-c++-valgrind): Move to
1921 cp/Make-lang.in.
1922 * configure: Regenerate.
1923 * configure.ac (selftest_languages): New.
1924
1925 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1926
1927 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
1928 overflow wraps argument.
1929 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
1930 wide_int_range_multiplicative_op.
1931 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
1932 overflow wraps argument.
1933 (wide_int_range_multiplicative_op): Same.
1934 (wide_int_range_lshift): Same.
1935 (wide_int_range_div): Same.
1936 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
1937 (wide_int_range_lshift): Same.
1938 (wide_int_range_div): Same.
1939
1940 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1941
1942 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
1943 use sign as argument.
1944 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
1945 wide_int_range_shift_undefined_p.
1946
1947 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1948
1949 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
1950 Rename to...
1951 (@despeculate_copy<ALLI_TI:mode>): ... This.
1952 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
1953 switch statement.
1954
1955 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1956
1957 * config.gcc: Obsolete *-*-solaris2.10*.
1958 * doc/install.texi (Specific, *-*-solaris2*): Document it.
1959
1960 2018-10-12 Jeff Law <law@redhat.com>
1961
1962 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
1963 reg + sym +- const_int addressing modes.
1964
1965 2018-10-15 David Malcolm <dmalcolm@redhat.com>
1966
1967 * common.opt (fdiagnostics-minimum-margin-width=): New option.
1968 * diagnostic-show-locus.c (layout::layout): Apply the minimum
1969 margin width.
1970 (layout::start_annotation_line): Only print up to 3 of the
1971 margin character, to avoid touching the left-hand side.
1972 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
1973 minimum margin width, as set by test_diagnostic_context's ctor.
1974 (selftest::test_fixit_insert_containing_newline): Likewise.
1975 (selftest::test_fixit_insert_containing_newline_2): Likewise.
1976 (selftest::test_line_numbers_multiline_range): Clear
1977 dc.min_margin_width.
1978 * diagnostic.c (diagnostic_initialize): Initialize
1979 min_margin_width.
1980 * diagnostic.h (struct diagnostic_context): Add field
1981 "min_margin_width".
1982 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
1983 * opts.c (common_handle_option): Handle
1984 OPT_fdiagnostics_minimum_margin_width_.
1985 * selftest-diagnostic.c
1986 (selftest::test_diagnostic_context::test_diagnostic_context):
1987 Initialize min_margin_width to 6.
1988 * toplev.c (general_init): Initialize global_dc->min_margin_width.
1989
1990 2018-10-15 David Malcolm <dmalcolm@redhat.com>
1991
1992 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
1993 Fix usage of "error_at_rich_loc" in the comment.
1994
1995 2018-10-15 Renlin Li <renlin.li@arm.com>
1996
1997 PR target/87563
1998 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
1999 if-conversioned loop when it contains ifn with types not
2000 supported by backend.
2001 * internal-fn.c (expand_direct_optab_fn): Add an assert.
2002 (direct_internal_fn_supported_p): New helper function.
2003 * internal-fn.h (direct_internal_fn_supported_p): Declare.
2004
2005 2018-10-15 Jakub Jelinek <jakub@redhat.com>
2006
2007 PR target/87572
2008 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2009 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2010 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2011
2012 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
2013
2014 PR tree-optimization/87022
2015 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
2016 bits in dist vector rather than the first one.
2017
2018 2018-10-15 Richard Biener <rguenther@suse.de>
2019
2020 PR middle-end/87610
2021 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
2022 (visit_loadstore): When a used restrict tag escaped verify that
2023 the points-to solution of "other" pointers do not include
2024 escaped.
2025 (compute_dependence_clique): If a used restrict tag escaped
2026 communicated that down to visit_loadstore.
2027
2028 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
2029
2030 * config/s390/s390.c (s390_expand_vec_init): Force vector element
2031 into reg if it isn't a general operand.
2032
2033 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2034
2035 PR target/87599
2036 * config/i386/sse.md (*vec_dupv2di): Add register source to
2037 movddup.
2038
2039 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2040
2041 PR target/87572
2042 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2043 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
2044 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2045 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2046
2047 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
2048
2049 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
2050 (notice_args_size): Set it in the current trace if no insn that can
2051 throw internally has been seen yet.
2052 (connect_traces): When connecting args_size between traces, allow the
2053 incoming values not to match if there is an insn setting it before the
2054 first insn that can throw internally; in that case, force the creation
2055 of a CFI note on this latter insn.
2056
2057 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
2058
2059 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
2060 the base class, because using the injected-class-name was not clearly
2061 specified until DR 176.
2062
2063 2018-10-12 Paul Koning <ni1d@arrl.net>
2064
2065 * config/pdp11/pdp11.md (doloop_end): New expander.
2066 (doloop_end_insn): renamed from "doloop_end".
2067 (addqi3): New pattern.
2068 (subqi3): New pattern.
2069 * config/pdp11/predicates.md (incdec_operand): New predicate.
2070
2071 2018-10-12 Yury Gribov <tetra2005@gmail.com>
2072
2073 PR middle-end/81376
2074 * real.c (format_helper::can_represent_integral_type_p): New function
2075 * real.h (format_helper::can_represent_integral_type_p): Ditto.
2076 * match.pd: New pattern.
2077
2078 2018-10-12 Alexandre Oliva <oliva@adacore.com>
2079
2080 * configure.ac: Introduce --enable-large-address-aware
2081 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
2082 * doc/install.texi: Document it.
2083 * configure, config.in: Rebuilt.
2084 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
2085 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
2086 (LINK_SPEC): Insert it.
2087 * config/i386/mingw-w64.h: Likewise.
2088
2089 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
2090
2091 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
2092
2093 PR rtl-optimization/87600
2094 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
2095
2096 2018-10-12 Paul Koning <ni1d@arrl.net>
2097
2098 * doc/md.texi (doloop_end): Document that the pattern code may
2099 need to check operand mode.
2100
2101 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
2102
2103 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
2104 to zero-extend between int and floating-point registers.
2105 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
2106 ldp into floating-point registers. Add type and arch attributes.
2107 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
2108 Use f_loads for type attribute.
2109
2110 2018-10-11 Martin Sebor <msebor@redhat.com>
2111
2112 * doc/extend.texi (attribute packed): Correct typos.
2113
2114 2018-10-11 Martin Sebor <msebor@redhat.com>
2115
2116 * doc/extend.texi (attribute flatten): Mention interaction with
2117 noinline.
2118
2119 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
2120
2121 PR target/87156
2122 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
2123 Set new_decl virtual flag to zero.
2124
2125 2018-10-11 Martin Sebor <msebor@redhat.com>
2126
2127 PR middle-end/87593
2128 * doc/extend.texi (attribute format_arg): Discuss using multiple
2129 attributes on a single function.
2130
2131 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
2132
2133 PR tree-optimization/86829
2134 * match.pd (sin (atan (x))): New simplification rules.
2135 (cos (atan (x))): Likewise.
2136 * real.c (build_sinatan_real): New function.
2137 * real.h (build_sinatan_real): Prototype.
2138
2139 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
2140
2141 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
2142 function.
2143 (fold_mergeeo_helper): New helper function.
2144 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
2145 intrinsics. Correct some whitespace indentation issues.
2146
2147 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
2148
2149 PR target/87511
2150 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
2151 Use HOST_WIDE_INT_1U for shift.
2152
2153 2018-10-11 Doug Rupp <rupp@adacore.com>
2154 Olivier Hainque <hainque@adacore.com>
2155
2156 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
2157 Pass --relax to the linker for RTPs.
2158 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
2159
2160 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
2161 Jan Hubicka <jh@suse.cz>
2162 Martin Jambor <mjambor@suse.cz>
2163
2164 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
2165 the same elements are repeated rather than printing all of them.
2166 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
2167 "repeated" elements.
2168 * read-rtl-function.c (test_loading_repeat): New function.
2169 (read_rtl_function_c_tests): Call test_loading_repeat.
2170 * rtl-tests.c (test_dumping_repeat): New function.
2171 (rtl_tests_c_tests): Call test_dumping_repeat.
2172
2173 2018-10-11 Richard Biener <rguenther@suse.de>
2174
2175 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
2176 bdver?_cost): Unify to ...
2177 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
2178 * config/i386/i386.c (processor_cost_table): Adjust.
2179
2180 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
2181
2182 PR middle-end/87574
2183 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
2184 the thunk when expanding to GIMPLE.
2185
2186 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
2187
2188 * varasm.c (mergeable_string_section): Don't try to move zero-length
2189 strings to the merge section.
2190
2191 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
2192
2193 PR target/87573
2194 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
2195
2196 2018-10-10 Jakub Jelinek <jakub@redhat.com>
2197
2198 PR target/87550
2199 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
2200 to special_args set.
2201
2202 2018-10-10 Richard Biener <rguenther@suse.de>
2203
2204 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
2205 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
2206 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
2207 and recursing and pattern terminating the recursion on SSE
2208 vector width using ix86_expand_reduc.
2209 (reduc_sminmax_scal_<mode>): Split into part reducing to half
2210 width and recursing and SSE2 vector variant doing the final
2211 reduction with ix86_expand_reduc.
2212 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
2213 with terminating the recursion at AVX level, splitting that
2214 to SSE there.
2215
2216 2018-10-09 David Malcolm <dmalcolm@redhat.com>
2217
2218 * genmatch.c (error_cb): Rename to...
2219 (diagnostic_cb): ...this, converting int params to enums.
2220 (fatal_at): Update for renaming.
2221 (warning_at): Likewise.
2222 (main): Likewise.
2223 * input.c (selftest::ebcdic_execution_charset::apply):
2224 Update for renaming of...
2225 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
2226 to...
2227 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
2228 converting level and reason to enums.
2229 (class selftest::lexer_error_sink): Rename to...
2230 (class selftest::lexer_test_options): ...this, renaming field
2231 "m_errors" to "m_diagnostics".
2232 (selftest::lexer_test_options::apply): Update for renaming of...
2233 (selftest::lexer_test_options::on_error): ...this, renaming to...
2234 (selftest::lexer_test_options::on_diagnostic): ...this
2235 converting level and reason to enums.
2236 (selftest::test_lexer_string_locations_raw_string_unterminated):
2237 Update for renamings.
2238 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
2239 "reason".
2240
2241 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
2242
2243 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
2244 * config/rs6000/pmmintrin.h: New file.
2245
2246 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
2247
2248 PR tree-optimization/86659
2249 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
2250
2251 2018-10-09 Richard Biener <rguenther@suse.de>
2252
2253 PR tree-optimization/63155
2254 * tree-ssa-structalias.c: Include tree-ssa.h.
2255 (get_constraint_for_ssa_var): For undefs return nothing_id.
2256 (find_func_aliases): Cleanup PHI handling.
2257
2258 2018-10-09 Richard Biener <rguenther@suse.de>
2259
2260 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
2261 replacements.
2262
2263 2018-10-09 Martin Liska <mliska@suse.cz>
2264
2265 * asan.c (asan_emit_stack_protection): If a stack variable
2266 is located in a same file as current function, then emit
2267 line info into variable definition string.
2268
2269 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2270
2271 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
2272 information.
2273
2274 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2275
2276 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
2277 on the thunk.
2278
2279 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2280
2281 PR tree-optimization/86659
2282 * gimple-match.h (struct gimple_match_op): Add reverse field.
2283 (gimple_match_op::set_op): New overloaded method.
2284 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
2285 the REF_REVERSE_STORAGE_ORDER flag on the value.
2286 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
2287 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
2288
2289 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2290
2291 PR middle-end/63155
2292 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
2293 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
2294
2295 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2296
2297 PR target/87517
2298 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
2299 Defined with __builtin_ia32_vfmaddsubpd512_mask.
2300
2301 2018-10-08 Richard Biener <rguenther@suse.de>
2302
2303 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
2304 cost the same as AVX128 ones.
2305
2306 2018-10-08 Paul Koning <ni1d@arrl.net>
2307
2308 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
2309 (expand_block_move): New function.
2310 * config/pdp11/pdp11.c (output_block_move): Remove.
2311 (expand_block_move): New function.
2312 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
2313 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
2314 (*movmemhi1): Remove.
2315
2316 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
2317
2318 * config/s390/2827.md: Increase latencies for some FP instructions.
2319
2320 2018-10-08 Richard Biener <rguenther@suse.de>
2321
2322 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
2323 Open a dump scope.
2324 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
2325 * tree-vectorizer.h (dump_stmt_cost): Adjust.
2326 (add_stmt_cost): Dump return value of the hook.
2327
2328 2018-10-08 Richard Biener <rguenther@suse.de>
2329
2330 PR tree-optimization/63155
2331 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
2332 (ssa_propagation_engine::ssa_propagate): Remove redundant
2333 bitmap bit clearing.
2334
2335 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
2336
2337 PR rtl-optimization/86939
2338 PR rtl-optimization/87479
2339 * ira.h (non_conflicting_reg_copy_p): New prototype.
2340 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
2341 (make_hard_regno_dead): Don't add conflicts for register
2342 ignore_reg_for_conflicts.
2343 (make_object_dead): Likewise.
2344 (non_conflicting_reg_copy_p): New function.
2345 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
2346 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
2347 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
2348 (make_hard_regno_dead): Don't add conflicts for register
2349 ignore_reg_for_conflicts. Remove special conflict handling of
2350 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
2351 check_pic_pseudo_p and update callers.
2352 (mark_pseudo_dead): Don't add conflicts for register
2353 ignore_reg_for_conflicts.
2354 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
2355
2356 2018-10-05 Andrew Waterman <andrew@sifive.com>
2357 Jim Wilson <jimw@sifive.com>
2358
2359 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
2360 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
2361 new pattern using HONOR_SNANS that emits one extra instruction.
2362
2363 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2364
2365 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
2366 patterns): Merge SI and DI patterns to a GPR pattern.
2367 (unnamed define_insn and define_split for record form of that): Merge
2368 to a single define_insn_and_split pattern.
2369
2370 2018-10-05 David Malcolm <dmalcolm@redhat.com>
2371
2372 PR c++/56856
2373 * input.c (expand_location_to_spelling_point): Add param "aspect"
2374 and use rather than hardcoding LOCATION_ASPECT_CARET.
2375 (get_substring_ranges_for_loc): Handle the case of a single token
2376 within a macro expansion.
2377 * input.h (expand_location_to_spelling_point): Add "aspect" param,
2378 defaulting to LOCATION_ASPECT_CARET.
2379
2380 2018-10-05 Paul Koning <ni1d@arrl.net>
2381
2382 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
2383 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
2384 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
2385 (pdp11_guard_type): New function.
2386
2387 2018-10-05 Paul Koning <ni1d@arrl.net>
2388
2389 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
2390 * config/pdp11/pdp11.opt (mfloat32): Remove.
2391 (mfloat64): Remove.
2392 * doc/invoke.texi (pdp11 -mfloat32): Remove:
2393 (pdp11 -mfloat64): Remove.
2394
2395 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2396
2397 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
2398 (*cmp<mode>_cc_i387): Ditto.
2399 (*cmpu<mode>_cc_i387): Ditto.
2400 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2401 * config/i386/i386.c (ix86_expand_fp_compare): Remove
2402 "scratch" argument.
2403 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
2404 Emit x86_sahf_1 pattern.
2405 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
2406 (ix86_expand_carry_flag_compare): Ditto.
2407
2408 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2409
2410 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
2411 to reg_or_0_operand. Add "C" constraint.
2412 (*cmpxf_cc_i387): Ditto.
2413 (*cmp<mode>_i387): Change operand 2 predicate
2414 to nonimm_or_0_operand. Add "C" constraint.
2415 (*cmp<mode>_cc_i387): Ditto.
2416 (*cmp<mode>_0_i387): Remove insn pattern.
2417 (*cmp<mode>_0_cc_i387): Ditto.
2418
2419 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2420
2421 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
2422 * config/i386/predicates.md (nonimm_or_0_operand): Rename
2423 from vector_move_operand. Update all uses.
2424
2425 2018-10-05 Martin Sebor <msebor@redhat.com>
2426
2427 PR tree-optimization/87490
2428 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
2429 consistently.
2430
2431 2018-10-05 Richard Biener <rguenther@suse.de>
2432
2433 PR tree-optimization/63155
2434 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
2435 vertical space in dumpfiles.
2436 * tree-ssa-propagate.h
2437 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
2438 * tree-ssa-propagate.c (cfg_blocks_back): New global.
2439 (ssa_edge_worklist_back): Likewise.
2440 (curr_order): Likewise.
2441 (cfg_blocks_get): Remove abstraction.
2442 (cfg_blocks_add): Likewise.
2443 (cfg_blocks_empty_p): Likewise.
2444 (add_ssa_edge): Add to current or next worklist based on
2445 RPO index.
2446 (add_control_edge): Likewise.
2447 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
2448 into ...
2449 (ssa_propagation_engine::ssa_propagate): ... here. Unify
2450 iteration from CFG and SSA edge worklist so we process
2451 everything in RPO order, prioritizing forward progress
2452 over iteration.
2453 (ssa_prop_init): Allocate new worklists, do not dump
2454 immediate uses.
2455 (ssa_prop_fini): Free new worklists.
2456
2457 2018-10-05 Richard Biener <rguenther@suse.de>
2458
2459 * tree-core.h (tree_block::abstract_flag): Remove.
2460 (tree_block::block_num): Make full 32bits.
2461 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
2462 * tree.h (BLOCK_ABSTRACT): Remove.
2463 * dwarf2out.c (gen_lexical_block_die): Remove dead code
2464 resulting from BLOCK_ABSTRACT being always false.
2465 (gen_inlined_subroutine_die): Likewise.
2466 (gen_block_die): Likewise.
2467 * tree.c (block_ultimate_origin): Likewise.
2468 * tree-pretty-print.c (dump_block_node): Remove code dealing
2469 with BLOCK_ABSTRACT.
2470 * tree-ssa-live.c (dump_scope_block): Likewise.
2471 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
2472 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
2473
2474 2018-10-05 Richard Biener <rguenther@suse.de>
2475
2476 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
2477 is asked for initialize mode to the component mode of the
2478 vector type.
2479
2480 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2481
2482 PR target/87522
2483 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
2484 assembler for -mavx.
2485 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
2486
2487 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2488
2489 PR target/87509
2490 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
2491 RS6000_BTM_DFP.
2492 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
2493 to be DImode. When using mffscrn, force the operand to a register.
2494
2495 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
2496
2497 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
2498 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
2499 X87MODEF mode iterator.
2500 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
2501 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
2502 X87MODEF mode iterator.
2503
2504 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
2505
2506 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
2507 -Wno-prio-ctor-dtor.
2508
2509 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2510
2511 * Makefile.in (OBJS): Add opt-problem.o.
2512 * dump-context.h: Include "selftest.h.
2513 (selftest::temp_dump_context): New forward decl.
2514 (class dump_context): Make friend of class
2515 selftest::temp_dump_context.
2516 (dump_context::dump_loc_immediate): New decl.
2517 (class dump_pretty_printer): Move here from dumpfile.c.
2518 (class temp_dump_context): Move to namespace selftest.
2519 (temp_dump_context::temp_dump_context): Add param
2520 "forcibly_enable_dumping".
2521 (selftest::verify_dumped_text):
2522 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
2523 (selftest::verify_item):
2524 (ASSERT_IS_TEXT): Move here from dumpfile.c.
2525 (ASSERT_IS_TREE): Likewise.
2526 (ASSERT_IS_GIMPLE): Likewise.
2527 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
2528 to...
2529 (dump_context::dump_loc_immediate): ...this new function.
2530 (class dump_pretty_printer): Move to dump-context.h.
2531 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
2532 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
2533 (temp_dump_context::temp_dump_context): Move to "selftest"
2534 namespace. Add param "forcibly_enable_dumping", and use it to
2535 conditionalize the use of m_pp;
2536 (selftest::verify_dumped_text): Make non-static.
2537 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
2538 (selftest::verify_item): Make non-static.
2539 (ASSERT_IS_TEXT): Move to dump-context.h.
2540 (ASSERT_IS_TREE): Likewise.
2541 (ASSERT_IS_GIMPLE): Likewise.
2542 (selftest::test_capture_of_dump_calls): Pass "true" for new
2543 param of temp_dump_context.
2544 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
2545 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
2546 TDF_COMPARE_DEBUG.
2547 * opt-problem.cc: New file.
2548 * opt-problem.h: New file.
2549 * optinfo-emit-json.cc
2550 (selftest::test_building_json_from_dump_calls): Pass "true" for
2551 new param of temp_dump_context.
2552 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
2553 (optinfo::emit_for_opt_problem): New function.
2554 (optinfo::emit): Clarity which emit_item is used.
2555 * optinfo.h (optinfo::get_dump_location): New accessor.
2556 (optinfo::emit_for_opt_problem): New decl.
2557 (optinfo::emit): Make const.
2558 * selftest-run-tests.c (selftest::run_tests): Call
2559 selftest::opt_problem_cc_tests.
2560 * selftest.h (selftest::opt_problem_cc_tests): New decl.
2561 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
2562 bool to opt_result, converting fprintf messages to
2563 opt_result::failure_at calls. Add "stmt" param for use by the
2564 failure_at calls.
2565 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
2566 (runtime_alias_check_p): Convert return type from bool to
2567 opt_result, converting dump_printf calls to
2568 opt_result::failure_at, using the statement DDR_A for their
2569 location.
2570 (find_data_references_in_stmt): Convert return type from bool to
2571 opt_result, converting "return false" to opt_result::failure_at
2572 with a new message.
2573 * tree-data-ref.h: Include "opt-problem.h".
2574 (dr_analyze_innermost): Convert return type from bool to opt_result,
2575 and add a const gimple * param.
2576 (find_data_references_in_stmt): Convert return type from bool to
2577 opt_result.
2578 (runtime_alias_check_p): Likewise.
2579 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
2580 dr_analyze_innermost.
2581 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
2582 Convert return type from bool to opt_result, adding a message for
2583 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
2584 (vect_analyze_data_ref_dependence): Convert return type from bool
2585 to opt_result. Change sense of return type from "false"
2586 effectively meaning "no problems" to "false" meaning a problem,
2587 so that "return false" becomes "return opt_result::success".
2588 Convert "return true" calls to opt_result::failure_at, using
2589 the location of statement A rather than vect_location.
2590 (vect_analyze_data_ref_dependences): Convert return type from bool
2591 to opt_result.
2592 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
2593 calls to opt_result::failure_at, using the stmt location rather
2594 than vect_location.
2595 (vect_verify_datarefs_alignment): Convert return type from bool
2596 to opt_result.
2597 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
2598 into multiple more-tightly-scoped copies.
2599 (vect_analyze_data_refs_alignment): Convert return type from bool
2600 to opt_result.
2601 (vect_analyze_data_ref_accesses): Likewise, converting a
2602 "return false" to a "return opt_result::failure_at", adding a
2603 new message.
2604 (vect_prune_runtime_alias_test_list): Convert return type from
2605 bool to opt_result, converting dump_printf_loc to
2606 opt_result::failure_at. Add a %G to show the pertinent statement,
2607 and use the stmt's location rather than vect_location.
2608 (vect_find_stmt_data_reference): Convert return type from
2609 bool to opt_result, converting dump_printf_loc to
2610 opt_result::failure_at, using stmt's location.
2611 (vect_analyze_data_refs): Convert return type from bool to
2612 opt_result. Convert "return false" to "return
2613 opt_result::failure_at", adding messages as needed.
2614 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
2615 type from bool to opt_result.
2616 (vect_determine_vf_for_stmt): Likewise.
2617 (vect_determine_vectorization_factor): Likewise, converting
2618 dump_printf_loc to opt_result::failure_at, using location of phi
2619 rather than vect_location.
2620 (vect_analyze_loop_form_1): Convert return type from bool to
2621 opt_result, converting dump_printf_loc calls, retaining the use of
2622 vect_location.
2623 (vect_analyze_loop_form): Convert return type from loop_vec_info
2624 to opt_loop_vec_info.
2625 (vect_analyze_loop_operations): Convert return type from bool to
2626 opt_result, converting dump_printf_loc calls, using the location
2627 of phi/stmt rather than vect_location where available. Convert
2628 various "return false" to "return opt_result::failure_at" with
2629 "unsupported phi" messages.
2630 (vect_get_datarefs_in_loop): Convert return type from bool to
2631 opt_result. Add a message for the
2632 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
2633 (vect_analyze_loop_2): Convert return type from bool to
2634 opt_result. Ensure "ok" is set to a opt_result::failure_at before
2635 each "goto again;", adding new messages where needed.
2636 Add "unsupported grouped {store|load}" messages.
2637 (vect_analyze_loop): Convert return type from loop_vec_info to
2638 opt_loop_vec_info.
2639 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
2640 bool to opt_result.
2641 * tree-vect-stmts.c (process_use): Likewise, converting
2642 dump_printf_loc call and using stmt location, rather than
2643 vect_location.
2644 (vect_mark_stmts_to_be_vectorized): Likeise.
2645 (vect_analyze_stmt): Likewise, adding a %G.
2646 (vect_get_vector_types_for_stmt): Convert return type from bool to
2647 opt_result, converting dump_printf_loc calls and using stmt
2648 location, rather than vect_location.
2649 (vect_get_mask_type_for_stmt): Convert return type from tree to
2650 opt_tree, converting dump_printf_loc calls and using stmt location.
2651 * tree-vectorizer.c: Include "opt-problem.h.
2652 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
2653 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
2654 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
2655 enabled, use it to report at the top level "couldn't vectorize
2656 loop" followed by the problem.
2657 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
2658 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
2659 to opt_result.
2660 (vect_analyze_stmt): Likewise.
2661 (vect_get_vector_types_for_stmt): Likewise.
2662 (tree vect_get_mask_type_for_stmt): Likewise.
2663 (vect_analyze_data_ref_dependences): Likewise.
2664 (vect_enhance_data_refs_alignment): Likewise.
2665 (vect_analyze_data_refs_alignment): Likewise.
2666 (vect_verify_datarefs_alignment): Likewise.
2667 (vect_analyze_data_ref_accesses): Likewise.
2668 (vect_prune_runtime_alias_test_list): Likewise.
2669 (vect_find_stmt_data_reference): Likewise.
2670 (vect_analyze_data_refs): Likewise.
2671 (vect_analyze_loop): Convert return type from loop_vec_info to
2672 opt_loop_vec_info.
2673 (vect_analyze_loop_form): Likewise.
2674 (vect_analyze_slp): Convert return type from bool to opt_result.
2675
2676 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2677
2678 * doc/invoke.texi (-fopt-info): Document new "internals"
2679 sub-option.
2680 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
2681 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
2682 MSG_ALL_KINDS.
2683 (optinfo_verbosity_options): Add "internals".
2684 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
2685 (dump_context::apply_dump_filter_p): New member function.
2686 (dump_context::dump_loc): Use apply_dump_filter_p rather than
2687 explicitly masking the dump_kind.
2688 (dump_context::begin_scope): Increment the scope depth first. Use
2689 apply_dump_filter_p rather than explicitly masking the dump_kind.
2690 (dump_context::emit_item): Use apply_dump_filter_p rather than
2691 explicitly masking the dump_kind.
2692 (dump_dec): Likewise.
2693 (dump_hex): Likewise.
2694 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
2695 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
2696 (opt_info_switch_p): Update handling of default
2697 MSG_OPTIMIZED_LOCATIONS to cope with default of
2698 MSG_PRIORITY_USER_FACING.
2699 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
2700 masking the dump_kind.
2701 (selftest::test_capture_of_dump_calls): Update test_dump_context
2702 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
2703 than MSG_ALL. Generalize scope test to be run at all four
2704 combinations of with/without MSG_PRIORITY_USER_FACING and
2705 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
2706 for each of the two values.
2707 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
2708 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
2709 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
2710 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
2711 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
2712 with MSG_PRIORITY_*.
2713 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
2714 dump messages as MSG_PRIORITY_USER_FACING.
2715 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
2716 about the interaction with MSG_PRIORITY_*.
2717
2718 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
2719
2720 * varasm.c (output_constant): Add new parameter merge_strings.
2721 Make strings properly zero terminated in merge string sections.
2722 (mergeable_string_section): Don't fail if the last char is non-zero.
2723 (assemble_variable_contents): Handle merge string sections.
2724 (assemble_variable): Likewise.
2725 (assemble_constant_contents): Likewise.
2726 (output_constant_def_contents): Likewise.
2727 (output_constructor_array_range,
2728 output_constructor_regular_field): Adjust call to output_constant.
2729 (output_object_block): Adjust call to assemble_constant_contents
2730 and assemble_variable_contents.
2731
2732 2018-10-04 Martin Liska <mliska@suse.cz>
2733
2734 PR c/87483
2735 * cgraphunit.c (process_function_and_variable_attributes):
2736 Warn about a function with alias attribute and a body.
2737
2738 2018-10-04 Martin Liska <mliska@suse.cz>
2739
2740 PR ipa/82625
2741 * multiple_target.c (redirect_to_specific_clone): New function.
2742 (ipa_target_clone): Use it.
2743 * tree-inline.c: Fix comment.
2744
2745 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2746
2747 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
2748 fields.
2749 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
2750 (gcc::dump_manager::register_pass): New member function, adapted
2751 from loop body in gcc::pass_manager::register_pass, adding a
2752 call to update_dfi_for_opt_info.
2753 (gcc::dump_manager::opt_info_enable_passes): Store the
2754 -fopt-info options into the new fields. Move the loop
2755 bodies into...
2756 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
2757 function.
2758 * dumpfile.h (struct opt_pass): New forward decl.
2759 (gcc::dump_manager::register_pass): New decl.
2760 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
2761 (class gcc::dump_manager): Add fields "m_optgroup_flags",
2762 "m_optinfo_flags", and "m_optinfo_filename".
2763 * passes.c (gcc::pass_manager::register_pass): Move all of the
2764 dump-handling code to gcc::dump_manager::register_pass.
2765
2766 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
2767
2768 PR rtl-optimization/87466
2769 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
2770 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
2771 * doc/tm.texi: Regenerate.
2772 * ira-lives.c (process_bb_node_lives): Use the new target hook.
2773 * lra-lives.c (process_bb_lives): Likewise.
2774 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
2775 Define.
2776
2777 2018-10-04 Tamar Christina <tamar.christina@arm.com>
2778
2779 * params.c (add_params): Fix initialization.
2780
2781 2018-10-04 Martin Liska <mliska@suse.cz>
2782
2783 PR gcov-profile/84107
2784 * tree-profile.c (init_ic_make_global_vars):
2785 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
2786 Come up with new ic_tuple* variables. Emit
2787 __gcov_indirect_call{,_topn} variables.
2788 (gimple_gen_ic_profiler): Access the variable
2789 and emit gimple.
2790 (gimple_gen_ic_func_profiler): Access
2791 __gcov_indirect_call.callee field.
2792 (gimple_init_gcov_profiler): Use ptr_type_node.
2793 * value-prof.c (gimple_ic): Use ptr_type_node.
2794
2795 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2796
2797 PR tree-optimization/85787
2798 * ipa-pure-const.c (malloc_candidate_p_1): Move most of malloc_candidate_p
2799 into this function and add support for detecting multiple phis.
2800 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
2801
2802 2018-10-04 Martin Liska <mliska@suse.cz>
2803
2804 PR ipa/87491
2805 * ipa-inline.c (inline_to_all_callers_1):
2806 Call ultimate_alias_target for node being inlined.
2807
2808 2018-10-03 Jeff Law <law@redhat.com>
2809
2810 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
2811 target's wchar_t.
2812 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
2813 * tree.h (get_typenode_from_name): Prototype.
2814
2815 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2816
2817 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
2818 Change operand 2 predicate to nonimmediate_operand.
2819 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2820
2821 2018-10-03 Martin Sebor <msebor@redhat.com>
2822 Jeff Law <law@redhat.com>
2823
2824 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
2825 initialize it.
2826 (get_string_length): Detect unterminated arrays.
2827 (format_string): Same.
2828 (format_directive): Warn about unterminated arrays.
2829 (handle_gimple_call): Mark statements with no_warning as needed.
2830
2831 2018-10-03 Jim Wilson <jimw@sifive.com>
2832
2833 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
2834 also define __riscv_abi_rve. Delete trailing white space.
2835
2836 2018-10-03 Paul Koning <ni1d@arrl.net>
2837
2838 Enable LRA register allocator for PDP11.
2839 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
2840 (R): Likewise.
2841 (D): Likewise.
2842 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
2843 * config/pdp11/pdp11.opt (-mlra): New option.
2844 * doc/invoke.texi (PDP-11 Options): Document -mlra.
2845
2846 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2847
2848 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
2849 (*<absneg:code>extend<mode>xf2): Ditto.
2850
2851 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2852
2853 PR tree-optimization/87415
2854 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
2855 precision fields.
2856
2857 2018-10-02 Jeff Law <law@redhat.com>
2858
2859 * gimple-fold.c (get_range_strlen): Only set *nonstr when
2860 an unterminated string is discovered. Bubble up range
2861 even for unterminated strings.
2862 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
2863 indicates the string was not terminated via NONSTR.
2864
2865 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2866
2867 * tree-vrp.c (extract_range_from_unary_expr): Special case all
2868 pointer conversions.
2869 Do not do anything special for anti-ranges.
2870
2871 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
2872
2873 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
2874 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
2875
2876 2018-10-03 Martin Liska <mliska@suse.cz>
2877
2878 PR gcov-profile/86109
2879 * coverage.c (coverage_begin_function): Do not
2880 mark lambdas as artificial.
2881 * tree-core.h (struct GTY): Remove tm_clone_flag
2882 and introduce new lambda_function.
2883 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
2884
2885 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
2886
2887 PR target/87474
2888 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
2889 P8_VECTOR and VSX are enabled.
2890
2891 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
2892
2893 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
2894 0x3907 as CPU model number.
2895
2896 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
2897
2898 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
2899 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
2900 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
2901 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
2902 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
2903 * config/s390/s390.md: Likewise. Rename also the cpu attribute
2904 value from arch12 to z14.
2905
2906 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
2907
2908 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
2909 (isinfxf2): Ditto.
2910 (isinf<mode>2): Ditto.
2911
2912 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
2913
2914 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
2915 before emitting fxam. Perform calculations in XFmode.
2916
2917 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
2918
2919 * match.pd (((X /[ex] A) +- B) * A): New transformation.
2920
2921 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
2922
2923 PR middle-end/87319
2924 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
2925 * tree.c (signed_or_unsigned_type_for): Handle complex.
2926
2927 2018-10-02 Jeff Law <law@redhat.com>
2928
2929 * gimple-fold.c (get_range_strlen): Remove dead code.
2930
2931 2018-10-02 Martin Sebor <msebor@redhat.com>
2932 Jeff Law <law@redhat.com>
2933
2934 * builtins.c (unterminated_array): Add new arguments.
2935 If argument is not terminated, bubble up size and exact
2936 state to callers.
2937 (expand_builtin_strnlen): Detect, avoid expanding
2938 and diagnose unterminated arrays.
2939 (c_strlen): Fill in offset of start of unterminated strings.
2940 * builtins.h (unterminated_array): Update prototype.
2941
2942 2018-10-02 Richard Biener <rguenther@suse.de>
2943
2944 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
2945 of haddv4df, first reduce to SSE width and exploit the fact
2946 that we only need element zero with the reduction result.
2947 (reduc_plus_scal_v2df): Likewise.
2948
2949 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
2950
2951 * dojump.h (do_jump): Delete.
2952 (do_jump_1): Likewise.
2953 (split_comparison): Move around.
2954 * dojump.c (do_jump): Make static.
2955 (do_jump_1): Likewise.
2956 (jumpifnot): Move around.
2957 (jumpifnot_1): Likewise.
2958 (jumpif): Likewise.
2959 (jumpif_1): Likewise.
2960 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
2961
2962 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
2963
2964 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
2965 insns in the delay slot and add_insn_after for the jump insn.
2966
2967 2018-10-02 Richard Biener <rguenther@suse.de>
2968
2969 * tree-inline.c (expand_call_inline): Use the location of
2970 the callee declaration for the inline-entry marker.
2971 * final.c (notice_source_line): Remove special-casing of
2972 NOTE_INSN_INLINE_ENTRY.
2973
2974 2018-10-01 Carl Love <cel@us.ibm.com>
2975
2976 PR 69431
2977 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
2978 (__builtin_mtfsb0): New.
2979 (__builtin_mtfsb1): New.
2980 ( __builtin_set_fpscr_rn): New.
2981 (__builtin_set_fpscr_drn): New.
2982 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
2983 (rs6000_expand_set_fpscr_rn_builtin): Add.
2984 (rs6000_expand_set_fpscr_drn_builtin): Add.
2985 (rs6000_expand_builtin): Add case statement entries for
2986 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
2987 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
2988 RS6000_BUILTIN_MFFSL.
2989 (rs6000_init_builtins): Add ftype initialization and def_builtin
2990 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
2991 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
2992 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
2993 rs6000_mffscdrn): Add define_insn.
2994 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
2995 * doc/extend.texi: Add documentation for the builtins.
2996
2997 2018-10-01 Richard Biener <rguenther@suse.de>
2998
2999 PR tree-optimization/87465
3000 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
3001 causing branch miscounts.
3002
3003 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3004
3005 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
3006 aarch64_option_default_param): New.
3007 (params.h): Include.
3008 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
3009 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
3010 stack-clash protection validation code.
3011
3012 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3013
3014 * params.c (validate_param): New.
3015 (add_params): Use it.
3016 (set_param_value): Refactor param validation into validate_param.
3017 (diagnostic.h): Include.
3018 * diagnostic.h (diagnostic_ready_p): New.
3019
3020 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3021
3022 * params.c (set_param_value):
3023 Add index of parameter being validated.
3024 * common/common-target.def (option_validate_param): New.
3025 * common/common-targhooks.h (default_option_validate_param): New.
3026 * common/common-targhooks.c (default_option_validate_param): New.
3027 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
3028 * doc/tm.texi: Regenerate.
3029
3030 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3031
3032 PR target/86486
3033 * config/aarch64/aarch64.c (aarch64_override_options_internal):
3034 Add validation for stack-clash parameters and set defaults.
3035
3036 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3037
3038 PR target/86486
3039 * configure.ac: Add stack-clash-protection-guard-size.
3040 * doc/install.texi: Document it.
3041 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
3042 * params.def: Update comment for guard-size.
3043 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
3044 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
3045 * configure: Regenerate.
3046
3047 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3048
3049 PR target/86486
3050 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
3051 STACK_DYNAMIC_OFFSET): New.
3052 * config/aarch64/aarch64.c (aarch64_layout_frame):
3053 Update outgoing args size.
3054 (aarch64_stack_clash_protection_alloca_probe_range,
3055 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3056
3057 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3058
3059 PR target/86486
3060 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
3061 probe ranges.
3062 * target.def (stack_clash_protection_alloca_probe_range): New.
3063 (stack_clash_protection_final_dynamic_probe): Remove.
3064 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
3065 (default_stack_clash_protection_final_dynamic_probe): Remove.
3066 * targhooks.c: Likewise.
3067 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3068 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
3069 * doc/tm.texi: Regenerate.
3070
3071 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3072
3073 PR target/86486
3074 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
3075 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
3076 aarch64_clamp_to_uimm12_shift): New.
3077 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
3078 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
3079
3080 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3081
3082 PR target/86486
3083 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
3084
3085 2018-10-01 Jeff Law <law@redhat.com>
3086 Richard Sandiford <richard.sandiford@linaro.org>
3087 Tamar Christina <tamar.christina@arm.com>
3088
3089 PR target/86486
3090 * config/aarch64/aarch64.md
3091 (probe_stack_range): Add k (SP) constraint.
3092 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
3093 STACK_CLASH_MAX_UNROLL_PAGES): New.
3094 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
3095 stack probes for stack clash.
3096 (aarch64_allocate_and_probe_stack_space): New.
3097 (aarch64_expand_prologue): Use it.
3098 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
3099 (aarch64_sub_sp): Add emit_move_imm optional param.
3100
3101 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
3102
3103 PR tree-optimization/87261
3104 * match.pd: Remove trailing whitespace.
3105 Add (x & y) | ~(x | y) -> ~(x ^ y),
3106 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
3107
3108 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3109
3110 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
3111 constraints.
3112 (ashlsi3_insn): Update instruction constraints.
3113 (ashrsi3_insn): Likewise.
3114 (rotrsi3): Likewise.
3115 (add_shift): Likewise.
3116 * config/arc/constraints.md (Csz): New 32 bit constraint. It
3117 avoids placing in the limm field small constants which, otherwise,
3118 could end into a small instruction.
3119
3120 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3121
3122 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
3123 destination register is not odd-even.
3124 (umaddsidi4_split): Likewise.
3125
3126 2018-10-01 Richard Biener <rguenther@suse.de>
3127
3128 * tree-inline.c (expand_call_inline): Store origin of fn
3129 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
3130 * tree.c (block_ultimate_origin): Simplify and do some
3131 checking.
3132
3133 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
3134
3135 * config/i386/mmx.md (EMMS): New int iterator.
3136 (emms): New int attribute.
3137 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
3138 EMMS int iterator. Explicitly declare clobbers.
3139 (mmx_emms): Remove expander.
3140 (mmx_femms): Ditto.
3141 * config/i386/predicates.md (emms_operation): Remove predicate.
3142 (vzeroall_pattern): New predicate.
3143 (vzeroupper_pattern): Rename from vzeroupper_operation.
3144 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
3145 vzeroupper_pattern and vzeroall_pattern predicates.
3146
3147 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
3148
3149 PR rtl-optimization/86939
3150 * ira-lives.c (make_hard_regno_born): Rename from this...
3151 (make_hard_regno_live): ... to this. Remove update to conflict
3152 information. Update function comment.
3153 (make_hard_regno_dead): Add conflict information update. Update
3154 function comment.
3155 (make_object_born): Rename from this...
3156 (make_object_live): ... to this. Remove update to conflict information.
3157 Update function comment.
3158 (make_object_dead): Add conflict information update. Update function
3159 comment.
3160 (mark_pseudo_regno_live): Call make_object_live.
3161 (mark_pseudo_regno_subword_live): Likewise.
3162 (mark_hard_reg_dead): Update function comment.
3163 (mark_hard_reg_live): Call make_hard_regno_live.
3164 (process_bb_node_lives): Likewise.
3165 * lra-lives.c (make_hard_regno_born): Rename from this...
3166 (make_hard_regno_live): ... to this. Remove update to conflict
3167 information. Remove now uneeded check_pic_pseudo_p argument.
3168 Update function comment.
3169 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
3170 to conflict information. Update function comment.
3171 (mark_pseudo_live): Remove update to conflict information. Update
3172 function comment.
3173 (mark_pseudo_dead): Add conflict information update.
3174 (mark_regno_live): Call make_hard_regno_live.
3175 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
3176 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
3177
3178 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
3179
3180 PR target/87370
3181 * config/i386/i386.c (construct_container): Use TImode for
3182 BLKmode values in 2 integer registers.
3183
3184 2018-09-29 Jeff Law <law@redhat.com>
3185
3186 * builtins.c (unterminated_array): Pass in c_strlen_data * to
3187 c_strlen rather than just a tree *.
3188 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
3189 Update recursive calls appropriately. If caller did not provide a
3190 suitable data pointer, create a local one. When a non-terminated
3191 string is discovered, bubble up information about the string via the
3192 c_strlen_data object.
3193 * builtins.h (c_strlen): Update prototype.
3194 (c_strlen_data): New structure.
3195 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
3196 For a type 2 call, if c_strlen indicates a non-terminated string
3197 use the length of the non-terminated string.
3198 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
3199
3200 2018-09-29 Jakub Jelinek <jakub@redhat.com>
3201
3202 PR target/87467
3203 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
3204 __m512d type for __A argument rather than __m512.
3205
3206 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
3207
3208 * match.pd (simple_comparison): Don't optimize if either operand is
3209 a function pointer when target needs function pointer canonicalization.
3210
3211 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3212
3213 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
3214 power5 .. power9 to remove indirection.
3215 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
3216 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
3217 ASM_CPU_476_SPEC): Delete.
3218 (ASM_CPU_SPEC): Adjust.
3219 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
3220 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
3221
3222 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3223
3224 * config.in: Delete HAVE_AS_DCI.
3225 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
3226 * config/rs6000/rs6000.h: Ditto.
3227 * configure.ac: Delete HAVE_AS_DCI.
3228 * configure: Regenerate.
3229
3230 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3231
3232 * config.in (HAVE_AS_LWSYNC): Delete.
3233 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3234 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
3235 do it as a .long .
3236 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3237 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
3238 as a .long .
3239 * configure.ac: Delete HAVE_AS_LWSYNC.
3240 * configure: Regenerate.
3241
3242 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3243 Pierre-Marie de Rodat <derodat@adacore.com>
3244
3245 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
3246 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
3247 (cgraph_node::create_thunk): Add indirect_offset parameter.
3248 (thunk_adjust): Likewise.
3249 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
3250 and initialize the corresponding field with it.
3251 (cgraph_node::dump): Dump indirect_offset field.
3252 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
3253 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
3254 (thunk_adjust): Add indirect_offset parameter and deal with it.
3255 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
3256 pass it to thunk_adjust. Do not call the target hook if it's non-zero
3257 or if the thunk is external or local. Fix formatting. Do not chain
3258 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
3259 if any, in the GIMPLE representation.
3260 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
3261 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
3262 (input_node): Read indirect_offset field.
3263 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
3264 call to thunk_adjust.
3265 * tree-nested.c (struct nesting_info): Add thunk_p field.
3266 (create_nesting_tree): Set it.
3267 (convert_all_function_calls): Copy static chain from targets to thunks.
3268 (finalize_nesting_tree_1): Return early for thunks.
3269 (unnest_nesting_tree_1): Do not finalize thunks.
3270 (gimplify_all_functions): Do not gimplify thunks.
3271
3272 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3273
3274 * opt-suggestions.c (option_proposer::build_option_suggestions):
3275 Release "option_values".
3276
3277 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3278
3279 * coverage.c (get_coverage_counts): Convert problem-reporting dump
3280 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
3281 * dumpfile.c (kind_as_string): New function.
3282 (dump_loc): Rather than a hardcoded prefix of "note: ", use
3283 kind_as_string to vary the prefix based on dump_kind.
3284 (selftest::test_capture_of_dump_calls): Update for above.
3285
3286 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3287
3288 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
3289 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
3290
3291 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3292
3293 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
3294 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
3295 INVALID_REGNUM instead of FPSR_REG.
3296 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
3297 * config/i386/i386.md: Update comment of FP compares.
3298 (fldenv): Do not clobber FPSR_REG.
3299
3300 2018-09-28 Richard Biener <rguenther@suse.de>
3301
3302 * tree.h (BLOCK_ORIGIN): New.
3303 * omp-expand.c (grid_expand_target_grid_body): Assign
3304 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
3305 * tree-inline.c (remap_block): Likewise.
3306 * auto-profile.c (get_function_decl_from_block): Simplify
3307 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
3308 * langhooks.c (lhd_print_error_function): Likewise.
3309 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
3310 Likewise.
3311 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
3312 * tree.c (block_nonartificial_location): Likewise.
3313 (block_ultimate_origin): Likewise.
3314 * tree-pretty-print.c (percent_K_format): Likewise. Remove
3315 no longer needed LTO case.
3316
3317 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
3318 Jan Hubicka <jh@suse.cz>
3319 Martin Jambor <mjambor@suse.cz>
3320
3321 * simplify-rtx.c (simplify_merge_mask): New function.
3322 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
3323 same masks are used in op1 or op2.
3324 (test_vec_merge): New function.
3325 (test_vector_ops): Call test_vec_merge.
3326
3327 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3328
3329 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
3330 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
3331 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
3332 (cypress_costs): Set it.
3333 (supersparc_costs): Likewise.
3334 (hypersparc_costs): Likewise.
3335 (leon_cost): Likewise.
3336 (leon3_costs): Likewise.
3337 (sparclet_costs): Likewise.
3338 (ultrasparc_costs): Likewise.
3339 (ultrasparc_costs): Likewise.
3340 (niagara_costs): Likewise.
3341 (niagara2_costs): Likewise.
3342 (niagara3_costs): Likewise.
3343 (niagara4_costs): Likewise.
3344 (niagara7_costs): Likewise.
3345 (m8_costs): Likewise.
3346 (TARGET_CAN_FOLLOW_JUMP): Define.
3347 (pass_work_around_errata::gate): Minor tweak.
3348 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
3349 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
3350 Automaitcally clear MASK_FSMULD mask for V7 processors.
3351 (sparc_can_follow_jump): New static function.
3352 (output_ubranch): Deal with CROSSING_JUMP_P.
3353 (sparc_use_sched_lookahead): Rewrite using switch statement.
3354 (sparc_issue_rate): Reorder.
3355 (sparc_branch_cost): New function.
3356
3357 2018-09-27 Martin Sebor <msebor@redhat.com>
3358
3359 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
3360 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
3361 (int_fits_type_p): Same.
3362
3363 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
3364
3365 * config/i386/i386.md (FPCR_REG): Remove.
3366 (UNSPEC_FLDCW): Remove.
3367 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
3368 (x86_fldcw_1): Remove insn pattern.
3369 (fnstenv): Do not clobber FPCR_REG.
3370 (fldenv): Ditto.
3371 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
3372 (CALL_USED_REGISTERS): Ditto.
3373 (REG_ALLOC_ORDER): Ditto.
3374 (REG_CLASS_CONTENTS): Ditto.
3375 (HI_REGISTER_NAMES): Ditto.
3376 (ADDITIONAL_REGISTER_NAMES): Use defines instead
3377 of numerical constants.
3378 * config/i386/i386.c (regclass_map): Remove fpsr register.
3379 (dbx_register_map): Ditto.
3380 (dbx64_register_map): Ditto.
3381 (svr4_dbx_register_map): Ditto.
3382 (print_reg): Do not handle FPCR_REG.
3383
3384 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
3385
3386 PR target/87149
3387 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
3388 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
3389 Delete, always treat as true.
3390 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
3391 Ditto. Simplify remaining code.
3392 * config/powerpcspe/powerpcspe.h: Ditto.
3393 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
3394 Simplify remaining code.
3395 (rs6000_expand_builtin): Ditto.
3396 * config/rs6000/rs6000.h: Ditto.
3397 * configure.ac: Ditto.
3398 * configure: Regenerate.
3399
3400 2018-09-27 Martin Liska <mliska@suse.cz>
3401
3402 * coverage.c (get_coverage_counts): Revert the formatting
3403 of missing profile opt info.
3404
3405 2018-09-27 Richard Biener <rguenther@suse.de>
3406
3407 PR debug/37801
3408 PR debug/87440
3409 * dwarf2out.c (set_block_origin_self): Do not mark outermost
3410 block as we do not output that.
3411 (gen_inlined_subroutine_die): Elide the originally outermost
3412 block, matching what we do for concrete instances.
3413 (decls_for_scope): Add parameter specifying whether to recurse
3414 to subblocks.
3415
3416 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
3417 Tom de Vries <tom@codesourcery.com>
3418
3419 PR 82089
3420
3421 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
3422 STORE_FLAG_VALUE == 1.
3423
3424 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
3425
3426 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
3427 constant definitions.
3428 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
3429 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
3430 ("speculation_barrier"): New expander definition.
3431
3432 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
3433
3434 PR gcov-profile/86957
3435 * common.opt: New warning option -Wmissing-profile.
3436 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
3437 * doc/invoke.texi: Document -Wmissing-profile.
3438
3439 2018-09-26 Jim Wilson <jimw@sifive.com>
3440
3441 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
3442 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
3443
3444 2018-09-26 Martin Sebor <msebor@redhat.com>
3445
3446 * tree.c (zerop): Change return type to bool.
3447 (integer_zerop, integer_onep, integer_each_onep): Same.
3448 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3449 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3450 (real_onep, real_minus_onep, chain_index): Same.
3451 (print_type_hash_statistics, type_list_equal): Same.
3452 * tree.h (zerop): Same.
3453 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
3454 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3455 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3456 (real_onep, real_minus_onep, chain_index): Same.
3457 (print_type_hash_statistics, type_list_equal): Same.
3458
3459 2018-09-26 Jim Wilson <jimw@sifive.com>
3460
3461 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
3462
3463 2018-09-26 Jakub Jelinek <jakub@redhat.com>
3464
3465 PR target/87414
3466 * config/i386/i386.c: Include debug.h and dwarf2out.h.
3467 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
3468 call.
3469
3470 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
3471
3472 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
3473
3474 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3475
3476 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
3477 and FP_SECOND_SSE_REGS.
3478 (REG_CLASS_NAMES): Ditto.
3479 (REG_CLASS_CONTENTS): Ditto.
3480 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
3481 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
3482 (ix86_preferred_output_reload_class): Ditto.
3483 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
3484 clobber constraint to "=&f".
3485 (fix_truncdi_i387): Ditto.
3486 (lrintxfdi2): Ditto.
3487 (fistdi2_<rounding>): Ditto.
3488 (fpremxf4_i387): Change "=u" constraint to "=f".
3489 (fprem1xf4_i387): Ditto.
3490 (sincosxf3): Ditto.
3491 (fptanxf4_i387): Ditto.
3492 (fxtractxf3_i387): Ditto.
3493 (fscalexf4_i387): Ditto.
3494 (atan2xf3): Change "u" constraint to "f".
3495 (fyl2xxf3_i387): Ditto.
3496 (fyl2xp1xf3_i387): Ditto.
3497
3498 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3499
3500 PR target/87439
3501 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
3502 for removed I387_MASK_PM entity.
3503
3504
3505 2018-09-26 Jeff Law <law@redhat.com>
3506 Revert
3507 2018-09-26 Alexey Neyman <stilor@att.net>
3508
3509 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3510 headers are no longer pulled in by <isl/val.h>.
3511
3512 2018-09-26 Richard Biener <rguenther@suse.de>
3513
3514 PR debug/87443
3515 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
3516 or concrete instance DIE to the tree. Create abstract origin
3517 attributes also for concrete instances.
3518
3519 2018-09-26 Alexey Neyman <stilor@att.net>
3520
3521 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3522 headers are no longer pulled in by <isl/val.h>.
3523
3524 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
3525
3526 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
3527 Use new helper functions.
3528 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
3529 Use new helper functions.
3530 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
3531 aarch_mm_needs_release): New declarations.
3532 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
3533 aarch_mm_needs_release): New.
3534
3535 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
3536
3537 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
3538 (arm32_output_mi_thunk): Deal with long calls.
3539
3540 2018-09-26 Richard Biener <rguenther@suse.de>
3541
3542 PR debug/87428
3543 PR debug/87362
3544 * tree-inline.c (expand_call_inline): When the location
3545 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
3546 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
3547 the inserted BLOCK to make inlined_function_outer_scope_p
3548 recognize it.
3549 * dwarf2out.c (add_call_src_coords_attributes): Do not add
3550 coords for reserved locations.
3551
3552 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3553
3554 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
3555 (*call_indirect_nonlocal_sysv<mode>): Ditto.
3556 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
3557 (*sibcall_nonlocal_sysv<mode>): Ditto.
3558 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
3559 (<bd>_<mode>): Ditto.
3560 (<bd>tf_<mode>): Ditto.
3561
3562 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3563
3564 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
3565 control string as a list of templates instead of as C code.
3566 (*altivec_movti): Ditto.
3567 * config/rs6000/darwin.md (movdf_low_di): Ditto.
3568
3569 2018-09-25 Jim Wilson <jimw@sifive.com>
3570
3571 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
3572 when target symbol is weak.
3573
3574 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
3575
3576 PR c/87387
3577 * builtins.c (unterminated_array): Simplify.
3578 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
3579 where pointer arithmetic is safe.
3580
3581 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3582
3583 PR target/86987
3584 * config/rs6000/altivec.md (altivec_vspltb): Use
3585 const_0_to_15_operand instead of u5bit_cint_operand.
3586 (*altivec_vspltb_internal): Ditto.
3587 (altivec_vspltb_direct): Ditto.
3588 (altivec_vsplth): Use const_0_to_7_operand instead of
3589 u5bit_cint_operand.
3590 (*altivec_vsplth_internal): Ditto.
3591 (altivec_vsplth_direct): Ditto.
3592 (altivec_vspltw): Use const_0_to_3_operand instead of
3593 u5bit_cint_operand.
3594 (*altivec_vspltw_internal): Ditto.
3595 (altivec_vspltw_direct): Ditto.
3596 (altivec_vspltsf): Ditto.
3597 (*altivec_vspltsf_internal): Ditto.
3598 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
3599 various splats with the proper size immediate. Reorder the various
3600 cases by ascending size of immediate, and put all such together.
3601
3602 2018-09-25 Richard Biener <rguenther@suse.de>
3603
3604 PR debug/83941
3605 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
3606 GC-ification.
3607 (maybe_create_die_with_external_ref): Do not create
3608 DW_TAG_imported_unit here.
3609 (add_abstract_origin_attribute): Handle external BLOCK refs.
3610 (dwarf2out_abstract_function): Simplify LTO case.
3611 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
3612 rather than using maybe_create_die_with_external_ref.
3613
3614 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
3615
3616 PR target/71278
3617 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
3618 (frndintxf2_mask_pm_i387): Ditto.
3619 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
3620 Enable for !flag_trapping_math.
3621 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
3622 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
3623 Change operand 1 predicate to nonimmediate_operand.
3624 (attr "i387_cw"): Remove mask_pm.
3625 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
3626 (enum ix86_entity): Remove I387_MASK_PM.
3627 * config/i386/i386.c (ix86_i387_mode_needed): Do not
3628 handle I387_MASK_PM.
3629 (ix86_mode_needed): Ditto.
3630 (ix86_mode_after): Ditto.
3631 (ix86_mode_entry): Ditto.
3632 (ix86_mode_exit): Ditto.
3633 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
3634
3635 2018-09-25 Jakub Jelinek <jakub@redhat.com>
3636
3637 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
3638 to_update_switch_stmts to vNULL instead of calling create on them
3639 immediately.
3640
3641 2018-09-25 Richard Biener <rguenther@suse.de>
3642
3643 PR tree-optimization/87402
3644 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
3645 (visit_phi): Re-instantiate handling of supposed to be VARYING
3646 but non-VARYING backedge value.
3647
3648 2018-09-25 Richard Biener <rguenther@suse.de>
3649
3650 PR debug/83941
3651 * dwarf2out.c (struct sym_off_pair): New.
3652 (external_die_map): New global.
3653 (lookup_decl_die): When in LTO create DIEs lazily from the
3654 external_die_map.
3655 (lookup_block_die): New function, create DIEs lazily in LTO.
3656 (equate_block_to_die): New function.
3657 (dwarf2out_die_ref_for_decl): During WPA get the association
3658 from the external DIE map.
3659 (dwarf2out_register_external_die): Record mapping into the
3660 external DIE map.
3661 (maybe_create_die_with_external_ref): New function split out from
3662 DIE generation part of old dwarf2out_register_external_die.
3663 (add_abstract_origin_attribute): Do not return the DIE. When
3664 in LTO reference externals directly.
3665 (dwarf2out_abstract_function): When in LTO ignore calls for
3666 decls with external DIEs (already present abstract instances).
3667 (gen_call_site_die): Adjust.
3668 (add_high_low_attributes): Likewise.
3669 (gen_lexical_block_die): Likewise.
3670 (gen_inlined_subroutine_die): Likewie.
3671 (gen_block_die): Likewise.
3672 (dwarf2out_inline_entry): Likewise.
3673 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
3674 DIEs.
3675
3676 2018-09-25 Martin Liska <mliska@suse.cz>
3677
3678 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
3679 integers and not by a float value.
3680
3681 2018-09-25 Martin Liska <mliska@suse.cz>
3682
3683 PR fortran/87394
3684 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
3685 instead of NULL.
3686 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
3687 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
3688 * godump.c (go_format_type): Remove extra parenthesis.
3689
3690 2018-09-25 Martin Liska <mliska@suse.cz>
3691
3692 * alias.c (set_dest_equal_p): Remove unused function.
3693 * config/i386/i386.c (def_builtin_pure2): Likewise.
3694 * diagnostic-show-locus.c (class layout): Remove
3695 unused field.
3696 (layout::layout): Likewise here.
3697 * dump-context.h (class temp_dump_context): Likewise.
3698 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
3699 (add_AT_loclistsptr): Likewise.
3700 (add_AT_offset): Likewise.
3701 (get_AT_hi_pc): Likewise.
3702 (is_comdat_die): Likewise.
3703 (type_is_enum): Likewise.
3704 (ceiling): Likewise.
3705 (add_AT_vms_delta): Likewise.
3706 (is_class_die): Likewise.
3707 * edit-context.c (class line_event): Remove unused field.
3708 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
3709 unused function.
3710 * ipa-cp.c (ipa_get_vr_lat): Likewise.
3711 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
3712 (ok_for_base_p_nonstrict): Likewise.
3713 * tree-chrec.c (is_not_constant_evolution): Likewise.
3714 (chrec_fold_poly_cst): Likewise.
3715 * tree-if-conv.c (has_pred_critical_p): Likewise.
3716 * tree-ssa-coalesce.c (print_exprs): Likewise.
3717 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
3718 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
3719 * tree-vrp.c (value_ranges_intersect_p): Likewise.
3720 (value_range_nonnegative_p): Likewise.
3721
3722 2018-09-25 Martin Liska <mliska@suse.cz>
3723
3724 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
3725 Do not handle "GNU Pascal".
3726 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
3727 Likewise.
3728 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
3729 from documentation. Likewise.
3730 * dbxout.c (dbxout_range_type): Likewise.
3731 * doc/cpp.texi: Likewise.
3732 * doc/extend.texi: Likewise.
3733 * doc/frontends.texi: Likewise.
3734 * doc/invoke.texi: Remove Pascal entry.
3735 * tree.def (CLEANUP_POINT_EXPR): Likewise.
3736 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
3737
3738 2018-09-25 Martin Liska <mliska@suse.cz>
3739
3740 PR middle-end/86078
3741 * doc/invoke.texi: Document all parameters and remove default
3742 of the parameters.
3743
3744 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
3745
3746 PR bootstrap/87417
3747 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
3748 contains HOST_WIDE_INTs when computing its size.
3749
3750 2018-09-24 Jim Wilson <jimw@sifive.com>
3751
3752 PR target/87391
3753 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
3754 not TARGET_RVE.
3755 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
3756
3757 2018-09-24 Andrew Pinski <apinski@marvell.com>
3758
3759 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
3760 access prev before checking it for NULLness in the
3761 AARCH64_FUSE_CMP_BRANCH case.
3762
3763 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
3764
3765 PR target/82699
3766 * config/i386/i386.c (rest_of_insert_endbranch): Set
3767 endbr_queued_at_entrance to true and don't insert ENDBR if
3768 x86_function_profiler will be called.
3769 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
3770 is true.
3771 * config/i386/i386.h (machine_function): Add
3772 endbr_queued_at_entrance.
3773
3774 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3775
3776 * genattrtab.c (mk_attr_alt): Use alternative_mask.
3777 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
3778 types.
3779 (check_attr_test): Use alternative_mask.
3780 (get_attr_value): Likewise.
3781 (compute_alternative_mask): Use alternative_mask and XWINT.
3782 (make_alternative_compare): Use alternative_mask.
3783 (attr_alt_subset_p): Use XWINT.
3784 (attr_alt_subset_of_compl_p): Likewise.
3785 (attr_alt_intersection): Use alternative_mask and XWINT.
3786 (attr_alt_union): Likewise.
3787 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
3788 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
3789 (simplify_test_exp): Use alternative_mask and XWINT.
3790 (write_test_expr): Use alternative_mask and XWINT, adjust bit
3791 number calculation to support 64 bits. Generate code that
3792 checks 64-bit masks.
3793 (main): Use alternative_mask.
3794 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
3795
3796 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3797
3798 PR target/80080
3799 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
3800 RETURN+USE when returning via %r14.
3801
3802 2018-09-24 Martin Liska <mliska@suse.cz>
3803
3804 * gcov.c (output_lines): Print colorization legend
3805 for both flag_use_colors and flag_use_hotness_colors.
3806 Reword the help.
3807
3808 2018-09-24 Martin Liska <mliska@suse.cz>
3809
3810 * coverage.c (get_coverage_counts): Use warning_at
3811 with current_function_decl location. Use %qD in warning
3812 message.
3813
3814 2018-09-24 Martin Liska <mliska@suse.cz>
3815
3816 * memory-block.h (memory_block_pool::release): Annotate with
3817 valgrind that the memory is not accessible.
3818
3819 2018-09-24 Martin Liska <mliska@suse.cz>
3820
3821 PR sanitizer/85774
3822 * asan.c: Make asan_handled_variables extern.
3823 * asan.h: Likewise.
3824 * cfgexpand.c (expand_stack_vars): Make sure
3825 a representative is unpoison if another
3826 variable in the partition is handled by
3827 use-after-scope sanitization.
3828
3829 2018-09-24 Richard Biener <rguenther@suse.de>
3830
3831 PR tree-optimization/63155
3832 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
3833 the worklist when the edge of the respective argument isn't
3834 executable.
3835
3836 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3837
3838 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
3839 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
3840 (MASK_CLASS_P): Update for rename.
3841 (MAYBE_MASK_CLASS_P): Ditto.
3842 (REG_CLASS_NAMES): Update.
3843 (REG_CLASS_CONTENT): Update.
3844 * config/i386/i386.c (regclass_map): Update for MASK_REG
3845 and ALL_MASK_REGS rename.
3846 * config/i386/constraints.md (Yk): Update for rename.
3847 (k): Ditto.
3848
3849 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3850
3851 * config/i386/i386.h (enum reg_class): Remove
3852 EVEX_SSE_REGS and MOD4_SSE_REGS.
3853 (REG_CLASS_NAMES): Update.
3854 (REG_CLASS_CONTENT): Update.
3855 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
3856 registers as ALL_SSE_REGS.
3857 (ix86_additional_allocno_class_p): Remove.
3858 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
3859 (ix86_register_priority): Lower priority of EVEX SSE registers.
3860 Use IN_RANGE macro where appropriate.
3861 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
3862 AVX-5124VNNIW checks.
3863 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
3864 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
3865 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
3866 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
3867 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
3868 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
3869 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
3870 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
3871 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
3872 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
3873 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
3874 * config/i386/constraints.md (Yh): Remove.
3875
3876 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3877
3878 * config/i386/i386.c (regclass_map): Declare integer REX registers
3879 as GENERAL_REGS.
3880
3881 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
3882
3883 * doc/service.texi (Service): Switch the fsf.org link to https.
3884
3885 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
3886
3887 PR target/86798
3888 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
3889 Define to speculation_safe_value_not_needed.
3890
3891 2018-09-21 Florian Weimer <fweimer@redhat.com>
3892
3893 PR middle-end/81035
3894 * doc/extend.texi (Common Function Attributes): Mention that
3895 noreturn suppresses tail call optimization.
3896
3897 2018-09-21 Jeff Law <law@redhat.com>
3898
3899 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
3900 vr_values::cleanup_edges_and_switches.
3901 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
3902 vr_values class.
3903 (identify_jump_threads): Remove EDGE_IGNORE handling.
3904 (execute_vrp): Move handling of to_remove_edges and
3905 to_update_switch_stmts into vr_values class member functions.
3906 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
3907 (to_update_switch_stmts): Likewise.
3908 * vr-values.c: Include cfghooks.h.
3909 (vr_values::vr_values): Initialize to_remove_edges and
3910 to_update_switch_stmts.
3911 (vr_values::~vr_values): Verify to_remove_edges and
3912 to_update_switch_stmts are empty.
3913 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
3914 (vr_values::cleanup_edges_and_switches): New member function.
3915 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
3916 function. Add new data members.
3917
3918 2018-09-21 David Malcolm <dmalcolm@redhat.com>
3919
3920 PR tree-optimization/87309
3921 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
3922 calls with pflags and alt_flags.
3923 (selftest::test_capture_of_dump_calls): Add test of interaction of
3924 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
3925
3926 2018-09-21 Olivier Hainque <hainque@adacore.com>
3927
3928 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
3929
3930 2018-09-21 Olivier Hainque <hainque@adacore.com>
3931
3932 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
3933
3934 2018-09-21 Olivier Hainque <hainque@adacore.com>
3935
3936 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
3937 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
3938 (VXWORKS_LIBS_RTP): Minor reordering.
3939
3940 2018-09-21 Olivier Hainque <hainque@adacore.com>
3941
3942 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
3943 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
3944
3945 2018-09-21 Olivier Hainque <hainque@adacore.com>
3946
3947 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
3948 (PTRDIFF_TYPE): Likewise.
3949
3950 2018-09-21 Olivier Hainque <hainque@adacore.com>
3951
3952 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
3953 triplet, similar to support for VxWorks7.
3954 * config/vxworks-dummy.h: Provide a default definition
3955 of TARGET_VXWORKS64 to 0.
3956
3957 2018-09-21 Olivier Hainque <hainque@adacore.com>
3958
3959 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
3960 * config/vxworks-dummy.h: here.
3961
3962 2018-09-21 Olivier Hainque <hainque@adacore.com>
3963
3964 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
3965
3966 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
3967 Bo Zhou <zbo.zhou@hisilicon.com>
3968
3969 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
3970 * config/aarch64/aarch64-tune.md: Regenerated.
3971 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
3972 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
3973 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
3974
3975 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
3976 Julian Brown <julian@codesourcery.com>
3977
3978 * builtins.c (get_builtin_sync_mem): Handle address spaces.
3979
3980 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
3981
3982 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
3983 if the call takes a static chain.
3984
3985 2018-09-21 Martin Liska <mliska@suse.cz>
3986
3987 * auto-profile.c (autofdo_source_profile::read): Do not
3988 set sum_all.
3989 (read_profile): Do not add working sets.
3990 (read_autofdo_file): Remove sum_all.
3991 (afdo_callsite_hot_enough_for_early_inline): Remove const
3992 qualifier.
3993 * coverage.c (struct counts_entry): Remove gcov_summary.
3994 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
3995 do not support GCOV_TAG_PROGRAM_SUMMARY.
3996 (get_coverage_counts): Remove summary and expected
3997 arguments.
3998 * coverage.h (get_coverage_counts): Likewise.
3999 * doc/gcov-dump.texi: Remove -w option.
4000 * gcov-dump.c (dump_working_sets): Remove.
4001 (main): Do not support '-w' option.
4002 (print_usage): Likewise.
4003 (tag_summary): Likewise.
4004 * gcov-io.c (gcov_write_summary): Do not dump
4005 histogram.
4006 (gcov_read_summary): Likewise.
4007 (gcov_histo_index): Remove.
4008 (gcov_histogram_merge): Likewise.
4009 (compute_working_sets): Likewise.
4010 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
4011 it not obsolete.
4012 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
4013 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
4014 (GCOV_HISTOGRAM_SIZE): Remove.
4015 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
4016 (struct gcov_summary): Simplify rapidly just
4017 to runs and sum_max fields.
4018 (gcov_histo_index): Remove.
4019 (NUM_GCOV_WORKING_SETS): Likewise.
4020 (compute_working_sets): Likewise.
4021 * gcov-tool.c (print_overlap_usage_message): Remove
4022 trailing empty line.
4023 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
4024 (output_lines): Remove program related line.
4025 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
4026 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
4027 histogram.
4028 (input_profile_summary): Do not read it.
4029 (merge_profile_summaries): And do not merge it.
4030 (input_symtab): Do not call removed function.
4031 * modulo-sched.c (sms_schedule): Do not print sum_max.
4032 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
4033 removed when histogram method was invented.
4034 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
4035 mode.
4036 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
4037 GCOV coding style.
4038 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
4039 and dump selected value.
4040 * profile.c (add_working_set): Remove.
4041 (get_working_sets): Likewise.
4042 (find_working_set): Likewise.
4043 (get_exec_counts): Do not work with working sets.
4044 (read_profile_edge_counts): Do not inform as sum_max is removed.
4045 (compute_branch_probabilities): Likewise.
4046 (compute_value_histograms): Remove argument for call of
4047 get_coverage_counts.
4048 * profile.h: Do not make gcov_summary const.
4049
4050 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
4051
4052 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
4053
4054 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4055
4056 PR tree-optimization/86990
4057 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
4058 Check that the entire merged store group is made of constants only for
4059 overlapping stores.
4060
4061 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
4062
4063 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
4064 (VTABLE_VERIFICATION_SPEC): Likewise.
4065 (SANITIZER_EARLY_SPEC): Likewise.
4066 (SANITIZER_SPEC): Likewise.
4067 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
4068 * doc/invoke.texi (Link Options): Document -r.
4069
4070 2018-09-20 Richard Biener <rguenther@suse.de>
4071
4072 PR middle-end/87054
4073 * gimplify.c (gimplify_expr): Retain alignment of
4074 addressable lvalue in dereference.
4075
4076 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
4077
4078 PR bootstrap/87013
4079 * configure.ac: Check for .loc is_stmt support.
4080 * configure, config.in: Rebuilt.
4081 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
4082 if not supported.
4083
4084 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4085
4086 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
4087 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
4088 -misel=no.
4089
4090 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4091
4092 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
4093 VECTOR_OTHER.
4094 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
4095 case VECTOR_OTHER.
4096
4097 2018-09-20 Marek Polacek <polacek@redhat.com>
4098
4099 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
4100
4101 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4102
4103 PR tree-optimization/87288
4104 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
4105 into account when determining PEELING_FOR_NITERS.
4106
4107 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4108
4109 PR tree-optimization/86877
4110 * tree-vect-loop.c (vect_analyze_loop_2): Call
4111 vect_verify_datarefs_alignment.
4112
4113 2018-09-19 Marek Polacek <polacek@redhat.com>
4114
4115 * doc/invoke.texi: Document -Wclass-conversion.
4116
4117 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
4118
4119 * config/pa/pa.c (pa_adjust_priority): Delete.
4120 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
4121
4122 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
4123 (atomic_storehi): Likewise.
4124 (atomic_storesi): Likewise.
4125 (atomic_loaddi): Restore compare and swap exchange loop code.
4126
4127 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
4128
4129 PR rtl-optimization/86902
4130 * combine.c (try_combine): When changing the CC mode used, don't change
4131 an unrelated mode in other_insn to that new CC mode.
4132
4133 2018-09-19 David Malcolm <dmalcolm@redhat.com>
4134
4135 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
4136 with %T in place of calls to dump_generic_expr.
4137 (prune_runtime_alias_test_list): Likewise.
4138 (create_runtime_alias_checks): Likewise.
4139 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
4140 (vect_analyze_data_ref_dependence): Likewise.
4141 (vect_slp_analyze_data_ref_dependence): Likewise.
4142 (vect_record_base_alignment): Likewise. Use %G in place of call
4143 to dump_gimple_stmt.
4144 (vect_compute_data_ref_alignment): Likewise.
4145 (verify_data_ref_alignment): Likewise.
4146 (vect_find_same_alignment_drs): Likewise.
4147 (vect_analyze_group_access_1): Likewise.
4148 (vect_analyze_data_ref_accesses): Likewise.
4149 (dependence_distance_ge_vf): Likewise.
4150 (dump_lower_bound): Likewise.
4151 (vect_prune_runtime_alias_test_list): Likewise.
4152 (vect_find_stmt_data_reference): Likewise.
4153 (vect_analyze_data_refs): Likewise.
4154 (vect_create_addr_base_for_vector_ref): Likewise.
4155 (vect_create_data_ref_ptr): Likewise.
4156 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
4157 (vect_can_advance_ivs_p): Likewise.
4158 (vect_update_ivs_after_vectorizer): Likewise.
4159 (vect_gen_prolog_loop_niters): Likewise.
4160 (vect_prepare_for_masked_peels): Likewise.
4161 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
4162 (vect_determine_vectorization_factor): Likewise.
4163 (vect_is_simple_iv_evolution): Likewise.
4164 (vect_analyze_scalar_cycles_1): Likewise.
4165 (vect_analyze_loop_operations): Likewise.
4166 (report_vect_op): Likewise.
4167 (vect_is_slp_reduction): Likewise.
4168 (check_reduction_path): Likewise.
4169 (vect_is_simple_reduction): Likewise.
4170 (vect_create_epilog_for_reduction): Likewise.
4171 (vect_finalize_reduction:): Likewise.
4172 (vectorizable_induction): Likewise.
4173 (vect_transform_loop_stmt): Likewise.
4174 (vect_transform_loop): Likewise.
4175 (optimize_mask_stores): Likewise.
4176 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
4177 (vect_split_statement): Likewise.
4178 (vect_recog_over_widening_pattern): Likewise.
4179 (vect_recog_average_pattern): Likewise.
4180 (vect_determine_min_output_precision_1): Likewise.
4181 (vect_determine_precisions_from_range): Likewise.
4182 (vect_determine_precisions_from_users): Likewise.
4183 (vect_mark_pattern_stmts): Likewise.
4184 (vect_pattern_recog_1): Likewise.
4185 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
4186 (vect_record_max_nunits): Likewise.
4187 (vect_build_slp_tree_1): Likewise.
4188 (vect_build_slp_tree_2): Likewise.
4189 (vect_print_slp_tree): Likewise.
4190 (vect_analyze_slp_instance): Likewise.
4191 (vect_detect_hybrid_slp_stmts): Likewise.
4192 (vect_detect_hybrid_slp_1): Likewise.
4193 (vect_slp_analyze_operations): Likewise.
4194 (vect_slp_analyze_bb_1): Likewise.
4195 (vect_transform_slp_perm_load): Likewise.
4196 (vect_schedule_slp_instance): Likewise.
4197 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
4198 (vect_mark_stmts_to_be_vectorized): Likewise.
4199 (vect_init_vector_1): Likewise.
4200 (vect_get_vec_def_for_operand): Likewise.
4201 (vect_finish_stmt_generation_1): Likewise.
4202 (vect_check_load_store_mask): Likewise.
4203 (vectorizable_call): Likewise.
4204 (vectorizable_conversion): Likewise.
4205 (vectorizable_operation): Likewise.
4206 (vectorizable_load): Likewise.
4207 (vect_analyze_stmt): Likewise.
4208 (vect_is_simple_use): Likewise.
4209 (vect_get_vector_types_for_stmt): Likewise.
4210 (vect_get_mask_type_for_stmt): Likewise.
4211 * tree-vectorizer.c (increase_alignment): Likewise.
4212
4213 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
4214
4215 * doc/rtl.texi: Adjust vec_select description.
4216 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
4217 non-constant selectors.
4218
4219 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
4220
4221 * config/aarch64/aarch64-protos.h
4222 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
4223 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
4224 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
4225 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
4226 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
4227 (AARCH64_FL_PROFILE): Move index so flags are ordered.
4228 (AARCH64_ISA_RCPC8_4): New flag.
4229 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
4230 to aarch64_offset_9bit_signed_unscaled_p.
4231 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
4232 and use stlur.
4233 * config/aarch64/constraints.md (Ust): New constraint.
4234 * config/aarch64/predicates.md.
4235 (aarch64_9bit_offset_memory_operand): New predicate.
4236 (aarch64_rcpc_memory_operand): New predicate.
4237
4238 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
4239
4240 PR rtl-optimization/87361
4241 * rtlanal.c (nonzero_bits1): Revert accidental change.
4242
4243 2018-09-19 Richard Biener <rguenther@suse.de>
4244
4245 PR tree-optimization/87349
4246 PR tree-optimization/87342
4247 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
4248
4249 2018-09-18 Marek Polacek <polacek@redhat.com>
4250
4251 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
4252 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
4253
4254 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4255
4256 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
4257
4258 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4259
4260 PR rtl-optimization/86882
4261 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
4262
4263 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
4264
4265 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
4266 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
4267
4268 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
4269
4270 PR other/87353
4271 * doc/invoke.texi (Link Options): Fix formatting and grammar.
4272
4273 2018-09-18 Richard Biener <rguenther@suse.de>
4274
4275 PR middle-end/63155
4276 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
4277 (compute_samebase_partition_bases): Likewise.
4278 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
4279 (gimple_can_coalesce_p): Simplify.
4280
4281 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
4282
4283 Handle a library implementation of ffs calling __builtin_ffs.
4284 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
4285 (mmix_init_libfuncs): New function: make __builtin_ffs expand
4286 to __ffsdi2.
4287
4288 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4289
4290 * diagnostic-show-locus.c (class layout_range): Add field
4291 "m_original_idx".
4292 (layout_range::layout_range): Add "original_idx" param and use it
4293 to initialize new field.
4294 (make_range): Use 0 for original_idx.
4295 (layout::layout): Pass in index to calls to
4296 maybe_add_location_range.
4297 (layout::maybe_add_location_range): Add param "original_idx" and
4298 pass it on to layout_range.
4299 (layout::print_any_labels): Pass on range->m_original_idx to
4300 get_text call.
4301 (gcc_rich_location::add_location_if_nearby): Use 0 for
4302 original_idx.
4303 * gcc-rich-location.h (text_range_label::get_text): Update for new
4304 param.
4305 (range_label_for_type_mismatch::get_text): Likewise.
4306
4307 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4308
4309 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
4310
4311 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4312
4313 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
4314 format_string_diagnostic_t.
4315 (fmtwarn_n): Likewise.
4316 * substring-locations.c
4317 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
4318 (format_warning_n_va): Convert to...
4319 (format_string_diagnostic_t::emit_warning_n_va): ...this.
4320 (format_warning_va): Convert to...
4321 (format_string_diagnostic_t::emit_warning_va): ...this.
4322 (format_warning_at_substring): Convert to...
4323 (format_string_diagnostic_t::emit_warning): ...this.
4324 (format_warning_at_substring_n): Convert to...
4325 (format_string_diagnostic_t::emit_warning_n): ...this.
4326 * substring-locations.h (class format_string_diagnostic_t): New
4327 class.
4328 (format_warning_va): Convert to
4329 format_string_diagnostic_t::emit_warning_va.
4330 (format_warning_n_va): Convert to
4331 format_string_diagnostic_t::emit_warning_n_va.
4332 (format_warning_at_substring): Convert to
4333 format_string_diagnostic_t::emit_warning.
4334 (format_warning_at_substring_n): Convert to
4335 format_string_diagnostic_t::emit_warning_n.
4336
4337 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
4338 Bernd Schmidt <bernds_cb1@t-online.de>
4339
4340 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
4341 SImode args.
4342
4343 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4344
4345 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
4346 operand 0 predicate to nonimmediate operand.
4347 (rint<mode>2_frndint): Remove insn pattern.
4348 (rint<mode>2): Change operand 1 predicate to general_operand.
4349 Extend operand 1 to XFmode and generate rintxf2 insn.
4350 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
4351 Do not use X87MODEF mode macro.
4352 (frndintxf2_<rounding>_i387): Rename from
4353 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
4354 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
4355 to XFmode and generate significandxf3 insn.
4356
4357 2018-09-17 Richard Biener <rguenther@suse.de>
4358
4359 PR tree-optimization/87328
4360 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
4361 visiting unexecutable backedges when not iterating.
4362 (do_rpo_vn): Mark all edges not executable even when not
4363 iterating.
4364
4365 2018-09-17 Martin Jambor <mjambor@suse.cz>
4366
4367 PR c/63886
4368 * doc/invoke.texi (Warning Options): Likewise.
4369
4370 2018-09-17 Richard Biener <rguenther@suse.de>
4371
4372 PR tree-optimization/87301
4373 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
4374 clean EH info from leftover copy assignments.
4375
4376 2018-09-17 Martin Liska <mliska@suse.cz>
4377
4378 PR gcov-profile/85871
4379 * gcov.c (output_intermediate_file): Fix out of bounds
4380 access.
4381
4382 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
4383
4384 * config/arc/arc.c: Object attributes for core4 not reflected
4385 correctly.
4386 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
4387 core3).
4388
4389 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
4390
4391 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
4392
4393 2018-09-17 Martin Liska <mliska@suse.cz>
4394
4395 * doc/gcov.texi: Document new option --use-hotness-colors.
4396 * gcov.c (struct source_info): Declare new field.
4397 (source_info::source_info): Set default for maximum_count.
4398 (print_usage): Add new -q option.
4399 (process_args): Process it.
4400 (accumulate_line_info): Save src->maximum_count.
4401 (output_line_beginning): Make color line number if
4402 flag_use_hotness_colors is set.
4403 (output_line_details): Pass default argument value.
4404 (output_lines): Pass src->maximum_count.
4405
4406 2018-09-17 Martin Liska <mliska@suse.cz>
4407
4408 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
4409 Use processor_names table.
4410 * config/i386/i386.c (ix86_default_align): Use
4411 processor_cost_table for alignment values.
4412 (ix86_option_override_internal): Use processor_names.
4413 (ix86_function_specific_print): Likewise.
4414 * config/i386/i386.h (struct processor_costs):
4415 Add alignment values.
4416 (struct ptt): Remove and replace with const char *.
4417 * config/i386/x86-tune-costs.h (struct processor_costs):
4418 Declare default alignments for all costs.
4419
4420 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
4421
4422 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
4423 symbolics or VR_VARYING ranges for ABS_EXPR.
4424 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
4425 when range will wrap.
4426
4427 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
4428
4429 PR middle-end/86864
4430 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
4431 before and after a JUMP_TABLE_DATA.
4432
4433 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
4434
4435 PR middle-end/87188
4436 * dojump.c (do_compare_and_jump): Canonicalize function pointers
4437 when one operand is a function pointer. Use POINTER_TYPE_P and
4438 FUNC_OR_METHOD_TYPE_P.
4439 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
4440 * fold-const.c (build_range_check): Likewise.
4441 * match.pd (simple_comparison): Likewise.
4442
4443 2018-09-14 David Malcolm <dmalcolm@redhat.com>
4444
4445 PR c/82967
4446 * spellcheck.c (get_edit_distance_cutoff): New function.
4447 (selftest::test_edit_distance_unit_test_oneway): Rename to...
4448 (selftest::test_get_edit_distance_one_way): ...this.
4449 (selftest::test_get_edit_distance_unit): Rename to...
4450 (selftest::test_get_edit_distance_both_ways): ...this.
4451 (selftest::test_edit_distances): Move tests to this new function,
4452 and test some more pairs of strings. Update for above renaming.
4453 (selftest::get_old_cutoff): New function.
4454 (selftest::test_get_edit_distance_cutoff): New function.
4455 (selftest::assert_suggested_for): New function.
4456 (ASSERT_SUGGESTED_FOR): New macro.
4457 (selftest::assert_not_suggested_for): New function.
4458 (ASSERT_NOT_SUGGESTED_FOR): New macro.
4459 (selftest::test_suggestions): New function.
4460 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
4461 tests to selftest::test_edit_distances and call it. Add calls to
4462 selftest::test_get_edit_distance_cutoff and
4463 selftest::test_suggestions.
4464 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
4465 (best_match::consider): Replace hard-coded cutoff calculation with
4466 a call to...
4467 (best_match::get_cutoff): New declaration.
4468 (best_match::get_best_meaningful_candidate): Likewise.
4469
4470 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4471
4472 * builtins.c (fold_builtin_strlen): Remove TODO comment.
4473
4474 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4475
4476 revert:
4477 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
4478
4479 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
4480 terminated string literal.
4481
4482 2018-09-14 Martin Sebor <msebor@redhat.com>
4483
4484 * builtins.c (unterminated_array): Handle ARRAY_REF.
4485 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
4486 * builtins.h (unterminated_array): Declare extern.
4487 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
4488 arrays.
4489 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
4490 calls.
4491
4492 2018-09-14 Martin Sebor <msebor@redhat.com>
4493 Jeff Law <law@redhat.com>
4494
4495 * builtins.c (unterminated_array): New.
4496 (expand_builtin_strcpy): Adjust.
4497 (expand_builtin_strcpy_args): Detect unterminated arrays.
4498 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
4499 unterminated arrays.
4500 * gimple-fold.h (get_maxval_strlen): Add argument.
4501 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
4502
4503 * gimple-fold.c (get_range_strlen): Add argument.
4504 (get_maxval_strlen): Adjust.
4505 * gimple-fold.h (get_range_strlen): Add argument.
4506
4507 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
4508
4509 * config/i386/movdirintrin.h: Fix copyright year.
4510
4511 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
4512
4513 * reg-stack.c: Include regs.h.
4514 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
4515 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
4516 FIRST_STACK_REG, not DFmode.
4517 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
4518 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
4519 (change stack): Default register mode to the reg_raw_mode of
4520 FIRST_STACK_REG, not DFmode.
4521 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
4522 (*swapxf): Rename from swapxf.
4523
4524 2018-09-14 Carl Love <cel@us.ibm.com>
4525
4526 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
4527 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
4528
4529 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
4530
4531 PR target/87224
4532 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
4533 alternatives.
4534
4535 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
4536
4537 PR target/85628
4538 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
4539
4540 2018-09-14 Jason Merrill <jason@redhat.com>
4541
4542 Fix --enable-gather-detailed-mem-stats.
4543 * hash-table.c (hash_table_usage): Change from variable to function.
4544 * hash-table.h: Adjust.
4545 * Makefile.in: Add missing dependencies on hash-table.h.
4546
4547 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4548
4549 PR tree-optimization/87259
4550 PR lto/87283
4551 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
4552 execute_cse_reciprocals_1 has tried transforming.
4553
4554 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
4555
4556 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
4557 VR_VARYING for PLUS/MINUS_EXPR.
4558
4559 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
4560
4561 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
4562 formatting.
4563
4564 2018-09-14 Richard Biener <rguenther@suse.de>
4565
4566 PR middle-end/63155
4567 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
4568 bits for the merged partition.
4569
4570 2018-09-13 Martin Sebor <msebor@redhat.com>
4571 Bernd Edlinger <bernd.edlinger@hotmail.de>
4572
4573 * builtins.h (c_srlen): Add argument.
4574 * builtins.c (warn_string_no_nul): New function.
4575 (c_strlen): Add argument and use it. Update recursive calls.
4576 Pass DECL argument to string_constant to get info on non
4577 terminated strings. Update *NONSTR as needed.
4578 (fold_builtin_strlen): Add argument to calls to c_strlen.
4579 Warn for unterminated arrays.
4580 (warn_string_no_null): Add prototype.
4581 * expr.c (string_constant): Update arguments. Update recursive
4582 calls appropriately. Detect missing NUL terminator and outermost
4583 declaration its missing in.
4584 Improve checks for arrays with nonzero lower bound or elements
4585 that are not a single byte. Simplify offset computation.
4586 Simplify checks for non-NUL terminated strings.
4587 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
4588 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
4589
4590 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
4591
4592 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
4593 correctly.
4594 * fold-const.c (c_getstr): Fix function comment. Remove unused third
4595 argument. Fix range checks.
4596 * fold-const.h (c_getstr): Adjust protoype.
4597 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
4598 string is constant but contains no NUL byte.
4599
4600 * expr.c (string_constant): Adjust function comment.
4601 Remove bogus check for zero termination.
4602
4603 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
4604
4605 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
4606 (get_constant_size): Don't make STRING_CSTs larger than they are.
4607 (check_string_literal): New check function for STRING_CSTs.
4608 (output_constant): Use it.
4609
4610 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
4611
4612 PR target/86812
4613 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
4614
4615 2018-09-13 Richard Biener <rguenther@suse.de>
4616
4617 PR tree-optimization/87263
4618 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
4619 (struct unwind_state): Add max_rpo field.
4620 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
4621 Compute max_rpo, the max RPO number a block can be backwards reached
4622 from. Re-write non-iterating mode to a RPO ordered worklist approach,
4623 separating it from the iterating mode.
4624
4625 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4626
4627 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
4628 (rfs_decision): New scheduling decision.
4629
4630 2018-09-13 Richard Biener <rguenther@suse.de>
4631
4632 PR bootstrap/87134
4633 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
4634 (vn_nary_op_insert_pieces_predicated): Do not write useless
4635 valid_dominated_by_p entry outside of the allocated storage.
4636
4637 2018-09-13 Omar Sandoval <osandov@osandov.com>
4638 Tom de Vries <tdevries@suse.de>
4639
4640 PR debug/86985
4641 * dwarf2out.c (is_c): New function.
4642 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
4643
4644 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
4645
4646 PR target/85628
4647 * config/aarch64/aarch64.md (*aarch64_bfxil):
4648 Define.
4649 * config/aarch64/constraints.md (Ulc): Define.
4650 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
4651 Define.
4652 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
4653 New function.
4654
4655 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4656
4657 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
4658 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
4659 aarch64_layout_frame call.
4660 (aarch64_expand_epilogue): Likewise.
4661 (aarch64_initial_elimination_offset): Likewise.
4662 (aarch64_get_separate_components): Likewise.
4663 (aarch64_use_return_insn_p): Likewise.
4664 (aarch64_layout_frame): Remove unneeded check.
4665
4666 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4667
4668 * configure.ac: Only append
4669 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
4670 gcc_config_arguments if it was never reconfigured or last reconfigure
4671 was with different arguments.
4672 * configure: Regenerated.
4673
4674 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4675 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4676
4677 PR middle-end/87290
4678 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
4679 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
4680
4681 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4682
4683 PR tree-optimization/87287
4684 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
4685 X % C == 0 to X % (unsigned) C == 0 optimization to ...
4686 * match.pd (X % C == 0): ... here. New optimization.
4687
4688 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4689
4690 PR middle-end/82853
4691 * expr.h (maybe_optimize_mod_cmp): Declare.
4692 * expr.c (mod_inv): New function.
4693 (maybe_optimize_mod_cmp): New function.
4694 (do_store_flag): Use it.
4695 * cfgexpand.c (expand_gimple_cond): Likewise.
4696
4697 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
4698 Julian Brown <julian@codesourcery.com>
4699
4700 PR middle-end/86336
4701 * gimplify.c (gimplify_scan_omp_clauses): Set
4702 target_firstprivatize_array_bases in OpenACC parallel and kernels
4703 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
4704 OpenACC data regions.
4705
4706 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
4707
4708 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
4709 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
4710
4711 2018-09-12 Richard Biener <rguenther@suse.de>
4712
4713 PR tree-optimization/87280
4714 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
4715 edge but unreachable target.
4716 (do_rpo_vn): For conservatively handling a PHI only mark
4717 the backedge executable but not the block reachable.
4718
4719 2018-09-12 Richard Biener <rguenther@suse.de>
4720
4721 PR tree-optimization/87266
4722 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
4723 visited blocks.
4724
4725 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
4726
4727 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
4728 constants.
4729 ("trunc<BFP:mode><DFP_ALL:mode>2")
4730 ("trunc<DFP_ALL:mode><BFP:mode>2")
4731 ("extend<BFP:mode><DFP_ALL:mode>2")
4732 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
4733 according to the target operand type.
4734
4735 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4736 Andreas Krebbel <krebbel@linux.ibm.com>
4737
4738 PR tree-optimization/86844
4739 * gimple-ssa-store-merging.c
4740 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
4741 there are any overlapping stores in between them, make sure they are
4742 also coalesced or we give up completely.
4743
4744 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4745
4746 PR middle-end/87248
4747 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
4748 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
4749
4750 2018-09-12 Tom de Vries <tdevries@suse.de>
4751
4752 * common.opt (gdescribe-dies): Add option.
4753 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
4754 attribute for artifical and nameless decls.
4755 (dwarf2out_register_external_die): Add description attribute to
4756 external reference die.
4757 (add_desc_attribute): New functions.
4758 (gen_subprogram_die): Add description attribute to
4759 DW_TAG_call_site_parameter.
4760 * tree-pretty-print.c (print_generic_expr_to_str): New function.
4761 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
4762 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
4763 -gno-describe-dies.
4764 (@item -gdescribe-dies): Add.
4765
4766 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4767
4768 * tree-vrp.c (vrp_shift_undefined_p): Remove.
4769 (extract_range_from_binary_expr_1: Call
4770 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
4771 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
4772 depend on sign.
4773
4774 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4775
4776 * gimple-ssa-warn-alloca.c
4777 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
4778 field for ALLOCA_BOUND_*_LARGE.
4779
4780 2018-09-11 Nathan Sidwell <nathan@acm.org>
4781
4782 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
4783
4784 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4785
4786 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
4787 for clobbers. Remove obsolete comment.
4788
4789 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4790
4791 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
4792 mpxchk, mpxld and mpxst types.
4793 (define_attr length_immediate): Remove all processing of mpx types.
4794 (define_attr prefix_0f): Ditto.
4795 (define_attr memory): Ditto.
4796
4797 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4798
4799 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
4800 (log<mode>2): Change operand 1 predicate to general_operand.
4801 Extend operand 1 to XFmode and generate logxf3 insn.
4802 (log10<mode>2): Change operand 1 predicate to general_operand.
4803 Extend operand 1 to XFmode and generate log10xf3 insn.
4804 (log2<mode>2): Change operand 1 predicate to general_operand.
4805 Extend operand 1 to XFmode and generate log2xf3 insn.
4806 (fyl2xp1_extend<mode>xf3_i387): Remove.
4807 (log1p<mode>2): Change operand 1 predicate to general_operand.
4808 Extend operand 1 to XFmode and generate log1pxf3 insn.
4809 (fxtract_extend<mode>xf3_i387): Remove.
4810 (logb<mode>2): Change operand 1 predicate to general_operand.
4811 Extend operand 1 to XFmode and generate logbxf3 insn.
4812 (ilogb<mode>2): Change operand 1 predicate to general_operand.
4813 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
4814 (significand<mode>2): Change operand 1 predicate to general_operand.
4815 Extend operand 1 to XFmode and generate significandxf3 insn.
4816
4817 2018-09-11 Nathan Sidwell <nathan@acm.org>
4818
4819 * gcc.c (perror_with_name, pfatal_with_name): Delete.
4820 (load_specs): Use fatal_error.
4821 (DELETE_IF_ORDINARY, process_command): Use error.
4822 (execute, run_attempt): Use fatal_error.
4823
4824 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
4825
4826 * diagnostic-core.h (sorry_at): New prototype.
4827 * diagnostic.c (sorry_at): New function.
4828
4829 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
4830
4831 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
4832 by zero as VR_UNDEFINED.
4833
4834 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4835
4836 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
4837 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
4838 (<sincos>mode2): New expander.
4839 (sincos_extend<mode>xf3_i387): Remove insn pattern.
4840 (sincos -> sin, cos splitters): Remove splitter patterns.
4841 (sincos<mode>3): Change operand 2 predicate to general_operand.
4842 Extend operand 2 to XFmode and generate sincosxf3 insn.
4843 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
4844 Change operand 3 predicate to const1_operand.
4845 (fptan_extend<mode>xf4_i387): Remove insn pattern.
4846 (tanxf2): Update operands in the call to fptanxf4_i387.
4847 (tan<mode>2): Change operand 1 predicate to general_operand.
4848 Extend operand 1 to XFmode and generate tanxf3 insn.
4849 (atan2xf3): Rename from *fpatanxf3_i387.
4850 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
4851 (atan2xf3): Remove expander.
4852 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
4853 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
4854 (atan<mode>2): Change operand 1 predicate to general_operand.
4855 Extend operand 1 to XFmode and generate atanxf3 insn.
4856
4857 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4858
4859 * config/i386/i386.md (x87/SSE constant load splitter): Use
4860 memory_operand instead of nonimmediate_operand for input operand
4861 predicate.
4862
4863 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
4864
4865 * config/i386/i386.md (float partial SSE register stall splitter): Move
4866 splitter near its instruction pattern.
4867 (float_extend partial SSE register stall splitter): Ditto.
4868 (float_truncate partial SSE register stall splitter): Ditto.
4869
4870 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
4871
4872 PR target/86794
4873 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
4874 to speculation_safe_value_not_needed.
4875
4876 PR target/85666
4877 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
4878 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
4879 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
4880 leaf_function_p, instead use has_hard_reg_initial_val.
4881
4882 2018-09-09 Nathan Sidwell <nathan@acm.org>
4883
4884 * gcc.h (pfatal_with_name): Don't declare here.
4885 * gcc.c (pfatal_with_name): Make static.
4886
4887 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
4888
4889 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
4890 earlyclobber.
4891
4892 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
4893
4894 PR rtl-optimization/85458
4895 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
4896 priority hook to reduce the priority of EXPR.
4897
4898 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
4899
4900 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
4901 DImode for x87 on 32bit targets. Conditionally disable x87 modes
4902 with X87_ENABLE_FLOAT. Remove preparation code.
4903 (*float<SWI48:mode><MODEF:mode>2): Rename from
4904 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
4905 math using "enabled" attribute.
4906 (*floatdi<MODEF:mode>2_i387): Rename from
4907 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
4908 enable for 32bit targets only.
4909 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
4910 splitter.
4911 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
4912 as operand 1 predicate. Rewrite as define_insn_and_split.
4913 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
4914
4915 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
4916
4917 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
4918 to fallthru to FLOAT case.
4919
4920 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
4921
4922 PR target/86731
4923 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
4924 around folding of vec_sl to handle out of range shift values.
4925
4926 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
4927
4928 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
4929 Update callers to gen_fix_trunc<mode>_i387_fisttp
4930 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
4931 nonimmediate_operand.
4932 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
4933 and corresponding splitters.
4934 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
4935 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
4936 (fix_truncdi_i387_with_temp): Remove insn pattern
4937 and corresponding splitters.
4938 (fix_trunc<mode>_i387): Change operand 0 predicate to
4939 nonimmediate_operand.
4940 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
4941 and corresponding splitters.
4942 (*fistdi2_1): Remove.
4943 (fistdi2): Ditto.
4944 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
4945 (lrintxfdi2): Remove expander. Reimplement as define_insn.
4946 (*fist<mode>2_1): Remove.
4947 (fist<mode>2): Ditto.
4948 (fist<mode>2_with_temp): Remove insn pattern and corresponding
4949 splitters.
4950 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
4951 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
4952 (fistdi2_<rounding>): Change operand 0 predicate to
4953 nonimmediate_operand.
4954 (fistdi2_<rounding>_with_temp): Remove insn pattern
4955 and corresponding splitters.
4956 (fist<mode>2_<rounding>): Change operand 0 predicate to
4957 nonimmediate_operand.
4958 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
4959 and corresponding splitters.
4960
4961 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
4962
4963 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
4964
4965 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
4966 the init value.
4967
4968 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
4969
4970 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
4971 early gimple folding of vec_splat().
4972 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
4973 * gimple-fold.h: Add an extern define for tree_vec_extract().
4974
4975 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
4976
4977 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
4978 wrappers around TREE_TYPE comparisons.
4979
4980 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
4981
4982 PR target/80080
4983 * config/s390/predicates.md: Add nonsym_memory_operand.
4984 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
4985 contains a SYMBOL_REF, load it into an intermediate pseudo.
4986 (s390_emit_compare_and_swap): Legitimize operand.
4987 * config/s390/s390.md: Use the new nonsym_memory_operand
4988 with UNSPECV_CAS patterns.
4989
4990 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
4991
4992 PR target/80080
4993 * config/s390/s390-passes.def: New file.
4994 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
4995 declaration.
4996 (make_pass_s390_early_mach): Add declaration.
4997 * config/s390/s390.c (make_pass_s390_early_mach):
4998 (s390_option_override): Remove dynamic registration.
4999 * config/s390/t-s390: Add s390-passes.def.
5000
5001 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5002
5003 * config/s390/s390.c (s390_decompose_constant_pool_ref):
5004 Remove UNSPEC_LTREL_BASE check.
5005 (annotate_constant_pool_refs): Likewise.
5006 (find_constant_pool_ref): Likewise.
5007 (find_ltrel_base): Removed.
5008 (replace_ltrel_base): Removed.
5009 (s390_mainpool_finish): Remove replace_ltrel_base call.
5010 (s390_chunkify_start): Remove pending LTREL_BASE logic.
5011 (s390_chunkify_finish): Remove replace_ltrel_base call.
5012 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
5013
5014 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
5015
5016 PR target/86779
5017 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
5018 to speculation_safe_value_not_needed.
5019
5020 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
5021 Bernd Schmidt <bernds_cb1@t-online.de>
5022
5023 * config/nvptx/nvptx-opts.h: New file.
5024 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
5025 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
5026 (ASM_SPEC): Define.
5027 (TARGET_SM35): New macro.
5028 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
5029 correct predicate.
5030 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
5031 values.
5032 (misa=): New option.
5033 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
5034
5035 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
5036
5037 * config/i386/i386.md (truncdfsf2): Remove expander.
5038 (truncdfsf2_with_temp): Ditto.
5039 (truncxf<mode>2): Ditto.
5040 (*truncdfsf_fast_mixed): Remove insn pattern.
5041 (*truncdfsf_fast_i387): Ditto.
5042 (*truncdfsf_mixed): Ditto.
5043 (*truncdfsf_i387): Ditto.
5044 (*truncdfsf2_i387_1): Ditto.
5045 (*truncxfsf2_mixed): Ditto.
5046 (*truncxfdf2_mixed): Ditto.
5047 (*truncxf<mode>2_i387_noop): Ditto. Update callers
5048 to call gen_truncxf<mode>2 instead.
5049 (*truncxf<mode>2_i387): Remove.
5050 (reg->reg splitters): Remove splitter pattern.
5051 (reg->mem splitters): Ditto.
5052
5053 (truncdfsf2): New insn pattern.
5054 (truncxf<mode>2): Ditto.
5055
5056 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5057
5058 * tree-ssa-math-opts.c (is_mult_by): New function.
5059 (is_square_of): Use the above.
5060 (optimize_recip_sqrt): New function.
5061 (pass_cse_reciprocals::execute): Use the above.
5062
5063 2018-09-05 Richard Biener <rguenther@suse.de>
5064
5065 PR bootstrap/87134
5066 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
5067 to zero-init the emplaced vec.
5068
5069 2018-09-05 Martin Liska <mliska@suse.cz>
5070
5071 PR tree-optimization/87205
5072 * tree-switch-conversion.c (pass_lower_switch::execute):
5073 Group cases for switch statements.
5074
5075 2018-09-05 Richard Biener <rguenther@suse.de>
5076
5077 PR tree-optimization/87217
5078 * tree-ssa-sccvn.c (vuse_valueize): New.
5079 (vn_reference_lookup_pieces): Use it.
5080 (vn_reference_lookup): Likewise.
5081
5082 2018-09-05 Nathan Sidwell <nathan@acm.org>
5083
5084 PR c++/87137
5085 * stor-layout.c (place_field): Scan forwards to check last
5086 bitfield when ms_bitfield_placement is in effect.
5087
5088 2018-09-05 Richard Biener <rguenther@suse.de>
5089
5090 PR bootstrap/87225
5091 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
5092 return.
5093
5094 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
5095 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
5096
5097 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
5098 * config.gcc (extra_objs): Build it.
5099 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
5100 Likewise.
5101 * config/aarch64/aarch64-passes.def
5102 (pass_tag_collision_avoidance): New pass.
5103 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
5104 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
5105 (aarch64_classify_address): Remove static qualifier.
5106 (aarch64_address_info, aarch64_address_type): Move to...
5107 * config/aarch64/aarch64-protos.h: ... here.
5108 (make_pass_tag_collision_avoidance): New function.
5109 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
5110 New tuning flag.
5111
5112 2018-09-05 Martin Liska <mliska@suse.cz>
5113
5114 * doc/gcov.texi: Update documentation of humar
5115 readable mode.
5116 * gcov.c (format_count): Print one decimal place, it provides
5117 more fine number of situations like '1G' vs. '1.4G'.
5118
5119 2018-09-05 Martin Liska <mliska@suse.cz>
5120
5121 PR target/87164
5122 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
5123 * optc-gen.awk: Allow 'Var' for Deprecated options in order
5124 to generate a MASK value.
5125
5126 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
5127
5128 PR debug/86593
5129 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
5130 if frame pointer isn't used.
5131 (compute_frame_pointer_to_fb_displacement): Likewise.
5132
5133 2018-09-04 Jakub Jelinek <jakub@redhat.com>
5134
5135 PR target/87198
5136 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
5137 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
5138 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
5139 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
5140 and OPTION_MASK_ISA_XSAVEC_UNSET.
5141
5142 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
5143
5144 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
5145 XOR operations in NAND case.
5146
5147 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5148
5149 * wide-int-range.cc (wide_int_range_convert): New.
5150 * wide-int-range.h (wide_int_range_convert): New.
5151 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
5152 code into wide_int_range_convert.
5153 (extract_range_into_wide_ints): Do not munge anti range constants
5154 into the entire domain. Just return the range back.
5155
5156 2018-09-04 Martin Liska <mliska@suse.cz>
5157
5158 * genmatch.c (output_line_directive): Add new argument
5159 fnargs.
5160 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
5161
5162 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5163
5164 * doc/invoke.texi (Option Summary): Add whitespace.
5165
5166 * doc/invoke.texi (Option Summary): Add -Waligned-new.
5167
5168 2018-09-04 Richard Biener <rguenther@suse.de>
5169
5170 PR tree-optimization/87211
5171 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
5172 backedge value we're supposed to treat as VARYING also number
5173 the PHI to VARYING in case it got a different value-number already.
5174
5175 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5176
5177 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
5178 (extract_range_from_binary_expr_1): Do not call
5179 vrp_can_optimize_bit_op.
5180 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
5181 static.
5182 (wide_int_range_get_mask_and_bounds): New.
5183 (wide_int_range_optimize_bit_op): New.
5184 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
5185 (wide_int_range_bit_and): Same.
5186 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
5187 (wide_int_range_optimize_bit_op): New.
5188 (wide_int_range_get_mask_and_bounds): New.
5189
5190 2018-09-04 Richard Biener <rguenther@suse.de>
5191
5192 PR tree-optimization/87176
5193 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
5194 variable. When value-numbering a virtual PHI node make sure
5195 to not value-number to the backedge value.
5196
5197 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5198
5199 * doc/extend.texi (Long Long, Hex Floats): Document support for
5200 long long and hex floats in more recent versions of ISO C++.
5201
5202 2018-09-03 Richard Biener <rguenther@suse.de>
5203
5204 PR tree-optimization/87177
5205 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
5206 cleanup.
5207
5208 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5209
5210 * bb-reorder.c (edge_order): Convert to C-qsort-style
5211 tri-state comparator.
5212 (reorder_basic_blocks_simple): Change std::stable_sort to
5213 gcc_stablesort.
5214
5215 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5216
5217 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
5218 tri-state comparator.
5219 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
5220
5221 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5222
5223 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
5224 (mergesort): ... here as maximum count for using netsort.
5225 (gcc_qsort): Set nlim to 3 if stable sort is requested.
5226 (gcc_stablesort): New.
5227 * system.h (gcc_stablesort): Declare.
5228
5229 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5230
5231 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
5232 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
5233 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
5234
5235 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
5236
5237 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
5238 lxsdx and stxsdx alternatives.
5239 (*mov<mode>_hardfloat64): Ditto.
5240 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
5241
5242 2018-09-03 Richard Biener <rguenther@suse.de>
5243
5244 PR tree-optimization/87200
5245 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
5246 simplify result.
5247
5248 2018-09-03 Martin Liska <mliska@suse.cz>
5249
5250 PR tree-optimization/87201
5251 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5252 Fix parenthesis in an expression.
5253
5254 2018-09-03 Richard Biener <rguenther@suse.de>
5255
5256 PR tree-optimization/87197
5257 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
5258 visited. CSE the VN_INFO hashtable lookup.
5259
5260 PR tree-optimization/87169
5261 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
5262 iterating make sure there's no extra backedges from irreducible
5263 regions feeding the header. Mark the destination block
5264 executable.
5265
5266 2018-09-03 Martin Liska <mliska@suse.cz>
5267
5268 PR driver/83193
5269 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
5270 * common/common-targhooks.c (default_get_valid_option_values):
5271 New function.
5272 * common/common-targhooks.h (default_get_valid_option_values):
5273 Likewise.
5274 * common/config/i386/i386-common.c: Move processor_target_table
5275 from i386.c.
5276 (ix86_get_valid_option_values): New function.
5277 (TARGET_GET_VALID_OPTION_VALUES): New macro.
5278 * config/i386/i386.c (struct ptt): Move to i386-common.c.
5279 (PTA_*): Move all defined masks into i386-common.c.
5280 (ix86_function_specific_restore): Use new processor_cost_table.
5281 * config/i386/i386.h (struct ptt): Moved from i386.c.
5282 (struct pta): Likewise.
5283 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
5284 * doc/tm.texi.in: Likewise.
5285 * opt-suggestions.c (option_proposer::suggest_option):
5286 Pass prefix to build_option_suggestions.
5287 (option_proposer::get_completions): Likewise.
5288 (option_proposer::build_option_suggestions): Use the new target
5289 hook.
5290 * opts.c (struct option_help_tuple): New struct.
5291 (print_filtered_help): Use the new target hook.
5292
5293 2018-09-03 Martin Liska <mliska@suse.cz>
5294
5295 PR middle-end/59521
5296 * predict.c (set_even_probabilities): Add likely_edges
5297 argument and handle cases where we have precisely one
5298 likely edge.
5299 (combine_predictions_for_bb): Catch also likely_edges.
5300 (tree_predict_by_opcode): Handle gswitch statements.
5301 * tree-cfg.h (find_case_label_for_value): New declaration.
5302 (find_taken_edge_switch_expr): Likewise.
5303 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5304 Find pivot in decision tree based on probabily, not by number of
5305 nodes.
5306
5307 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
5308
5309 * doc/standards.texi (Standards): Update Objective-C reference.
5310
5311 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5312
5313 * doc/install.texi (Prerequisites): Update link for MPC.
5314
5315 2018-09-01 Michael Matz <matz@suse.de>
5316
5317 PR tree-optimization/87074
5318 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
5319 PHIs for outer-loop uses.
5320
5321 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5322
5323 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
5324 * doc/invoke.texi (C Dialect Options): Ditto.
5325
5326 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5327
5328 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
5329
5330 2018-08-31 Richard Biener <rguenther@suse.de>
5331
5332 PR tree-optimization/87168
5333 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
5334 (rpo_elim::eliminate_avail): When OP was not visited it must
5335 be available.
5336
5337 2018-08-31 David Malcolm <dmalcolm@redhat.com>
5338
5339 * tree-vrp.c (copy_value_range): Convert param "from" from
5340 "value_range *" to "const value_range *".
5341 (range_is_null): Likewise for param "vr".
5342 (range_int_cst_p): Likewise.
5343 (range_int_cst_singleton_p): Likewise.
5344 (symbolic_range_p): Likewise.
5345 (value_ranges_intersect_p): Likewise for both params.
5346 (value_range_nonnegative_p): Likewise for param "vr".
5347 (value_range_constant_singleton): Likewise.
5348 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
5349 (extract_range_into_wide_ints): Likewise for param "vr".
5350 (extract_range_from_multiplicative_op): Likewise for params "vr0"
5351 and "vr1".
5352 (vrp_can_optimize_bit_op): Likewise.
5353 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
5354 "vr1_".
5355 (extract_range_from_unary_expr): Likewise.
5356 (debug_value_range): Likewise for param "vr".
5357 (value_range::dump): Add "const" qualifier.
5358 (vrp_prop::check_array_ref): Convert local "vr" from
5359 "value_range *" to "const value_range *".
5360 (vrp_prop::check_mem_ref): Likewise.
5361 (vrp_prop::visit_stmt): Likewise for local "old_vr".
5362 (vrp_intersect_ranges_1): Likewise for param "vr_1".
5363 (vrp_intersect_ranges): Likewise.
5364 (simplify_stmt_for_jump_threading): Likewise for local "vr".
5365 (vrp_prop::vrp_finalize): Likewise.
5366 * tree-vrp.h (value_range::dump): Add "const" qualifier.
5367 (vrp_intersect_ranges): Add "const" qualifier to params as above.
5368 (extract_range_from_unary_expr): Likewise.
5369 (value_range_constant_singleton): Likewise.
5370 (symbolic_range_p): Likewise.
5371 (copy_value_range): Likewise.
5372 (extract_range_from_binary_expr_1): Likewise.
5373 (range_int_cst_p): Likewise.
5374 (vrp_set_zero_nonzero_bits): Likewise.
5375 (range_int_cst_singleton_p): Likewise.
5376
5377 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
5378
5379 * config/aarch64/arm_neon.h (vabsd_s64): New.
5380 (vnegd_s64): Likewise.
5381
5382 2018-08-31 Martin Jambor <mjambor@suse.cz>
5383
5384 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
5385
5386 2018-08-31 Martin Liska <mliska@suse.cz>
5387
5388 * ipa-icf.c (sem_item::add_type): Use
5389 sem_item::m_type_hash_cache.
5390 * ipa-icf.h: Move the cache from sem_item_optimizer
5391 to sem_item.
5392
5393 2018-08-31 Nathan Sidwell <nathan@acm.org>
5394
5395 * doc/extend.texi (Backwards Compatibility): Remove implicit
5396 extern C leeway of () being (...).
5397
5398 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5399
5400 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
5401
5402 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
5403
5404 PR target/86684
5405 PR target/87149
5406 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
5407
5408 2018-08-31 Jakub Jelinek <jakub@redhat.com>
5409
5410 PR middle-end/87138
5411 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
5412 gen_int_mode. Formatting fixes.
5413
5414 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
5415
5416 * target.def (custom_function_descriptors): Improve documentation.
5417 * doc/tm.texi.in (Trampolines): Expand discussion of function
5418 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
5419 beginning of the section.
5420 * doc/tm.texi: Regenerated.
5421
5422 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
5423
5424 * cfg.h (class auto_edge_flag): Spell out the template-id of the
5425 base class in the initializer list. This is a workaround for
5426 building with older GCC.
5427 (class auto_bb_flag): Likewise.
5428
5429 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
5430
5431 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
5432 (altivec_vcmpequ<VI_char>_p): Remove star.
5433 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
5434 vector load modes.
5435 (expand_strncmp_vec_sequence): New function.
5436 (emit_final_str_compare_vec): New function.
5437 (expand_strn_compare): Add support for vector strncmp.
5438 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
5439 length specification to bytes.
5440 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
5441 (vcmpnezb_p): New pattern.
5442 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
5443 for option -mstring-compare-inline-limit.
5444
5445 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
5446
5447 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
5448 (PTA_SKYLAKE): Add PTA_AES.
5449 (PTA_GOLDMONT): Likewise.
5450
5451 2018-08-29 Jan Hubicka <jh@suse.cz>
5452
5453 PR lto/86517
5454 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
5455 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
5456
5457 2018-08-29 Jan Hubicka <jh@suse.cz>
5458
5459 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
5460 TYPE_STUB_DECL.
5461 (hash_tree): Do not visit TYPE_STUB_DECL.
5462 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
5463 stream TYPE_STUB_DECL.
5464 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
5465 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
5466 after free_lang_data.
5467 (type_in_anonymous_namespace_p): Likewise.
5468
5469 2018-08-29 Jan Hubicka <jh@suse.cz>
5470
5471 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5472 comment that it has to be even number.
5473 (class sreal): Change m_sig type to int32_t.
5474 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5475 int64_t for temporary calculations.
5476 (sreal_verify_basics): Drop one bit from minimum and maximum.
5477
5478 2018-08-30 Richard Biener <rguenther@suse.de>
5479
5480 PR tree-optimization/87147
5481 * tree-ssa-sccvn.c (SSA_VISITED): New function.
5482 (visit_phi): When the degenerate result is from the backedge and
5483 we didn't visit its definition yet drop to VARYING.
5484 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
5485
5486 2018-08-29 Jan Hubicka <jh@suse.cz>
5487
5488 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
5489 DECL_VINDEX.
5490 (hash_tree): Likewise.
5491
5492 2018-08-29 Jan Hubicka <jh@suse.cz>
5493
5494 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
5495 and TYPE_NEXT_REF_TO.
5496
5497 2018-08-29 Jan Hubicka <jh@suse.cz>
5498
5499 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5500 comment that it has to be even number.
5501 (class sreal): Change m_sig type to int32_t.
5502 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5503 int64_t for temporary calculations.
5504 (sreal_verify_basics): Drop one bit from minimum and maximum.
5505
5506 2018-08-30 Tamar Christina <tamar.christina@arm.com>
5507
5508 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
5509
5510 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
5511
5512 PR middle-end/86995
5513 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
5514 if to_add is negative.
5515
5516 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
5517
5518 PR middle-end/87053
5519 * builtins.c (c_strlen): Improve range checks.
5520
5521 2018-08-29 Martin Sebor <msebor@redhat.com>
5522 Jeff Law <law@redhat.com>
5523
5524 PR tree-optimization/86714
5525 PR tree-optimization/86711
5526 * builtins.c (c_strlen): Add arguments to call to string_constant.
5527 * expr.c (string_constant): Add argument. Detect missing nul
5528 terminator and outermost declaration it's missing in.
5529 * expr.h (string_constant): Add argument.
5530 * fold-const.c (read_from_constant_string): Add arguments to call to
5531 string_constant.
5532 (c_getstr): Likewise.
5533 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5534 to string_constant.
5535 * tree-ssa-strlen.c (get_stridx): Likewise.
5536
5537 2018-08-29 Jan Hubicka <jh@suse.cz>
5538
5539 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
5540 Do not stream DECL_VINDEX.
5541 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
5542 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
5543 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
5544
5545 2018-08-29 Richard Biener <rguenther@suse.de>
5546
5547 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
5548 virtual operands that are not default defs to honor region
5549 boundaries.
5550 (rpo_vn_valueize): Remove ineffective code here.
5551
5552 2018-08-29 Richard Biener <rguenther@suse.de>
5553
5554 PR tree-optimization/87132
5555 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
5556 when skipping defs reachable over backedges.
5557
5558 2018-08-29 Richard Biener <rguenther@suse.de>
5559
5560 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
5561 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
5562 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
5563 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
5564 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
5565 (vn_reference_lookup_3): Remove use of const_parms.
5566 (free_rpo_vn): Do not free const_parms.
5567 (do_rpo_vn): Do not call init_const_parms.
5568 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
5569 SSA_NAME_POINTS_TO_READONLY_MEMORY.
5570 (call_may_clobber_ref_p_1): Likewise.
5571
5572 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
5573
5574 PR other/86726
5575 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
5576 (-O): Ditto.
5577 (-ftree-scev-cprop): Document.
5578
5579 2018-08-29 Jan Hubicka <jh@suse.cz>
5580
5581 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
5582 parameters.
5583 (sreal constructor): Update.
5584 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
5585 sreal:operator/): Update.
5586
5587 2018-08-29 Martin Liska <mliska@suse.cz>
5588
5589 * tree-switch-conversion.c (switch_conversion::expand):
5590 Strenghten assumption about gswitch statements.
5591
5592 2018-08-29 Richard Biener <rguenther@suse.de>
5593
5594 PR tree-optimization/87117
5595 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
5596 re-value-number released SSA VDEFs.
5597
5598 2018-08-29 Richard Biener <rguenther@suse.de>
5599
5600 PR tree-optimization/87126
5601 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
5602
5603 2018-08-28 Jim Wilson <jimw@sifive.com>
5604
5605 * config/riscv/pic.md: Rewrite.
5606 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
5607 invalid address.
5608 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
5609 (SOFTF, default_load, softload, softstore): New.
5610
5611 2018-08-28 Jeff Law <law@redhat.com>
5612
5613 * fold-const.c (fold_binary_loc): Remove recently added assert.
5614
5615 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
5616
5617 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
5618 to OP parmeter of generated function.
5619
5620 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
5621
5622 PR tree-optimization/87009
5623 * match.pd: Add boolean optimizations.
5624
5625 2018-08-28 Martin Sebor <msebor@redhat.com>
5626
5627 PR middle-end/86631
5628 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
5629 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
5630 (pass_walloca::gate): Use it.
5631 (alloca_call_type): Same.
5632 (pass_walloca::execute): Same.
5633 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
5634
5635 2018-08-28 David Malcolm <dmalcolm@redhat.com>
5636
5637 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
5638 GCC_VERSION for usage of "__gcc_dump_printf__" format from
5639 >= 3005 to >= 9000.
5640
5641 2018-08-28 Richard Biener <rguenther@suse.de>
5642
5643 PR tree-optimization/87124
5644 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
5645 constants before looking up avail.
5646
5647 2018-08-28 Jakub Jelinek <jakub@redhat.com>
5648
5649 PR middle-end/87099
5650 * calls.c (maybe_warn_nonstring_arg): Punt early if
5651 warn_stringop_overflow is zero. Don't call get_range_strlen
5652 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
5653 Swap comparison operands to have constants on rhs. Only use
5654 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
5655 increment lenrng[0].
5656
5657 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
5658
5659 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
5660 use of tree_to_shwi. Remove duplicated test for the size being
5661 a whole number of bytes.
5662
5663 2018-08-28 Richard Biener <rguenther@suse.de>
5664
5665 PR tree-optimization/87117
5666 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
5667 Handle removed stmt without LHS (GIMPLE_NOP).
5668
5669 2018-08-28 Richard Biener <rguenther@suse.de>
5670
5671 PR tree-optimization/87117
5672 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
5673 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
5674
5675 2018-08-28 Richard Biener <rguenther@suse.de>
5676
5677 PR tree-optimization/87117
5678 * tree-ssa-pre.c (compute_avail): Do not make expressions
5679 with predicated values available.
5680 (get_expr_value_id): Assert we do not run into predicated value
5681 expressions.
5682
5683 2018-08-28 Richard Biener <rguenther@suse.de>
5684
5685 PR tree-optimization/87117
5686 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
5687 get virtual operands.
5688 (get_expr_operands): Handle STRING_CST like other decls.
5689
5690 2018-08-28 Martin Liska <mliska@suse.cz>
5691
5692 * tree.h: Update documentation of fndecl_built_in_p
5693 functions.
5694
5695
5696 2018-08-27 Jeff Law <law@redhat.com>
5697 PR tree-optimization/87110
5698 * tree-ssa-dse.c (compute_trims): Handle non-constant
5699 TYPE_SIZE_UNIT.
5700
5701 2018-08-27 Martin Sebor <msebor@redhat.com>
5702
5703 PR tree-optimization/86914
5704 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
5705
5706 2018-08-27 Martin Sebor <msebor@redhat.com>
5707
5708 PR tree-optimization/87112
5709 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
5710 the type of the bound argument.
5711
5712 2018-08-27 Jeff Law <law@redhat.com>
5713
5714 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
5715 type does not have a TYPE_SIZE_UNIT.
5716
5717 2018-08-27 Steve Ellcey <sellcey@cavium.com>
5718
5719 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
5720 with include of backend.h.
5721
5722 2018-08-27 Richard Biener <rguenther@suse.de>
5723
5724 PR tree-optimization/86927
5725 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
5726 use const cond reduction code.
5727
5728 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
5729
5730 PR tree-optimization/85758
5731 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
5732
5733 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5734
5735 PR c++/87091
5736 * diagnostic-show-locus.c (class layout_range): Update for
5737 conversion of show_caret_p to a tri-state.
5738 (layout_range::layout_range): Likewise.
5739 (make_range): Likewise.
5740 (layout::maybe_add_location_range): Likewise.
5741 (layout::should_print_annotation_line_p): Don't show annotation
5742 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
5743 (layout::get_state_at_point): Update for conversion of
5744 show_caret_p to a tri-state. Bail out early for
5745 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
5746 underlining or source colorization.
5747 (gcc_rich_location::add_location_if_nearby): Update for conversion
5748 of show_caret_p to a tri-state.
5749 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
5750 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
5751 Likewise.
5752 (selftest::test_one_liner_labels): Likewise.
5753 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
5754 conversion of show_caret_p to a tri-state.
5755 * pretty-print.c (text_info::set_location): Likewise.
5756 * pretty-print.h (text_info::set_location): Likewise.
5757 * substring-locations.c (format_warning_n_va): Likewise.
5758 * tree-diagnostic.c (default_tree_printer): Likewise.
5759 * tree-pretty-print.c (newline_and_indent): Likewise.
5760
5761 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5762
5763 PR c++/87091
5764 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
5765 line above for line-insertion fix-it hints.
5766 (selftest::test_fixit_insert_containing_newline): Update the
5767 expected results, and add a test with line-numbering enabled.
5768
5769 2018-08-27 Martin Liska <mliska@suse.cz>
5770
5771 PR sanitizer/86962
5772 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
5773 params with DECL_HAS_VALUE_EXPR_P.
5774
5775 2018-08-27 Martin Liska <mliska@suse.cz>
5776
5777 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
5778 selected expansion strategy.
5779
5780 2018-08-27 Martin Liska <mliska@suse.cz>
5781
5782 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
5783 * builtins.c (is_builtin_fn): Likewise.
5784 * attribs.c (diag_attr_exclusions): Use new function
5785 fndecl_built_in_p and remove check for FUNCTION_DECL if
5786 possible.
5787 (builtin_mathfn_code): Likewise.
5788 (fold_builtin_expect): Likewise.
5789 (fold_call_expr): Likewise.
5790 (fold_builtin_call_array): Likewise.
5791 (fold_call_stmt): Likewise.
5792 (set_builtin_user_assembler_name): Likewise.
5793 (is_simple_builtin): Likewise.
5794 * calls.c (gimple_alloca_call_p): Likewise.
5795 (maybe_warn_nonstring_arg): Likewise.
5796 * cfgexpand.c (expand_call_stmt): Likewise.
5797 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
5798 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
5799 (cgraph_node::verify_node): Likewise.
5800 * cgraphclones.c (build_function_decl_skip_args): Likewise.
5801 (cgraph_node::create_clone): Likewise.
5802 * config/arm/arm.c (arm_insert_attributes): Likewise.
5803 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
5804 * dse.c (scan_insn): Likewise.
5805 * expr.c (expand_expr_real_1): Likewise.
5806 * fold-const.c (operand_equal_p): Likewise.
5807 (fold_binary_loc): Likewise.
5808 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
5809 * gimple-low.c (lower_stmt): Likewise.
5810 * gimple-pretty-print.c (dump_gimple_call): Likewise.
5811 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
5812 Likewise.
5813 * gimple.c (gimple_build_call_from_tree): Likewise.
5814 (gimple_call_builtin_p): Likewise.
5815 (gimple_call_combined_fn): Likewise.
5816 * gimplify.c (gimplify_call_expr): Likewise.
5817 (gimple_boolify): Likewise.
5818 (gimplify_modify_expr): Likewise.
5819 (gimplify_addr_expr): Likewise.
5820 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
5821 * ipa-cp.c (determine_versionability): Likewise.
5822 * ipa-fnsummary.c (compute_fn_summary): Likewise.
5823 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
5824 * ipa-split.c (visit_bb): Likewise.
5825 (split_function): Likewise.
5826 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
5827 * lto-cgraph.c (input_node): Likewise.
5828 * lto-streamer-out.c (write_symbol): Likewise.
5829 * omp-low.c (setjmp_or_longjmp_p): Likewise.
5830 (lower_omp_1): Likewise.
5831 * predict.c (strip_predict_hints): Likewise.
5832 * print-tree.c (print_node): Likewise.
5833 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
5834 * trans-mem.c (is_tm_irrevocable): Likewise.
5835 (is_tm_load): Likewise.
5836 (is_tm_simple_load): Likewise.
5837 (is_tm_store): Likewise.
5838 (is_tm_simple_store): Likewise.
5839 (is_tm_abort): Likewise.
5840 (tm_region_init_1): Likewise.
5841 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
5842 * tree-cfg.c (verify_gimple_call): Likewise.
5843 (move_stmt_r): Likewise.
5844 (stmt_can_terminate_bb_p): Likewise.
5845 * tree-eh.c (lower_eh_constructs_2): Likewise.
5846 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
5847 * tree-inline.c (remap_gimple_stmt): Likewise.
5848 (copy_bb): Likewise.
5849 (estimate_num_insns): Likewise.
5850 (fold_marked_statements): Likewise.
5851 * tree-sra.c (scan_function): Likewise.
5852 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
5853 (optimize_stack_restore): Likewise.
5854 (pass_fold_builtins::execute): Likewise.
5855 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
5856 (mark_all_reaching_defs_necessary_1): Likewise.
5857 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
5858 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5859 (pass_forwprop::execute): Likewise.
5860 * tree-ssa-loop-im.c (stmt_cost): Likewise.
5861 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
5862 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
5863 * tree-ssa-strlen.c (get_string_length): Likewise.
5864 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
5865 (find_func_aliases_for_call): Likewise.
5866 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
5867 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
5868 * tree-tailcall.c (find_tail_calls): Likewise.
5869 * tree.c (need_assembler_name_p): Likewise.
5870 (free_lang_data_in_decl): Likewise.
5871 (get_call_combined_fn): Likewise.
5872 * ubsan.c (is_ubsan_builtin_p): Likewise.
5873 * varasm.c (incorporeal_function_p): Likewise.
5874 * tree.h (DECL_BUILT_IN): Remove and replace with
5875 fndecl_built_in_p.
5876 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
5877 (fndecl_built_in_p): New.
5878
5879 2018-08-27 Martin Liska <mliska@suse.cz>
5880
5881 PR tree-optimization/86847
5882 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
5883 Dump also subtree probability.
5884 (switch_decision_tree::do_jump_if_equal): New function.
5885 (switch_decision_tree::emit_case_nodes): Handle special
5886 situations in balanced tree that can be emitted much simpler.
5887 Fix calculation of probabilities that happen in tree expansion.
5888 * tree-switch-conversion.h (struct cluster): Add
5889 is_single_value_p.
5890 (struct simple_cluster): Likewise.
5891 (struct case_tree_node): Add new function has_child.
5892 (do_jump_if_equal): New.
5893
5894 2018-08-27 Martin Liska <mliska@suse.cz>
5895
5896 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
5897 Add new argument to bit_test_cluster constructor.
5898 (bit_test_cluster::emit): Set bits really number of values
5899 handlel by a test.
5900 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
5901 probability argument.
5902 * tree-switch-conversion.h (struct bit_test_cluster):
5903 Add m_handles_entire_switch.
5904
5905 2018-08-27 Martin Liska <mliska@suse.cz>
5906
5907 PR tree-optimization/86702
5908 * tree-switch-conversion.c (jump_table_cluster::emit):
5909 Make probabilities even for values in jump table
5910 according to number of cases handled.
5911 (switch_decision_tree::compute_cases_per_edge): Pass
5912 argument to reset_out_edges_aux function.
5913 (switch_decision_tree::analyze_switch_statement): Likewise.
5914 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
5915 Make it static.
5916
5917 2018-08-27 Martin Liska <mliska@suse.cz>
5918
5919 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
5920 cfun argument explicitly.
5921 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
5922 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
5923 function gimple_switch_default_bb.
5924 (convert_switch_statements):
5925 (expand_builtins):
5926 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
5927 * stmt.c (label_to_block_fn): Use label_to_block and pass
5928 cfun argument explicitly and use gimple_switch_label_bb.
5929 (expand_case): Likewise.
5930 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
5931 cfun argument explicitly. Likewise.
5932 (make_edges_bb): Likewise.
5933 (make_cond_expr_edges): Likewise.
5934 (get_cases_for_edge): Likewise.
5935 (make_gimple_switch_edges): Likewise.
5936 (label_to_block_fn): Likewise.
5937 (label_to_block): Likewise.
5938 (make_goto_expr_edges): Likewise.
5939 (make_gimple_asm_edges): Likewise.
5940 (main_block_label): Likewise.
5941 (group_case_labels_stmt): Likewise.
5942 (find_taken_edge_computed_goto): Likewise.
5943 (find_taken_edge_switch_expr): Likewise.
5944 (gimple_verify_flow_info): Likewise.
5945 (gimple_redirect_edge_and_branch): Likewise.
5946 (gimple_switch_label_bb): New function.
5947 (gimple_switch_default_bb): Likewise.
5948 (gimple_switch_edge): Likewise.
5949 (gimple_switch_default_edge): Likewise.
5950 * tree-cfg.h (label_to_block_fn): Remove and replace ...
5951 (label_to_block): ... with this.
5952 (gimple_switch_label_bb): New.
5953 (gimple_switch_default_bb): Likewise.
5954 (gimple_switch_edge): Likewise.
5955 (gimple_switch_default_edge): Likewise.
5956 * tree-cfgcleanup.c (convert_single_case_switch): Use
5957 new gimple functions and pass new argument to label_to_block.
5958 (cleanup_control_flow_bb):
5959 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
5960 cfun argument explicitly.
5961 (make_eh_edges): Likewise.
5962 (redirect_eh_dispatch_edge): Likewise.
5963 (lower_resx): Likewise.
5964 (lower_eh_dispatch): Likewise.
5965 (maybe_remove_unreachable_handlers): Likewise.
5966 (unsplit_eh): Likewise.
5967 (cleanup_empty_eh): Likewise.
5968 (verify_eh_edges): Likewise.
5969 (verify_eh_dispatch_edge): Likewise.
5970 * tree-ssa-dom.c (record_edge_info): Likewise.
5971 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
5972 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
5973 (thread_through_normal_block): Likewise.
5974 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
5975 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
5976 * tree-switch-conversion.c (switch_conversion::collect): Use new
5977 gimple functions.
5978 (switch_conversion::check_final_bb): Likewise.
5979 (switch_conversion::gather_default_values): Pass new argument
5980 to label_to_block.
5981 (switch_conversion::build_constructors): Likewise.
5982 (switch_decision_tree::compute_cases_per_edge): Use new
5983 gimple_switch_edge function.
5984 (switch_decision_tree::analyze_switch_statement): Pass new argument
5985 to label_to_block.
5986 (switch_decision_tree::try_switch_expansion): Use
5987 gimple_switch_default_edge.
5988 * tree-vrp.c (find_switch_asserts): Pass new argument
5989 to label_to_block.
5990 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
5991 (vr_values::simplify_switch_using_ranges): Likewise.
5992
5993 2018-08-27 Richard Biener <rguenther@suse.de>
5994
5995 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
5996 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
5997
5998 * tree-ssa-sccvn.h (struct vn_pval): New structure.
5999 (struct vn_nary_op_s): Add unwind_to member. Add
6000 predicated_values flag and put result into a union together
6001 with a linked list of vn_pval.
6002 (struct vn_ssa_aux): Add name member to make maintaining
6003 a map of SSA name to vn_ssa_aux possible. Remove no longer
6004 needed info, dfsnum, low, visited, on_sccstack, use_processed
6005 and range_info_anti_range_p members.
6006 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
6007 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
6008 New functions.
6009 (vn_valueize): New global.
6010 (vn_context_bb): Likewise.
6011 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
6012 VN_INFO_PTR_INFO): Remove.
6013 * tree-ssa-sccvn.c: ... (rewrite)
6014 (pass_fre::execute): For -O2+ initialize loops and run
6015 RPO VN in optimistic mode (iterating). For -O1 and -Og
6016 run RPO VN in non-optimistic mode.
6017 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
6018 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
6019 * doc/invoke.texi (sccvn-max-scc-size): Remove.
6020 (rpo-vn-max-loop-depth): Document.
6021 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
6022 when valuezing the VUSE signals we walked out of the region.
6023 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
6024 (phi_translate): Set VN context block to use for availability
6025 lookup.
6026 (compute_avail): Likewise.
6027 (pre_valueize): New function.
6028 (pass_pre::execute): Adjust to the RPO VN API.
6029
6030 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
6031 (propagate_constants_for_unrolling): Remove.
6032 (tree_unroll_loops_completely): Perform value-numbering
6033 on the unrolled bodies loop parent.
6034
6035 2018-08-27 Richard Biener <rguenther@suse.de>
6036
6037 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
6038 for partial antic compute.
6039
6040 2018-08-27 Jakub Jelinek <jakub@redhat.com>
6041
6042 PR rtl-optimization/87065
6043 * combine.c (simplify_if_then_else): Formatting fix.
6044 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
6045 check.
6046 (known_cond): Don't return const_true_rtx for vector modes. Use
6047 CONST0_RTX instead of const0_rtx. Formatting fixes.
6048
6049 2018-08-27 Martin Liska <mliska@suse.cz>
6050
6051 PR gcov-profile/87069
6052 * gcov.c (process_file): Record files already processed
6053 and warn about a file being processed multiple times.
6054
6055 2018-08-27 Martin Liska <mliska@suse.cz>
6056
6057 PR driver/83193
6058 * config/aarch64/aarch64.c (aarch64_override_options_internal):
6059 Set default values for x_aarch64_*_string strings.
6060 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
6061 prefix. For -mabi do not print '=ABI' in help and use
6062 <option_value> format for -msve-vector-bits and -moverride
6063 options.
6064
6065 2018-08-26 Jeff Law <law@redhat.com>
6066
6067 * config/mips/frame-header-opt.c: Include "backend.h" rather than
6068 "cfg.h"
6069
6070 2018-08-26 Marek Polacek <polacek@redhat.com>
6071
6072 PR c++/87029, Implement -Wredundant-move.
6073 * doc/invoke.texi: Document -Wredundant-move.
6074
6075 2018-08-25 Martin Sebor <msebor@redhat.com>
6076
6077 PR tree-optimization/87059
6078 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
6079 to the same type as the other.
6080 * fold-const.c (fold_binary_loc): Assert expectation.
6081
6082 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
6083
6084 * config/darwin.c (machopic_legitimize_pic_address): Clean up
6085 extraneous parentheses, dead code section and formatting.
6086
6087 2018-08-24 David Malcolm <dmalcolm@redhat.com>
6088
6089 PR c++/87091
6090 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
6091 wide enough for jumps in the line-numbering to be visible.
6092 (layout::print_gap_in_line_numbering): New member function.
6093 (layout::calculate_line_spans): When using line numbering, merge
6094 line spans that are only 1 line apart.
6095 (diagnostic_show_locus): When printing line numbers, show gaps in
6096 line numbering directly, rather than printing headers.
6097 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
6098 line-numbering with multiple line spans.
6099 (selftest::test_fixit_insert_containing_newline_2): Add test of
6100 line-numbering, in which the spans are close enough to be merged.
6101
6102 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6103
6104 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
6105 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
6106 * tree-vrp.c (range_is_nonnull): Remove.
6107 (range_includes_zero_p): Accept value_range instead of min/max.
6108 (extract_range_from_binary_expr_1): Do not early bail on
6109 POINTER_PLUS_EXPR.
6110 Use range_includes_zero_p instead of range_is_nonnull.
6111 (extract_range_from_unary_expr): Use range_includes_zero_p instead
6112 of range_is_nonnull.
6113 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
6114 special case VR_ANTI_RANGE.
6115 (vrp_finalize): Same.
6116 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
6117 instead of min/max.
6118 (range_is_nonnull): Remove.
6119 * vr-values.c (vrp_stmt_computes_nonzero): Use
6120 range_includes_zero_p instead of range_is_nonnull.
6121 (extract_range_basic): Pass value_range to range_includes_zero_p
6122 instead of range_is_nonnull.
6123
6124 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
6125
6126 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
6127 * emit-rtl.h (rtl_data): Remove return_bnd.
6128 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
6129 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
6130 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
6131 (POINTER_BOUNDS_MODE): Remove definition.
6132 (make_pointer_bounds_mode): Remove.
6133 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
6134 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
6135 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
6136 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
6137 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
6138 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
6139 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
6140
6141 * config/i386/i386-modes.def (BND32, BND64): Remove.
6142 * config/i386/i386.c (dbx_register_map): Remove bound registers.
6143 (dbx64_register_map): Ditto.
6144 (svr4_dbx_register_map): Ditto.
6145 (indirect_thunk_bnd_needed): Remove.
6146 (indirect_thunks_bnd_used): Ditto.
6147 (indirect_return_bnd_needed): Ditto.
6148 (indirect_return_via_cx_bnd): Ditto.
6149 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
6150 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
6151 (output_indirect_thunk): Ditto. Remove need_prefix argument.
6152 (output_indirect_thunk_function): Remove handling of
6153 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
6154 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
6155 (ix86_save_reg): Remove handling of crtl->return_bnd.
6156 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
6157 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
6158 and UNSPEC_BNDLX_ADDR.
6159 (ix86_output_indirect_branch_via_reg): Remove handling of
6160 indirect_thunk_prefix_bnd.
6161 (ix86_output_indirect_branch_via_push): Ditto.
6162 (ix86_output_function_return): Ditto.
6163 (ix86_output_indirect_function_return): Ditto.
6164 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
6165 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
6166 (CALL_USED_REGISTERS): Ditto.
6167 (REG_ALLOC_ORDER): Update for removal of bound registers.
6168 (HI_REGISTER_NAMES): Ditto.
6169 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
6170 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
6171 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
6172 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
6173 (FIRST_PSEUDO_REG): Update.
6174 (BND): Remove mode iterator.
6175 * config/i386/predicates.md (bnd_mem_operator): Remove.
6176
6177 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6178
6179 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
6180 vectors.
6181
6182 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6183
6184 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
6185 the case in which the permute needs only a single element and
6186 repeats for every vector of the result. Extend that case to
6187 handle variable-length vectors.
6188 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
6189
6190 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
6191
6192 PR debug/79342
6193 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
6194 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
6195
6196 2018-08-24 Richard Biener <rguenther@suse.de>
6197
6198 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
6199 bb_flags_allocated members.
6200 (auto_flag): New RAII class for allocating flags.
6201 (auto_edge_flag): New RAII class for allocating edge flags.
6202 (auto_bb_flag): New RAII class for allocating bb flags.
6203 * cfgloop.c (verify_loop_structure): Allocate temporary edge
6204 flag dynamically.
6205 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
6206 in favor of temporarily allocated BB flag.
6207 * hsa-brig.c: Re-order includes.
6208 * hsa-dump.c: Likewise.
6209 * hsa-regalloc.c: Likewise.
6210 * print-rtl.c: Likewise.
6211 * profile-count.c: Likewise.
6212
6213 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
6214
6215 PR target/86989
6216 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
6217 the TOC register.
6218
6219 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6220
6221 PR 87073/bootstrap
6222 * wide-int-range.cc (wide_int_range_div): Do not ignore result
6223 from wide_int_range_multiplicative_op.
6224
6225 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6226
6227 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
6228 "permutaion".
6229
6230 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
6231
6232 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
6233 to 'expanded'.
6234
6235 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
6236
6237 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
6238 full GENERIC expression used for replacement.
6239
6240 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
6241
6242 * tree-vrp.c (abs_extent_range): Remove.
6243 (extract_range_into_wide_ints): Pass wide ints by reference.
6244 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
6245 Pass wide ints by reference in all calls to
6246 extract_range_into_wide_ints.
6247 * wide-int-range.cc (wide_int_range_div): New.
6248 * wide-int-range.h (wide_int_range_div): New.
6249 (wide_int_range_includes_zero_p): New.
6250 (wide_int_range_zero_p): New.
6251
6252 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
6253
6254 * config/aarch64/aarch64.md (arches): New enum.
6255 (arch): New enum attr.
6256 (arch_enabled): New attr.
6257 (enabled): Now uses arch_enabled only.
6258 (simd, sve, fp16): Removed attribute.
6259 (fp): Attr now defined in terms of 'arch'.
6260 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
6261 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
6262 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
6263 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
6264 attributes into 'arch'.
6265 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
6266 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
6267 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
6268 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
6269 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
6270 'simd' attribute into 'arch'.
6271 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
6272 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
6273 Convert use of 'fp' attribute to 'arch'.
6274 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
6275 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
6276 into 'arch'.
6277 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
6278 (different modes) Merge 'fp' and 'simd' into 'arch'.
6279 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
6280 'simd' into 'arch'.
6281
6282 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
6283
6284 PR rtl-optimization/87026
6285 * expmed.c (canonicalize_comparison): If we can no longer create
6286 pseudoregisters, don't.
6287
6288 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
6289
6290 PR target/86951
6291 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
6292 prototype.
6293 * config/arm/arm.c (speculation_barrier_libfunc): New static
6294 variable.
6295 (arm_init_libfuncs): Initialize it.
6296 (arm_emit_speculation_barrier): New function.
6297 * config/arm/arm.md (speculation_barrier): Call
6298 arm_emit_speculation_barrier for architectures that do not have
6299 DSB or ISB.
6300 (speculation_barrier_insn): Only match on Armv7 or later.
6301
6302 2018-08-23 Richard Biener <rguenther@suse.de>
6303
6304 PR middle-end/87024
6305 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
6306 calls.
6307
6308 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6309
6310 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
6311 of single-vector TBLs.
6312 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
6313 one input is given.
6314
6315 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6316
6317 PR target/85910
6318 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
6319 aarch64_evpc_tbl guard.
6320
6321 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
6322
6323 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
6324 behaviour.
6325
6326 2018-08-22 Martin Sebor <msebor@redhat.com>
6327
6328 PR middle-end/87052
6329 * tree-pretty-print.c (pretty_print_string): Add argument.
6330 (dump_generic_node): Call to pretty_print_string with string size.
6331
6332 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
6333
6334 PR rtl-optimization/86771
6335 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
6336 of two SETs into those two SETs, one to be placed at i2, if that SETs
6337 destination is modified between i2 and i3.
6338
6339 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6340
6341 PR tree-optimization/86725
6342 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
6343 function.
6344 (vect_analyze_scalar_cycles_1): Check it.
6345
6346 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6347
6348 PR tree-optimization/86725
6349 * tree-vect-loop.c (vect_is_simple_reduction): When treating
6350 an outer loop phi as a double reduction, make sure that the
6351 single user of the phi result is an inner loop phi.
6352
6353 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6354
6355 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
6356 grouped stores with gaps to a strided group.
6357
6358 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6359
6360 * tree-vect-stmts.c (get_group_load_store_type)
6361 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
6362 first statement in a group.
6363
6364 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6365
6366 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
6367 the sequence used in gcc/gcc.c.
6368
6369 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6370
6371 PR other/704
6372 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
6373 building it.
6374
6375 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6376
6377 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
6378 Darwin10-specific unwinder-shim.
6379 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
6380 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
6381 New to cater for Darwin10 Rosetta.
6382
6383 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6384
6385 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
6386 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
6387
6388 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6389
6390 PR bootstrap/81033
6391 PR target/81733
6392 PR target/52795
6393 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
6394 (dwarf2out_switch_text_section): Generate a local label for the
6395 second function sub-section and apply it as the second FDE start
6396 label.
6397 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
6398 second sub-section start.
6399
6400 2018-08-22 Richard Biener <rguenther@suse.de>
6401
6402 PR tree-optimization/86988
6403 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
6404
6405 2018-08-22 Richard Biener <rguenther@suse.de>
6406
6407 PR tree-optimization/86945
6408 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
6409
6410 2018-08-22 Alexandre Oliva <oliva@adacore.com>
6411
6412 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
6413 a comment about how uses of r2 for .sdata2 come about.
6414
6415 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
6416
6417 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
6418
6419 2018-08-21 Marek Polacek <polacek@redhat.com>
6420
6421 PR c++/86981, Implement -Wpessimizing-move.
6422 * doc/invoke.texi: Document -Wpessimizing-move.
6423
6424 2018-08-21 Jan Hubicka <jh@suse.cz>
6425
6426 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
6427 * tree.h (is_redundant_typedef): Remove.
6428 * dwarf2out.c (is_redundant_typedef): Turn into static function.
6429
6430 2018-08-21 Jan Hubicka <jh@suse.cz>
6431
6432 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
6433 when possible.
6434
6435 2018-08-21 Tamar Christina <tamar.christina@arm.com>
6436
6437 * expmed.c (extract_low_bits): Reject invalid subregs early.
6438
6439 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6440
6441 PR middle-end/86121
6442 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
6443 behaviour.
6444
6445 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6446
6447 * config/vxworks.h: Guard vxworks_asm_out_constructor and
6448 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
6449 * config/vxworks.c: Likewise.
6450
6451 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6452
6453 * config/vxworks.c: Set targetm.have_ctors_dtors
6454 if HAVE_INITFINI_ARRAY_SUPPORT.
6455 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
6456 if HAVE_INITFINI_ARRAY_SUPPORT.
6457
6458 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6459
6460 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
6461 default search path for VxWorks < 7.
6462
6463 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6464
6465 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
6466 (get_format_string): Refer to c_getstr.
6467
6468 2018-08-21 Tom de Vries <tdevries@suse.de>
6469
6470 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6471 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6472 (debuginfo_early_stop): Declare.
6473 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6474 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6475 (debuginfo_early_stop): New function.
6476 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
6477 and debuginfo_early_stop.
6478 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
6479 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
6480 (general_init): Call debuginfo_early_init.
6481 (finalize): Call debuginfo_fini.
6482 (do_compile): Call debuginfo_init.
6483 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
6484 -fdump-early-debug.
6485 (@item -fdump-debug, @item -fdump-earlydebug): Add.
6486
6487 2018-08-21 Tom de Vries <tdevries@suse.de>
6488
6489 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
6490 flag_dump_noaddr and flag_dump_unnumbered.
6491
6492 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
6493
6494 * wide-int-range.cc (wide_int_range_abs): New.
6495 (wide_int_range_order_set): Rename from wide_int_range_min_max.
6496 * wide-int-range.h (wide_int_range_abs): New.
6497 (wide_int_range_min_max): New.
6498 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
6499 case to call wide_int_range_abs.
6500 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
6501 (extract_range_from_abs_expr): Delete.
6502
6503 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
6504
6505 PR target/87033
6506 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
6507 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
6508 for indexed loads.
6509
6510 2018-08-20 Nathan Sidwell <nathan@acm.org>
6511 Jeff Law <law@redhat.com>
6512
6513 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
6514 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
6515
6516 2018-08-20 David Malcolm <dmalcolm@redhat.com>
6517
6518 PR other/84889
6519 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
6520 (decl_attributes): Likewise.
6521 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
6522 instance.
6523 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
6524 * diagnostic-core.h (class auto_diagnostic_group): New class.
6525 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
6526 (diagnostic_report_diagnostic): Handle the first diagnostics within
6527 a group.
6528 (emit_diagnostic): Add auto_diagnostic_group instance.
6529 (inform): Likewise.
6530 (inform_n): Likewise.
6531 (warning): Likewise.
6532 (warning_at): Likewise.
6533 (warning_n): Likewise.
6534 (pedwarn): Likewise.
6535 (permerror): Likewise.
6536 (error): Likewise.
6537 (error_n): Likewise.
6538 (error_at): Likewise.
6539 (sorry): Likewise.
6540 (fatal_error): Likewise.
6541 (internal_error): Likewise.
6542 (internal_error_no_backtrace): Likewise.
6543 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
6544 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
6545 * diagnostic.h (struct diagnostic_context): Add fields
6546 "diagnostic_group_nesting_depth",
6547 "diagnostic_group_emission_count", "begin_group_cb",
6548 "end_group_cb".
6549 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
6550 Add auto_diagnostic_group instance(s).
6551 (find_explicit_erroneous_behavior): Likewise.
6552 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
6553 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
6554 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
6555 (gimplify_va_arg_expr): Likewise.
6556 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
6557 (HSA_SORRY_AT): Likewise.
6558 * ipa-devirt.c (compare_virtual_tables): Likewise.
6559 (warn_odr): Likewise.
6560 * multiple_target.c (expand_target_clones): Likewise.
6561 * opts-common.c (cmdline_handle_error): Likewise.
6562 * reginfo.c (globalize_reg): Likewise.
6563 * substring-locations.c (format_warning_n_va): Likewise.
6564 * tree-inline.c (expand_call_inline): Likewise.
6565 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
6566 * tree-ssa-loop-niter.c
6567 (do_warn_aggressive_loop_optimizations): Likewise.
6568 * tree-ssa-uninit.c (warn_uninit): Likewise.
6569 * tree.c (warn_deprecated_use): Likewise.
6570
6571 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
6572
6573 PR target/87014
6574 * config/i386/i386.md (eh_return): Always update EH return
6575 address in word_mode.
6576
6577 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
6578
6579 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
6580 TARGET_SPLIT_COMPLEX_ARG is defined.
6581
6582 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6583
6584 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
6585
6586 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6587
6588 PR target/86984
6589 * expr.c (expand_assignment): Assert that bitpos is positive.
6590 (store_field): Likewise
6591 (expand_expr_real_1): Make sure that bitpos is positive.
6592 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
6593 integer overflow.
6594
6595 2018-08-20 Nathan Sidwell <nathan@acm.org>
6596
6597 * Makefile.in (CPP_ID_DATA_H): Delete.
6598 (CPP_INTERNAL_H): Don't add it.
6599 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
6600 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
6601
6602 2018-08-20 Richard Biener <rguenther@suse.de>
6603
6604 PR tree-optimization/78655
6605 * tree-vrp.c (extract_range_from_binary_expr_1): Make
6606 pointer + offset nonnull if either operand is nonnull work.
6607
6608 2018-08-20 Tom de Vries <tdevries@suse.de>
6609
6610 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
6611 unless the referenced die describes the added property using
6612 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
6613 Otherwise, add a DW_AT_location to the referenced die.
6614
6615 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
6616
6617 PR target/86994
6618 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
6619 register_operand when calling ix86_set_reg_reg_cost.
6620 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
6621 Set *total to 0 for operands that satisfy x86_64_immediate_operand
6622 predicate and to 1 otherwise.
6623
6624 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
6625
6626 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
6627 emit a diagnostic that it is not supported and reset the option.
6628 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
6629 supported and consume the option. (ASM_FINAL_SPEC): New.
6630
6631 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6632
6633 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
6634 a sentence.
6635
6636 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
6637
6638 C-SKY port: Documentation
6639
6640 * doc/extend.texi (C-SKY Function Attributes): New section.
6641 * doc/invoke.texi (Option Summary): Add C-SKY options.
6642 (C-SKY Options): New section.
6643 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
6644
6645 2018-08-17 Jojo <jijie_rong@c-sky.com>
6646 Huibin Wang <huibin_wang@c-sky.com>
6647 Sandra Loosemore <sandra@codesourcery.com>
6648 Chung-Lin Tang <cltang@codesourcery.com>
6649
6650 C-SKY port: Backend implementation
6651
6652 * config/csky/*: New.
6653 * common/config/csky/*: New.
6654
6655 2018-08-17 Jojo <jijie_rong@c-sky.com>
6656 Huibin Wang <huibin_wang@c-sky.com>
6657 Sandra Loosemore <sandra@codesourcery.com>
6658 Chung-Lin Tang <cltang@codesourcery.com>
6659 Andrew Jenner <andrew@codesourcery.com>
6660
6661 C-SKY port: Configury
6662
6663 * config.gcc (csky-*-*): New.
6664 * configure.ac: Add csky to targets for dwarf2 debug_line support.
6665 * configure: Regenerated.
6666
6667 2018-08-17 David Malcolm <dmalcolm@redhat.com>
6668
6669 * dump-context.h: Include "dumpfile.h".
6670 (dump_context::dump_printf_va): Convert final param from va_list
6671 to va_list *. Convert from ATTRIBUTE_PRINTF to
6672 ATTRIBUTE_GCC_DUMP_PRINTF.
6673 (dump_context::dump_printf_loc_va): Likewise.
6674 * dumpfile.c: Include "stringpool.h".
6675 (make_item_for_dump_printf_va): Delete.
6676 (make_item_for_dump_printf): Delete.
6677 (class dump_pretty_printer): New class.
6678 (dump_pretty_printer::dump_pretty_printer): New ctor.
6679 (dump_pretty_printer::emit_items): New member function.
6680 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
6681 function.
6682 (dump_pretty_printer::emit_item): New member function.
6683 (dump_pretty_printer::stash_item): New member function.
6684 (dump_pretty_printer::format_decoder_cb): New member function.
6685 (dump_pretty_printer::decode_format): New member function.
6686 (dump_context::dump_printf_va): Reimplement in terms of
6687 dump_pretty_printer.
6688 (dump_context::dump_printf_loc_va): Convert final param from va_list
6689 to va_list *.
6690 (dump_context::begin_scope): Reimplement call to
6691 make_item_for_dump_printf.
6692 (dump_printf): Update for change to dump_printf_va.
6693 (dump_printf_loc): Likewise.
6694 (selftest::test_capture_of_dump_calls): Convert "stmt" from
6695 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
6696 with %T, %E, and %G.
6697 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
6698 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
6699 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
6700 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
6701 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
6702 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
6703 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
6704 within a dump_printf_loc call to "%wu".
6705 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
6706 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
6707 missing space after "=".
6708 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
6709 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
6710 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
6711 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
6712 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
6713 duplicate "vectorized" from message.
6714
6715 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
6716
6717 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
6718 polyNxK_t element's TYPE_STRING_FLAG.
6719
6720 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6721
6722 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
6723 (they were unnamed before). Fix comments.
6724
6725 2018-08-17 Nathan Sidwell <nathan@acm.org>
6726
6727 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
6728
6729 2018-08-17 Richard Biener <rguenther@suse.de>
6730
6731 PR tree-optimization/86841
6732 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
6733
6734 2018-08-17 Martin Liska <mliska@suse.cz>
6735
6736 * common.opt: Remove Warn, Init and Report for options with
6737 Ignore/Deprecated flag. Warning is done automatically for
6738 Deprecated flags.
6739 * config/i386/i386.opt: Likewise.
6740 * config/ia64/ia64.opt: Likewise.
6741 * config/rs6000/rs6000.opt: Likewise.
6742 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
6743 Remove usage of flag_check_pointer_bounds.
6744 * lto-wrapper.c (merge_and_complain): Do not handle
6745 OPT_fcheck_pointer_bounds.
6746 (append_compiler_options): Likewise.
6747 * opt-functions.awk: Do not handle Deprecated.
6748 * optc-gen.awk: Check that Var, Report and Init are not
6749 used for an option with Ignore/Deprecated flag.
6750 * opts-common.c (decode_cmdline_option): Do not report
6751 CL_ERR_DEPRECATED.
6752 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
6753 options.
6754 * opts.h (struct cl_option): Remove cl_deprecated flag.
6755 (CL_ERR_DEPRECATED): Remove error enum value.
6756
6757 2018-08-17 Richard Biener <rguenther@suse.de>
6758
6759 PR middle-end/86505
6760 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
6761 across a va-arg-pack using call adjust its return value accordingly.
6762
6763 2018-08-16 Martin Sebor <msebor@redhat.com>
6764
6765 PR tree-optimization/86853
6766 * gimple-ssa-sprintf.c (struct format_result): Rename member.
6767 (struct fmtresult): Add member and initialize it in ctors.
6768 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
6769 (format_string): Handle %S the same as %ls. Set MAYFAIL.
6770 (format_directive): Set POSUNDER4K when MAYFAIL is set.
6771 (parse_directive): Handle %C same as %c.
6772 (sprintf_dom_walker::compute_format_length): Adjust.
6773 (is_call_safe): Adjust.
6774
6775 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
6776
6777 * builtins.c (c_strlen): Add new parameter eltsize. Use it
6778 for determining how to count the elements.
6779 * builtins.h (c_strlen): Adjust prototype.
6780 * expr.c (string_constant): Add new parameter mem_size.
6781 Set *mem_size appropriately.
6782 * expr.h (string_constant): Adjust protoype.
6783 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
6784 * gimple-fold.h (get_range_strlen): Adjust prototype.
6785 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
6786 (format_string): Call get_string_length with eltsize.
6787
6788 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6789
6790 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
6791 to emit the span, rather than setting it as the prefix.
6792
6793 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6794
6795 * diagnostic-show-locus.c (layout::start_annotation_line): Add
6796 "margin_char" parameter, defaulting to space. Use it in place
6797 of pp_space for the initial part of the margin.
6798 (layout::print_leading_fixits): Use '+' when filling the margin
6799 of line-insertion fix-it hints.
6800
6801 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6802
6803 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
6804 Delete.
6805
6806 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6807
6808 * config/rs6000/altivec.md: Don't set length attribute to the default
6809 value.
6810 * config/rs6000/darwin.md: Ditto.
6811 * config/rs6000/dfp.md: Ditto.
6812 * config/rs6000/htm.md: Ditto.
6813 * config/rs6000/rs6000.md: Ditto.
6814 * config/rs6000/sync.md: Ditto.
6815 * config/rs6000/vsx.md: Ditto.
6816
6817 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6818
6819 * config/rs6000/altivec.md: Don't set length attribute to the default
6820 value, for branch instructions.
6821 * config/rs6000/darwin.md: Ditto.
6822 * config/rs6000/rs6000.md: Ditto.
6823
6824 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6825
6826 * config/rs6000/rs6000.md (length): Always define as const_int 4.
6827 (unnamed conditional branch define_insn): Set length to 4 or 8
6828 depending on offset.
6829 (<bd>_<mode>): Similar, for alternative 0.
6830 (<bd>tf_<mode>): Ditto.
6831
6832 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6833
6834 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
6835
6836 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
6837
6838 * doc/rtl.texi: Replace old RTX class names with new names.
6839
6840
6841 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
6842
6843 * expmed.h (canonicalize_comparison): New declaration.
6844 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
6845 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
6846 * optabs.c (prepare_cmp_insn): Likewise.
6847 * rtl.h (unsigned_condition_p): New function which checks if a
6848 comparison operator is unsigned.
6849
6850 2018-08-16 Nathan Sidwell <nathan@acm.org>
6851
6852 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
6853 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
6854
6855 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6856
6857 PR target/84711
6858 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
6859 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
6860 (mov<mov>): ..this and enable unconditionally.
6861
6862 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6863
6864 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
6865
6866 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
6867
6868 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
6869 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
6870 "Common" with "Target".
6871
6872 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
6873
6874 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
6875 * doc/invoke.texi (mmitigate-rop): Remove.
6876 * config/i386/i386.c: Do not include "regrename.h".
6877 (ix86_rop_should_change_byte_p, reg_encoded_number)
6878 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
6879 Remove.
6880 (ix86_reorg): Remove call to ix86_mitigate_rop.
6881 * config/i386/i386.md (attr "modrm_class"): Remove.
6882 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
6883 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
6884 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
6885
6886 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
6887
6888 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
6889 allow folding of mergeh() and mergel() for the float and double types.
6890 (fold_mergehl_helper): Rework to handle building a permute tree
6891 for float vectors.
6892
6893 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
6894
6895 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
6896 for TARGET_SSE.
6897
6898 2018-08-15 David Malcolm <dmalcolm@redhat.com>
6899
6900 * common.opt (fdiagnostics-show-labels): New option.
6901 * diagnostic-show-locus.c (class layout_range): Add field
6902 "m_label".
6903 (class layout): Add field "m_show_labels_p".
6904 (layout_range::layout_range): Add param "label" and use it to
6905 initialize m_label.
6906 (make_range): Pass in NULL for new "label" param of layout_range's
6907 ctor.
6908 (layout::layout): Initialize m_show_labels_p.
6909 (layout::maybe_add_location_range): Pass in loc_range->m_label
6910 when constructing layout_range instances.
6911 (struct line_label): New struct.
6912 (layout::print_any_labels): New member function.
6913 (layout::print_line): Call it if label-printing is enabled.
6914 (selftest::test_one_liner_labels): New test.
6915 (selftest::test_diagnostic_show_locus_one_liner): Call it.
6916 * diagnostic.c (diagnostic_initialize): Initialize
6917 context->show_labels_p.
6918 * diagnostic.h (struct diagnostic_context): Add field
6919 "show_labels_p".
6920 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
6921 -fno-diagnostics-show-labels.
6922 * dwarf2out.c (gen_producer_string): Add
6923 OPT_fdiagnostics_show_labels to the ignored options.
6924 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
6925 param.
6926 (gcc_rich_location::maybe_add_expr): Likewise.
6927 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
6928 label" param, defaulting to NULL.
6929 (gcc_rich_location::add_expr): Add "label" param.
6930 (gcc_rich_location::maybe_add_expr): Likewise.
6931 (class text_range_label): New class.
6932 (class range_label_for_type_mismatch): New class.
6933 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
6934 of format_warning_va.
6935 (fmtwarn_n): Likewise for new params of format_warning_n_va.
6936 * lto-wrapper.c (merge_and_complain): Add
6937 OPT_fdiagnostics_show_labels to the "pick one setting" options.
6938 (append_compiler_options): Likewise to the dropped options.
6939 (append_diag_options): Likewise to the passed-on options.
6940 * opts.c (common_handle_option): Handle the new option.
6941 * selftest-diagnostic.c
6942 (test_diagnostic_context::test_diagnostic_context): Enable
6943 show_labels_p.
6944 * substring-locations.c: Include "gcc-rich-location.h".
6945 (format_warning_n_va): Add "fmt_label" and "param_label" params
6946 and use them as appropriate.
6947 (format_warning_va): Add "fmt_label" and "param_label" params,
6948 passing them on to format_warning_n_va.
6949 (format_warning_at_substring): Likewise.
6950 (format_warning_at_substring_n): Likewise.
6951 * substring-locations.h (format_warning_va): Add "fmt_label" and
6952 "param_label" params.
6953 (format_warning_n_va): Likewise.
6954 (format_warning_at_substring): Likewise.
6955 (format_warning_at_substring_n): Likewise.
6956 * toplev.c (general_init): Initialize global_dc->show_labels_p.
6957
6958 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
6959
6960 PR testsuite/86519
6961 * builtins.c (expand_builtin_memcmp): Do not expand the call
6962 when overflow is detected.
6963
6964 2018-08-15 Martin Sebor <msebor@redhat.com>
6965
6966 PR tree-optimization/71625
6967 * config/aarch64/aarch64-builtins.c
6968 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
6969
6970 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
6971
6972 * config/s390/s390.c (s390_reorg): Remove loop.
6973
6974 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
6975
6976 * config/darwin.c
6977 (darwin_function_switched_text_sections): Delete.
6978 * gcc/config/darwin.h
6979 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
6980
6981 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
6982
6983 PR target/81685
6984 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
6985 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
6986 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
6987
6988 2018-08-15 Martin Liska <mliska@suse.cz>
6989
6990 PR tree-optimization/86925
6991 * predict.c (expr_expected_value_1): When taking
6992 later predictor, assign also probability.
6993 Use fold_build2_initializer_loc in order to fold
6994 the expression in -frounding-math.
6995
6996 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
6997
6998 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
6999 patterns.
7000 (expand_vec_perm_1): Try the new method.
7001
7002 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
7003
7004 PR target/86547
7005 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
7006 Check whether lra_live_max_point is 0 before dividing.
7007
7008 2018-08-14 Martin Sebor <msebor@redhat.com>
7009
7010 PR tree-optimization/86650
7011 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
7012 (vrp_prop::check_mem_ref): Same.
7013
7014 2018-08-13 Liu Hao <lh_mouse@126.com>
7015
7016 * pretty-print.c (eat_esc_sequence): Swap the foreground and
7017 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
7018 and clear it thereafter, as it only works for DBCS.
7019
7020 2018-08-13 Liu Hao <lh_mouse@126.com>
7021
7022 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
7023 handle returned by _get_osf_handle().
7024
7025 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7026
7027 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
7028 for folding vec_perm.
7029
7030 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7031
7032 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
7033 Add support for gimple-folding of vec_pack() and vec_unpack()
7034 intrinsics.
7035
7036 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7037
7038 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
7039 vec_xst variants to the list.
7040 (rs6000_gimple_fold_builtin): Add support for folding unaligned
7041 vector loads and stores.
7042
7043 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
7044
7045 * config.gcc (rs6000-ibm-aix4.x): Delete.
7046 (rs6000-ibm-aix5.1): Delete.
7047 (rs6000-ibm-aix5.2): Delete.
7048 (rs6000-ibm-aix5.3): Delete.
7049 * config/rs6000/aix43.h: Delete.
7050 * config/rs6000/aix51.h: Delete.
7051 * config/rs6000/aix52.h: Delete.
7052 * config/rs6000/t-aix43: Delete.
7053
7054 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
7055
7056 * config/s390/s390.c (s390_decompose_constant_pool_ref):
7057 New function.
7058 (s390_decompose_address): Factor out constant pool ref
7059 decomposition.
7060
7061 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7062
7063 * config/nds32/nds32-predicates.c
7064 (nds32_can_use_bclr_p): Change return type as bool.
7065 (nds32_can_use_bset_p): Ditto.
7066 (nds32_can_use_btgl_p): Ditto.
7067 (nds32_can_use_bitci_p): Ditto.
7068 * config/nds32/nds32-protos.h
7069 (nds32_can_use_bclr_p): Change declaration.
7070 (nds32_can_use_bset_p): Ditto.
7071 (nds32_can_use_btgl_p): Ditto.
7072 (nds32_can_use_bitci_p): Ditto.
7073
7074 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7075
7076 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
7077 Support -msched-prolog-epilog option.
7078 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
7079
7080 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7081
7082 * common/config/nds32/nds32-common.c
7083 (nds32_option_optimization_table): Enalbe -malways-align.
7084
7085 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7086
7087 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
7088 extra_headers.
7089 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
7090 OPT_misr_secure_ case.
7091 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
7092 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
7093 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
7094 secure attribute.
7095 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
7096 (nds32_isr_info): New field security_level.
7097 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
7098 * config/nds32/nds32.md (return_internal): Consider critical attribute.
7099 * config/nds32/nds32.opt (misr-secure): New option.
7100 * config/nds32/nds32_init.inc: New file.
7101 * config/nds32/nds32_isr.h: New file.
7102
7103 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
7104
7105 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
7106 Update comment for atomic instructions.
7107 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
7108 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
7109 Remove.
7110 (atomic_loaddi): Revise fence expansion to only emit fence prior to
7111 load for __ATOMIC_SEQ_CST model.
7112 (atomic_loaddi_1): Remove float register target.
7113 (atomic_storedi): Handle CONST_INT values.
7114 (atomic_storedi_1): Remove float register source. Add special case
7115 for zero value.
7116 (memory_barrier): New expander and insn.
7117
7118 2018-08-11 Jakub Jelinek <jakub@redhat.com>
7119
7120 PR tree-optimization/86835
7121 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
7122 new_stmt after def_gsi, make sure to insert new_square_stmt after
7123 that stmt, not 2 stmts before it.
7124
7125 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
7126
7127 PR target/82418
7128 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
7129 instead of SWI48.
7130
7131 2018-08-10 Martin Liska <mliska@suse.cz>
7132
7133 PR target/83610
7134 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
7135 function type.
7136 * builtins.c (expand_builtin_expect_with_probability):
7137 New function.
7138 (expand_builtin_expect_with_probability): New function.
7139 (build_builtin_expect_predicate): Add new argumnet probability
7140 for BUILT_IN_EXPECT_WITH_PROBABILITY.
7141 (fold_builtin_expect):
7142 (fold_builtin_2):
7143 (fold_builtin_3):
7144 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
7145 * builtins.h (fold_builtin_expect): Set new argument.
7146 * doc/extend.texi: Document __builtin_expect_with_probability.
7147 * doc/invoke.texi: Likewise.
7148 * gimple-fold.c (gimple_fold_call): Pass new argument.
7149 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
7150 also BUILT_IN_EXPECT_WITH_PROBABILITY.
7151 * predict.c (get_predictor_value): New function.
7152 (expr_expected_value): Add new argument probability. Assume
7153 that predictor and probability are always non-null.
7154 (expr_expected_value_1): Likewise. For __builtin_expect and
7155 __builtin_expect_with_probability set probability. Handle
7156 combination in binary expressions.
7157 (tree_predict_by_opcode): Simplify code by simply calling
7158 get_predictor_value.
7159 (pass_strip_predict_hints::execute): Add handling of
7160 BUILT_IN_EXPECT_WITH_PROBABILITY.
7161 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
7162 new predictor.
7163 * tree.h (DECL_BUILT_IN_P): New function.
7164
7165 2018-08-10 Martin Liska <mliska@suse.cz>
7166
7167 PR tree-optimization/85799
7168 * passes.def: Add argument for pass_strip_predict_hints.
7169 * predict.c (class pass_strip_predict_hints): Add new argument
7170 early_p.
7171 (strip_predictor_early): New function.
7172 (pass_strip_predict_hints::execute): Call the function to
7173 strip predictors.
7174 (strip_predict_hints): New function.
7175 * predict.def: Fix comment.
7176
7177 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
7178
7179 * Makefile.in: Clarify which tm.texi to copy over to assert the
7180 right to grant a GFDL license for all.
7181
7182 2018-08-09 Jeff Law <law@redhat.com>
7183
7184 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
7185 unused variable.
7186
7187 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
7188
7189 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
7190 prototype.
7191
7192 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7193
7194 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
7195 reductions for variable-length vectors.
7196
7197 2018-08-09 David Malcolm <dmalcolm@redhat.com>
7198
7199 PR other/84889
7200 * common.opt (fdiagnostics-show-line-numbers): New option.
7201 * diagnostic-show-locus.c (class layout): Add fields
7202 "m_show_line_numbers_p" and "m_linenum_width";
7203 (num_digits): New function.
7204 (test_num_digits): New function.
7205 (layout::layout): Initialize new fields. Update m_x_offset
7206 logic to handle any left margin.
7207 (layout::print_source_line): Print line number when requested.
7208 (layout::start_annotation_line): New member function.
7209 (layout::print_annotation_line): Call it.
7210 (layout::print_leading_fixits): Likewise.
7211 (layout::print_trailing_fixits): Likewise. Update calls to
7212 move_to_column for new parameter.
7213 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
7214 it to potentially call start_annotation_line.
7215 (layout::show_ruler): Call start_annotation_line.
7216 (selftest::test_line_numbers_multiline_range): New selftest.
7217 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
7218 and selftest::test_line_numbers_multiline_range.
7219 * diagnostic.c (diagnostic_initialize): Initialize
7220 show_line_numbers_p.
7221 * diagnostic.h (struct diagnostic_context): Add field
7222 "show_line_numbers_p".
7223 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
7224 -fno-diagnostics-show-line-numbers.
7225 * dwarf2out.c (gen_producer_string): Add
7226 OPT_fdiagnostics_show_line_numbers to the ignored options.
7227 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
7228 one setting" options.
7229 (append_compiler_options): Likewise to the dropped options.
7230 (append_diag_options): Likewise to the passed-on options.
7231 * opts.c (common_handle_option): Handle the new option.
7232 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
7233
7234 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
7235
7236 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
7237 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
7238 third argument of type "const signed char" to descriptions of
7239 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
7240 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
7241 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
7242 __builtin_bcdsub_ov functions.
7243
7244 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7245
7246 PR tree-optimization/86858
7247 * tree-vect-loop.c (vect_is_simple_reduction): Restore
7248 flow_bb_inside_loop_p calls.
7249
7250 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7251
7252 PR tree-optimization/86871
7253 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
7254 instead of gimple_assign_lhs.
7255
7256 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
7257
7258 PR target/86887
7259 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
7260 register constraint to operand 0.
7261 (add<mode>3_carryinC): Likewise.
7262 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
7263
7264 2018-08-09 Martin Liska <mliska@suse.cz>
7265
7266 PR c/86895
7267 * common.opt: Remove extra line.
7268
7269 2018-08-09 Martin Liska <mliska@suse.cz>
7270
7271 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
7272 at the end of a line, make first letter capital and end up
7273 a sentence with a dot.
7274 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
7275 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
7276 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
7277 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
7278 (PARAM_MAX_ISL_OPERATIONS): Likewise.
7279 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
7280 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
7281 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
7282 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
7283 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
7284 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
7285 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
7286 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
7287 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
7288 (PARAM_TREE_REASSOC_WIDTH): Likewise.
7289 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
7290 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
7291 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
7292
7293 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
7294
7295 PR target/84332
7296 * config/s390/s390.c (s390_option_override_internal): Reduce the
7297 stack-clash-protection-probe-interval param if it would be too big
7298 for z900.
7299
7300 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
7301
7302 PR target/46179
7303 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
7304 * config/m68k/m68k.c (handle_move_double): Don't call
7305 m68k_final_prescan_insn.
7306 (m68k_adjust_decorated_operand): Renamed from
7307 m68k_final_prescan_insn, remove first and third operand and
7308 simplify.
7309 (print_operand): Call it.
7310 (print_operand_address): Call it.
7311
7312 2018-08-08 Nathan Sidwell <nathan@acm.org>
7313
7314 * diagnostic.c (diagnostic_report_current_module): Use
7315 linemap_included_from & linemap_included_from_linemap.
7316
7317 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
7318
7319 * config/aarch64/aarch64-cores.def: Add phecda core.
7320 * config/aarch64/aarch64-tune.md: Regenerate.
7321 * doc/invoke.texi: Add phecda core.
7322
7323 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7324
7325 PR target/85295
7326 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
7327 definitions.
7328 * config/s390/s390.md ("movti"): Add more alternatives for
7329 constant to GPR copies.
7330
7331 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7332
7333 * config/s390/s390.c: Fix whitespace damage throughout the file.
7334 * config/s390/s390.h: Likewise.
7335 * config/s390/tpf.h: Likewise.
7336
7337 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7338
7339 * config/s390/s390.c (s390_loadrelative_operand_p):
7340 Remove TARGET_CPU_ZARCH usages.
7341 (s390_rtx_costs): Likewise.
7342 (s390_legitimate_constant_p): Likewise.
7343 (s390_cannot_force_const_mem): Likewise.
7344 (legitimate_reload_constant_p): Likewise.
7345 (s390_preferred_reload_class): Likewise.
7346 (legitimize_pic_address): Likewise.
7347 (legitimize_tls_address): Likewise.
7348 (s390_split_branches): Removed.
7349 (s390_add_execute): Removed.
7350 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
7351 (s390_mainpool_start): Likewise.
7352 (s390_mainpool_finish): Likewise.
7353 (s390_mainpool_cancel): Removed.
7354 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
7355 (s390_chunkify_cancel): Likewise.
7356 (s390_return_addr_rtx): Likewise.
7357 (s390_register_info): Remove split_branches_pending_p uages.
7358 (s390_optimize_register_info): Likewise.
7359 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
7360 split_branches_pending_p usages.
7361 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
7362 (s390_load_got): Likewise.
7363 (s390_expand_split_stack_prologue): Likewise.
7364 (output_asm_nops): Likewise.
7365 (s390_function_profiler): Likewise.
7366 (s390_emit_call): Likewise.
7367 (s390_conditional_register_usage): Likewise.
7368 (s390_optimize_prologue): Likewise.
7369 (s390_reorg): Remove TARGET_CPU_ZARCH and
7370 split_branches_pending_p usages.
7371 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
7372 usages.
7373 (s390_output_indirect_thunk_function): Likewise.
7374 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
7375 (TARGET_CPU_ZARCH_P): Removed.
7376 (struct machine_function): Remove split_branches_pending_p.
7377 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
7378
7379 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7380
7381 * common/config/s390/s390-common.c (processor_flags_table):
7382 Remove flags.
7383 * config.gcc: Remove with_arch/with_tune support.
7384 * config/s390/2064.md: Remove cpu attribute comparisons.
7385 * config/s390/driver-native.c (s390_host_detect_local_cpu):
7386 Remove MTN.
7387 * config/s390/linux.h (ASM_SPEC):
7388 Remove -march support.
7389 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
7390 Use a table to get an arch level.
7391 * config/s390/s390-opts.h (enum processor_type):
7392 Remove enum values.
7393 * config/s390/s390.c
7394 (processor_table): Remove entries, add arch_level values.
7395 (s390_issue_rate): Remove cases.
7396 (s390_option_override): Adjust
7397 s390_option_override_internal() call.
7398 (s390_option_override_internal): Remove deprecation warning.
7399 (s390_valid_target_attribute_tree): Adjust
7400 s390_option_override_internal() call.
7401 * config/s390/s390.h (struct s390_processor):
7402 Share with s390-c.c, add arch_level field.
7403 * config/s390/s390.md:
7404 Remove occurrences in cpu attribute.
7405 * config/s390/s390.opt: Remove -march/-mtune support.
7406 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
7407 * doc/invoke.texi: Remove deprecation warning.
7408
7409 2018-08-08 Luis Machado <luis.machado@linaro.org>
7410
7411 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
7412 global.
7413 (qdf24xx_tunings): Set vector cost structure to
7414 qdf24xx_vector_cost.
7415
7416 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
7417 <register_sextend>: Set to 3.
7418
7419 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
7420
7421 PR target/86838
7422 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
7423 * config/aarch64/aarch64-simd.md
7424 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
7425 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
7426 (aarch64_frecpx<mode>): ...this new pattern.
7427 * config/aarch64/aarch64-simd-builtins.def: Remove comment
7428 about aarch64_frecp<FRECP:frecp_suffix><mode>.
7429
7430 2018-08-07 Martin Liska <mliska@suse.cz>
7431
7432 PR middle-end/83023
7433 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
7434 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
7435 * predict.def (PRED_MALLOC_NONNULL): New predictor.
7436 * doc/extend.texi: Document that malloc attribute adds
7437 hit to compiler.
7438
7439 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
7440
7441 PR target/86785
7442 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7443 Define to speculation_safe_value_not_needed.
7444
7445 2018-08-06 Jeff Law <law@redhat.com>
7446
7447 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
7448 the vr_values instance to cprop_into_stmt.
7449 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
7450 (cprop_operand): Also query EVRP to determine if OP is a constant.
7451
7452 2018-08-06 Nathan Sidwell <nathan@acm.org>
7453
7454 * diagnostic.c (diagnostic_report_current_module): Reroll
7455 included-at loop. Translate text.
7456
7457 2018-08-06 David Malcolm <dmalcolm@redhat.com>
7458
7459 * function-tests.c (selftest::test_expansion_to_rtl): Call
7460 free_after_compilation.
7461
7462 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7463
7464 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
7465
7466 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
7467
7468 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
7469 loops with memory block operations from getting unrolled.
7470
7471 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
7472
7473 PR target/86807
7474 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7475 Define to speculation_safe_value_not_needed.
7476
7477 2018-08-06 Jeff Law <law@redhat.com>
7478
7479 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
7480 assert.
7481
7482 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
7483
7484 PR target/86662
7485 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
7486 with all enabled __intN types.
7487
7488 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
7489
7490 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7491
7492 * alias.c (record_set): Check for clobber high.
7493 * cfgexpand.c (expand_gimple_stmt): Likewise.
7494 * combine-stack-adj.c (single_set_for_csa): Likewise.
7495 * combine.c (find_single_use_1): Likewise.
7496 (set_nonzero_bits_and_sign_copies): Likewise.
7497 (get_combine_src_dest): Likewise.
7498 (is_parallel_of_n_reg_sets): Likewise.
7499 (try_combine): Likewise.
7500 (record_dead_and_set_regs_1): Likewise.
7501 (reg_dead_at_p_1): Likewise.
7502 (reg_dead_at_p): Likewise.
7503 * dce.c (deletable_insn_p): Likewise.
7504 (mark_nonreg_stores_1): Likewise.
7505 (mark_nonreg_stores_2): Likewise.
7506 * df-scan.c (df_find_hard_reg_defs): Likewise.
7507 (df_uses_record): Likewise.
7508 (df_get_call_refs): Likewise.
7509 * dwarf2out.c (mem_loc_descriptor): Likewise.
7510 * haifa-sched.c (haifa_classify_rtx): Likewise.
7511 * ira-build.c (create_insn_allocnos): Likewise.
7512 * ira-costs.c (scan_one_insn): Likewise.
7513 * ira.c (equiv_init_movable_p): Likewise.
7514 (rtx_moveable_p): Likewise.
7515 (interesting_dest_for_shprep): Likewise.
7516 * jump.c (mark_jump_label_1): Likewise.
7517 * postreload-gcse.c (record_opr_changes): Likewise.
7518 * postreload.c (reload_cse_simplify): Likewise.
7519 (struct reg_use): Add source expr.
7520 (reload_combine): Check for clobber high.
7521 (reload_combine_note_use): Likewise.
7522 (reload_cse_move2add): Likewise.
7523 (move2add_note_store): Likewise.
7524 * print-rtl.c (print_pattern): Likewise.
7525 * recog.c (decode_asm_operands): Likewise.
7526 (store_data_bypass_p): Likewise.
7527 (if_test_bypass_p): Likewise.
7528 * regcprop.c (kill_clobbered_value): Likewise.
7529 (kill_set_value): Likewise.
7530 * reginfo.c (reg_scan_mark_refs): Likewise.
7531 * reload1.c (maybe_fix_stack_asms): Likewise.
7532 (eliminate_regs_1): Likewise.
7533 (elimination_effects): Likewise.
7534 (mark_not_eliminable): Likewise.
7535 (scan_paradoxical_subregs): Likewise.
7536 (forget_old_reloads_1): Likewise.
7537 * reorg.c (find_end_label): Likewise.
7538 (try_merge_delay_insns): Likewise.
7539 (redundant_insn): Likewise.
7540 (own_thread_p): Likewise.
7541 (fill_simple_delay_slots): Likewise.
7542 (fill_slots_from_thread): Likewise.
7543 (dbr_schedule): Likewise.
7544 * resource.c (update_live_status): Likewise.
7545 (mark_referenced_resources): Likewise.
7546 (mark_set_resources): Likewise.
7547 * rtl.c (copy_rtx): Likewise.
7548 * rtlanal.c (reg_referenced_p): Likewise.
7549 (single_set_2): Likewise.
7550 (noop_move_p): Likewise.
7551 (note_stores): Likewise.
7552 * sched-deps.c (sched_analyze_reg): Likewise.
7553 (sched_analyze_insn): Likewise.
7554
7555 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7556
7557 * cse.c (invalidate_reg): New function extracted from...
7558 (invalidate): ...here.
7559 (canonicalize_insn): Check for clobber high.
7560 (invalidate_from_clobbers): invalidate clobber highs.
7561 (invalidate_from_sets_and_clobbers): Likewise.
7562 (count_reg_usage): Check for clobber high.
7563 (insn_live_p): Likewise.
7564 * cselib.c (cselib_expand_value_rtx_1):Likewise.
7565 (cselib_invalidate_regno): Check for clobber in setter.
7566 (cselib_invalidate_rtx): Pass through setter.
7567 (cselib_invalidate_rtx_note_stores):
7568 (cselib_process_insn): Check for clobber high.
7569 * cselib.h (cselib_invalidate_rtx): Add operand.
7570
7571 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7572
7573 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
7574 (mark_not_eliminable): Likewise.
7575 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
7576 * lra-lives.c (process_bb_lives): Check for clobber high.
7577 * lra.c (new_insn_reg): Remember clobber highs.
7578 (collect_non_operand_hard_regs): Check for clobber high.
7579 (lra_set_insn_recog_data): Likewise.
7580 (add_regs_to_insn_regno_info): Likewise.
7581 (lra_update_insn_regno_info): Likewise.
7582
7583 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7584
7585 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
7586 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
7587
7588 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7589
7590 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
7591 (copy_insn_1): Likewise.
7592 (gen_hard_reg_clobber_high): New gen function.
7593 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
7594 * genemit.c (gen_exp): Likewise.
7595 (gen_emit_seq): Pass through info.
7596 (gen_insn): Check for CLOBBER_HIGH.
7597 (gen_expand): Pass through info.
7598 (gen_split): Likewise.
7599 (output_add_clobbers): Likewise.
7600 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
7601 (remove_clobbers): Likewise.
7602 * rtl.h (gen_hard_reg_clobber_high): New declaration.
7603
7604 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7605
7606 * doc/rtl.texi (clobber_high): Add.
7607 (parallel): Add in clobber high
7608 * rtl.c (rtl_check_failed_code3): Add function.
7609 * rtl.def (CLOBBER_HIGH): Add expression.
7610 * rtl.h (RTL_CHECKC3): Add macro.
7611 (rtl_check_failed_code3): Add declaration.
7612 (XC3EXP): Add macro.
7613
7614 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
7615
7616 PR target/86386
7617 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
7618 cfun->machine->max_used_stack_alignment if needed.
7619
7620 2018-08-04 Martin Sebor <msebor@redhat.com>
7621
7622 PR tree-optimization/86571
7623 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
7624 NaN output to 4.
7625
7626 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
7627
7628 PR target/86799
7629 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7630 Define.
7631
7632 2018-08-03 Jeff Law <law@redhat.com>
7633
7634 PR target/86795
7635 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7636 Define to speculation_safe_value_not_needed.
7637
7638 2018-08-03 David Malcolm <dmalcolm@redhat.com>
7639
7640 * doc/gcov.texi (-x): Remove duplicate "to".
7641 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
7642 (-Wif-not-aligned): Remove duplicate "is".
7643 (-flto): Remove duplicate "the".
7644 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
7645 duplicate "v5.00.b".
7646 (MSP430 Options): Remove duplicate "and" from the description
7647 of "-mgprel-sec=regexp".
7648 (x86 Options): Remove duplicate copies of "vmldLog102" and
7649 vmlsLog104 from description of "-mveclibabi=type".
7650
7651 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
7652
7653 * internal-fn.h (first_commutative_argument): Declare.
7654 * internal-fn.c (first_commutative_argument): New function.
7655 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
7656 restrictions for pattern statements. Use first_commutative_argument
7657 to look for commutative operands in calls to internal functions.
7658
7659 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
7660
7661 * Makefile.in (wide-int-range.o): New.
7662 * tree-vrp.c: Move all the wide_int_* functions to...
7663 * wide-int-range.cc: ...here.
7664 * tree-vrp.h: Move all the wide_int_* prototypes to...
7665 * wide-int-range.h: ...here.
7666
7667 2018-08-03 Tom de Vries <tdevries@suse.de>
7668
7669 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
7670 UI_NONE.
7671 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
7672 * except.c (output_function_exception_table): Do early exit if
7673 targetm_common.except_unwind_info (&global_options) == UI_NONE.
7674
7675 2018-08-03 Martin Liska <mliska@suse.cz>
7676
7677 * predict.c (dump_prediction): Change to 2 digits
7678 in fraction part.
7679
7680 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
7681
7682 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
7683 neon_dup_q to...
7684 (falkor_am_1_gtov_gtov): ... a new insn reservation.
7685
7686 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
7687
7688 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
7689 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
7690 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
7691 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
7692 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
7693
7694 2018-08-02 David Malcolm <dmalcolm@redhat.com>
7695
7696 * diagnostic-show-locus.c (diagnostic_show_locus): Use
7697 pp_take_prefix when saving the existing prefix.
7698 * diagnostic.c (diagnostic_append_note): Likewise.
7699 * langhooks.c (lhd_print_error_function): Likewise.
7700 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
7701 param's type. Free the existing prefix.
7702 (pp_take_prefix): New function.
7703 (pretty_printer::pretty_printer): Drop the prefix parameter.
7704 Rename the length parameter to match the comment.
7705 (pretty_printer::~pretty_printer): Free the prefix.
7706 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
7707 parameter.
7708 (struct pretty_printer): Drop the "const" from "prefix" field's
7709 type and clarify memory management.
7710 (pp_set_prefix): Drop the "const" from the 2nd param.
7711 (pp_take_prefix): New decl.
7712
7713 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
7714
7715 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
7716 for word_mode_ok here instead of passing as argument.
7717 (expand_block_compare): Change select_block_compare_mode() call.
7718 (expand_strncmp_gpr_sequence): New function.
7719 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
7720
7721 2018-08-02 Jeff Law <law@redhat.com>
7722
7723 PR target/86790
7724 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7725 Define to speculation_safe_value_not_needed.
7726
7727 PR target/86784
7728 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7729 Define to speculation_safe_value_not_needed.
7730
7731 2018-08-02 Tom de Vries <tdevries@suse.de>
7732
7733 PR target/86660
7734 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
7735 function. Return UI_TARGET unconditionally.
7736 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
7737 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
7738
7739 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7740
7741 * genemit.c (print_overload_test): Fix typo.
7742
7743 2018-08-02 Richard Biener <rguenther@suse.de>
7744
7745 PR tree-optimization/86816
7746 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
7747 which checks for value availability before querying it.
7748 (gvn_uses_equal): Use it.
7749 (same_succ_hash): Likewise.
7750 (gimple_equal_p): Likewise.
7751
7752 2018-08-02 Nick Clifton <nickc@redhat.com>
7753
7754 PR target/86813
7755 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7756 Define to speculation_safe_value_not_needed.
7757
7758 PR target/86810
7759 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7760 Define to speculation_safe_value_not_needed.
7761
7762 PR target/86810
7763 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7764 Define to speculation_safe_value_not_needed.
7765
7766 PR target/86803
7767 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7768 Define to speculation_safe_value_not_needed.
7769
7770 PR target/86797
7771 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7772 Define to speculation_safe_value_not_needed.
7773
7774 PR target/86791
7775 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7776 Define to speculation_safe_value_not_needed.
7777
7778 PR target/86789
7779 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7780 Define to speculation_safe_value_not_needed.
7781
7782 PR target/86787
7783 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7784 Define to speculation_safe_value_not_needed.
7785
7786 PR target/86782
7787 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
7788 speculation_safe_value_not_needed.
7789
7790 PR target/86781
7791 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
7792 to speculation_safe_value_not_needed.
7793
7794 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7795
7796 * doc/md.texi: Expand the documentation of instruction names
7797 to mention port-local uses. Document '@' in pattern names.
7798 * read-md.h (overloaded_instance, overloaded_name): New structs.
7799 (mapping): Declare.
7800 (md_reader::handle_overloaded_name): New member function.
7801 (md_reader::get_overloads): Likewise.
7802 (md_reader::m_first_overload): New member variable.
7803 (md_reader::m_next_overload_ptr): Likewise.
7804 (md_reader::m_overloads_htab): Likewise.
7805 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
7806 m_next_overload_ptr and m_overloads_htab.
7807 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
7808 (get_mode_token, get_code_token, get_int_token): New functions.
7809 (map_attr_string): Add an optional argument that passes back
7810 the associated iterator.
7811 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
7812 (md_reader::handle_overloaded_name, add_overload_instance): New
7813 functions.
7814 (apply_iterators): Handle '@' names. Report an error if '@'
7815 is used without iterators.
7816 (initialize_iterators): Initialize the new iterator_group fields.
7817 * genopinit.c (handle_overloaded_code_for)
7818 (handle_overloaded_gen): New functions.
7819 (main): Use them to print declarations of maybe_code_for_* and
7820 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
7821 * genemit.c (print_overload_arguments, print_overload_test)
7822 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
7823 (main): Use it to print definitions of maybe_code_for_* and
7824 maybe_gen_* functions.
7825 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
7826 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
7827 instead of explicit mode checks.
7828 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
7829 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
7830 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
7831 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
7832 (aarch64_expand_compare_and_swap): Likewise
7833 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
7834 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
7835 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
7836 (aarch64_constant_pool_reload_icode): Delete.
7837 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
7838 instead of aarch64_constant_pool_reload_icode. Use
7839 code_for_aarch64_reload_mov instead of explicit mode checks.
7840 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
7841 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
7842 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
7843 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
7844 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
7845 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
7846 (aarch64_atomic_load_op_code): Delete.
7847 (aarch64_emit_atomic_load_op): Likewise.
7848 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
7849 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
7850 instead of aarch64_emit_atomic_load_op.
7851 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
7852 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
7853 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
7854 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
7855 character before the pattern name.
7856 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
7857 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
7858 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
7859 (aarch64_frecps<mode>): Likewise.
7860 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
7861 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
7862 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
7863 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
7864 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
7865
7866 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7867
7868 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
7869 Allow HFmode constants if TARGET_FP_F16INST.
7870
7871 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
7872
7873 PR target/86014
7874 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
7875 No longer check last store for clobber of address register.
7876
7877 2018-08-02 Martin Liska <mliska@suse.cz>
7878
7879 PR gcov-profile/86817
7880 * gcov.c (process_all_functions): New function.
7881 (main): Call it.
7882 (process_file): Move functions processing to
7883 process_all_functions.
7884
7885 2018-08-02 David Malcolm <dmalcolm@redhat.com>
7886
7887 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
7888 "const" to the "gimple *" and "rtx_insn *" parameters.
7889 * dumpfile.h (dump_user_location_t::dump_user_location_t):
7890 Likewise.
7891 (dump_location_t::dump_location_t): Likewise.
7892
7893 2018-08-01 Martin Sebor <msebor@redhat.com>
7894
7895 PR tree-optimization/86650
7896 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
7897 rather than a "gcall *". Directly pass the data of interest
7898 to percent_K_format, rather than building a temporary CALL_EXPR
7899 to hold it.
7900 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
7901 (gimple_fold_builtin_strncat): Adjust.
7902 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
7903 gcall* argument with gimple*.
7904 * gimple-ssa-warn-restrict.c (check_call): Same.
7905 (wrestrict_dom_walker::before_dom_children): Same.
7906 (builtin_access::builtin_access): Same.
7907 (check_bounds_or_overlap): Same
7908 (maybe_diag_overlap): Same.
7909 (maybe_diag_offset_bounds): Same.
7910 * tree-diagnostic.c (default_tree_printer): Move usage of
7911 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
7912 to this callsite.
7913 * tree-pretty-print.c (percent_K_format): Add argument.
7914 * tree-pretty-print.h: Add argument.
7915 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
7916 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
7917 (maybe_diag_stxncpy_trunc): Same.
7918 (handle_builtin_stxncpy): Same.
7919 (handle_builtin_strcat): Same.
7920
7921 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7922
7923 * match.pd: Optimise pointer range checks.
7924
7925 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7926
7927 PR tree-optimization/86758
7928 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
7929 to remove pattern statements.
7930
7931 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7932
7933 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
7934 result of dfs_enumerate_from when constructing stmt_vec_infos,
7935 instead of additionally calling get_loop_body.
7936
7937 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7938
7939 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
7940 parameter.
7941 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
7942 When creating an iv, assert that the step is not known to be zero.
7943 (vect_setup_realignment): Update call accordingly.
7944 * tree-vect-stmts.c (vectorizable_store): Likewise.
7945 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
7946
7947 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7948
7949 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
7950 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
7951 (vectorizable_reduction): Likewise.
7952 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
7953 (vect_detect_hybrid_slp_stmts): Likewise.
7954 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
7955
7956 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
7957
7958 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
7959 (wide_int_set_zero_nonzero_bits): ...this.
7960 (zero_nonzero_bits_from_vr): Rename to...
7961 (vrp_set_zero_nonzero_bits): ...this.
7962 (extract_range_from_multiplicative_op_1): Abstract wide int
7963 code...
7964 (wide_int_range_multiplicative_op): ...here.
7965 (extract_range_from_binary_expr_1): Extract wide int binary
7966 operations into their own functions.
7967 (wide_int_range_lshift): New.
7968 (wide_int_range_can_optimize_bit_op): New.
7969 (wide_int_range_shift_undefined_p): New.
7970 (wide_int_range_bit_xor): New.
7971 (wide_int_range_bit_ior): New.
7972 (wide_int_range_bit_and): New.
7973 (wide_int_range_trunc_mod): New.
7974 (extract_range_into_wide_ints): New.
7975 (vrp_shift_undefined_p): New.
7976 (extract_range_from_multiplicative_op): New.
7977 (vrp_can_optimize_bit_op): New.
7978 * tree-vrp.h (value_range::dump): New.
7979 (wide_int_range_multiplicative_op): New.
7980 (wide_int_range_lshift):New.
7981 (wide_int_range_shift_undefined_p): New.
7982 (wide_int_range_bit_xor): New.
7983 (wide_int_range_bit_ior): New.
7984 (wide_int_range_bit_and): New.
7985 (wide_int_range_trunc_mod): New.
7986 (zero_nonzero_bits_from_bounds): Rename to...
7987 (wide_int_set_zero_nonzero_bits): ...this.
7988 (zero_nonzero_bits_from_vr): Rename to...
7989 (vrp_set_zero_nonzero_bits): ...this.
7990 (range_easy_mask_min_max): Rename to...
7991 (wide_int_range_can_optimize_bit_op): this.
7992 * vr-values.c (simplify_bit_ops_using_ranges): Rename
7993 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
7994
7995 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7996
7997 * tree-vectorizer.h (vect_orig_stmt): New function.
7998 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
7999 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
8000 (vect_create_epilog_for_reduction): Likewise.
8001 (vectorizable_live_operation): Likewise.
8002 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8003 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
8004 * tree-vect-stmts.c (vectorizable_call): Likewise.
8005 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
8006
8007 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8008
8009 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
8010 argument.
8011 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
8012 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
8013 (vect_transform_loop): Likewise.
8014 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8015
8016 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8017
8018 * tree-vectorizer.h (vect_schedule_slp): Return void.
8019 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8020 (vect_schedule_slp): Likewise.
8021
8022 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8023
8024 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
8025 argument.
8026 (vect_transform_loop): Update calls accordingly. Schedule SLP
8027 instances before the main loop, if any exist.
8028
8029 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8030
8031 PR tree-optimization/86749
8032 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
8033 If the lhs is used in a COND_EXPR, check that it is being used
8034 as the "then" or "else" value.
8035
8036 2018-08-01 Tom de Vries <tdevries@suse.de>
8037
8038 PR target/86800
8039 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
8040 speculation_safe_value_not_needed.
8041
8042 2018-08-01 Richard Biener <rguenther@suse.de>
8043
8044 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
8045 as base and offset.
8046
8047 2018-08-01 Martin Liska <mliska@suse.cz>
8048
8049 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
8050 format how successful transformation is dumped.
8051 (gimple_mod_pow2_value_transform): Likewise.
8052 (gimple_mod_subtract_transform): Likewise.
8053 (gimple_stringops_transform): Likewise.
8054
8055 2018-08-01 Martin Liska <mliska@suse.cz>
8056
8057 PR value-prof/35543
8058 * value-prof.c (interesting_stringop_to_profile_p):
8059 Simplify the code and add BUILT_IN_MEMMOVE.
8060 (gimple_stringops_transform): Likewise.
8061
8062 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
8063
8064 * config/aarch64/aarch64-simd.md
8065 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
8066 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
8067 use GPI iterator instead of SI mode.
8068
8069 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8070
8071 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
8072 rs6000_speculation_barrier.
8073 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
8074 new barrier pattern name.
8075
8076 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8077
8078 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
8079 (speculation_barrier): New insn.
8080
8081 2018-08-01 Richard Biener <rguenther@suse.de>
8082
8083 PR bootstrap/86724
8084 * graphite.h: Include isl/id.h and isl/space.h to allow build
8085 with ISL 0.20.
8086
8087 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
8088
8089 PR target/86651
8090 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
8091 mode for COFF targets.
8092 * defaults.h (TARGET_COFF): Define.
8093 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
8094 TARGET_COFF): Define.
8095 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
8096 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
8097 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
8098
8099 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8100
8101 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
8102 * gimple-streamer-out.c (output_bb): Save it.
8103 * lto-streamer-in.c (input_struct_function_base): Restore
8104 instance discriminator if available. Create map on demand.
8105 * lto-streamer-out.c (output_struct_function_base): Save it if
8106 available.
8107 * final.c (decl_to_instance_map): Document LTO strategy.
8108
8109 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8110 Olivier Hainque <hainque@adacore.com>
8111
8112 * debug.h (decl_to_instance_map_t): New type.
8113 (decl_to_instance_map): Declare.
8114 (maybe_create_decl_to_instance_map): New inline function.
8115 * final.c (bb_discriminator, last_bb_discriminator): New statics,
8116 to track basic block discriminators.
8117 (final_start_function_1): Initialize them.
8118 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
8119 bb_discriminator.
8120 (decl_to_instance_map): New variable.
8121 (map_decl_to_instance, maybe_set_discriminator): New functions.
8122 (notice_source_line): Set discriminator.
8123
8124 2018-07-31 Ian Lance Taylor <iant@golang.org>
8125
8126 * targhooks.c (default_have_speculation_safe_value): Add
8127 ATTRIBUTE_UNUSED.
8128
8129 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8130
8131 * dump-context.h: Include "pretty-print.h".
8132 (dump_context::refresh_dumps_are_enabled): New decl.
8133 (dump_context::emit_item): New decl.
8134 (class dump_context): Add fields "m_test_pp" and
8135 "m_test_pp_flags".
8136 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8137 (temp_dump_context::get_dumped_text): New decl.
8138 (class temp_dump_context): Add field "m_pp".
8139 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
8140 (dump_context::refresh_dumps_are_enabled): ...and add a test for
8141 m_test_pp.
8142 (set_dump_file): Update for above change.
8143 (set_alt_dump_file): Likewise.
8144 (dump_loc): New overload, taking a pretty_printer *.
8145 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
8146 to any test pretty-printer.
8147 (make_item_for_dump_gimple_stmt): New function, adapted from
8148 optinfo::add_gimple_stmt.
8149 (dump_context::dump_gimple_stmt): Call it, and use the result,
8150 eliminating the direct usage of dump_file and alt_dump_file in
8151 favor of indirectly using them via emit_item.
8152 (make_item_for_dump_gimple_expr): New function, adapted from
8153 optinfo::add_gimple_expr.
8154 (dump_context::dump_gimple_expr): Call it, and use the result,
8155 eliminating the direct usage of dump_file and alt_dump_file in
8156 favor of indirectly using them via emit_item.
8157 (make_item_for_dump_generic_expr): New function, adapted from
8158 optinfo::add_tree.
8159 (dump_context::dump_generic_expr): Call it, and use the result,
8160 eliminating the direct usage of dump_file and alt_dump_file in
8161 favor of indirectly using them via emit_item.
8162 (make_item_for_dump_printf_va): New function, adapted from
8163 optinfo::add_printf_va.
8164 (make_item_for_dump_printf): New function.
8165 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
8166 and use the result, eliminating the direct usage of dump_file and
8167 alt_dump_file in favor of indirectly using them via emit_item.
8168 (make_item_for_dump_dec): New function.
8169 (dump_context::dump_dec): Call it, and use the result,
8170 eliminating the direct usage of dump_file and alt_dump_file in
8171 favor of indirectly using them via emit_item.
8172 (make_item_for_dump_symtab_node): New function, adapted from
8173 optinfo::add_symtab_node.
8174 (dump_context::dump_symtab_node): Call it, and use the result,
8175 eliminating the direct usage of dump_file and alt_dump_file in
8176 favor of indirectly using them via emit_item.
8177 (dump_context::begin_scope): Reimplement, avoiding direct usage
8178 of dump_file and alt_dump_file in favor of indirectly using them
8179 via emit_item.
8180 (dump_context::emit_item): New member function.
8181 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8182 Set up test pretty-printer on the underlying context. Call
8183 refresh_dumps_are_enabled.
8184 (temp_dump_context::~temp_dump_context): Call
8185 refresh_dumps_are_enabled.
8186 (temp_dump_context::get_dumped_text): New member function.
8187 (selftest::verify_dumped_text): New function.
8188 (ASSERT_DUMPED_TEXT_EQ): New macro.
8189 (selftest::test_capture_of_dump_calls): Run all tests twice, with
8190 and then without optinfo enabled. Add uses of
8191 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
8192 * dumpfile.h: Update comment for the dump_* API.
8193 * optinfo-emit-json.cc
8194 (selftest::test_building_json_from_dump_calls): Update for new
8195 param for temp_dump_context ctor.
8196 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
8197 and "m_owned" field.
8198 (optinfo_item::~optinfo_item): Likewise.
8199 (optinfo::add_item): New member function.
8200 (optinfo::emit): Update comment.
8201 (optinfo::add_string): Delete.
8202 (optinfo::add_printf): Delete.
8203 (optinfo::add_printf_va): Delete.
8204 (optinfo::add_gimple_stmt): Delete.
8205 (optinfo::add_gimple_expr): Delete.
8206 (optinfo::add_tree): Delete.
8207 (optinfo::add_symtab_node): Delete.
8208 (optinfo::add_dec): Delete.
8209 * optinfo.h (class dump_context): New forward decl.
8210 (optinfo::add_item): New decl.
8211 (optinfo::add_string): Delete.
8212 (optinfo::add_printf): Delete.
8213 (optinfo::add_printf_va): Delete.
8214 (optinfo::add_gimple_stmt): Delete.
8215 (optinfo::add_gimple_expr): Delete.
8216 (optinfo::add_tree): Delete.
8217 (optinfo::add_symtab_node): Delete.
8218 (optinfo::add_dec): Delete.
8219 (optinfo::add_poly_int): Delete.
8220 (optinfo_item::optinfo_item): Remove "owned" param.
8221 (class optinfo_item): Remove field "m_owned".
8222
8223 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
8224
8225 PR middle-end/86705
8226 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
8227 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
8228 requested variable alignment.
8229 (expand_one_ssa_partition): Likewise.
8230 (expand_one_var): Likewise.
8231
8232 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8233
8234 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
8235 to speculation_safe_value_not_needed.
8236
8237 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8238
8239 * targhooks.h (speculation_safe_value_not_needed): New prototype.
8240 * targhooks.c (speculation_safe_value_not_needed): New function.
8241 * target.def (have_speculation_safe_value): Update documentation.
8242 * doc/tm.texi: Regenerated.
8243
8244 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8245
8246 * config/aarch64/iterators.md (ALLI_TI): New iterator.
8247 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
8248 expand.
8249 (despeculate_copy<ALLI:mode>_insn): New insn.
8250 (despeculate_copyti_insn): New insn.
8251 (despeculate_simple<ALLI:mode>): New insn
8252 (despeculate_simpleti): New insn.
8253 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
8254 function.
8255 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
8256 aarch64_speculation_safe_value.
8257 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
8258
8259 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8260
8261 * config/aarch64/aarch64-speculation.cc: New file.
8262 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
8263 before pass_reorder_blocks.
8264 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
8265 prototype.
8266 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
8267 X14 and X15 when tracking speculation.
8268 * config/aarch64/aarch64.md (register name constants): Add
8269 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
8270 (unspec): Add UNSPEC_SPECULATION_TRACKER.
8271 (speculation_barrier): New insn attribute.
8272 (cmp<mode>): Allow SP in comparisons.
8273 (speculation_tracker): New insn.
8274 (speculation_barrier): Add speculation_barrier attribute.
8275 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
8276 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
8277 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
8278
8279 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8280
8281 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
8282 aarch64_track_speculation is true.
8283 (tb<optab><mode>1): Likewise.
8284 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
8285 generate CB[N]Z when tracking speculation.
8286 (aarch64_split_compare_and_swap): Likewise.
8287 (aarch64_split_atomic_op): Likewise.
8288
8289 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8290
8291 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
8292
8293 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8294
8295 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
8296 (speculation_barrier): New insn.
8297
8298 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8299
8300 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
8301 * config/arm/arm.md (speculation_barrier): New expand.
8302 (speculation_barrier_insn): New pattern.
8303
8304 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8305
8306 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
8307 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
8308 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
8309 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
8310 list.
8311 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
8312 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
8313 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
8314 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
8315 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
8316 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
8317 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
8318 * builtins.c (expand_speculation_safe_value): New function.
8319 (expand_builtin): Call it.
8320 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
8321 * doc/extend.texi: Document __builtin_speculation_safe_value.
8322 * doc/md.texi: Document "speculation_barrier" pattern.
8323 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
8324 TARGET_HAVE_SPECULATION_SAFE_VALUE.
8325 * doc/tm.texi: Regenerated.
8326 * target.def (have_speculation_safe_value, speculation_safe_value): New
8327 hooks.
8328 * targhooks.c (default_have_speculation_safe_value): New function.
8329 (default_speculation_safe_value): New function.
8330 * targhooks.h (default_have_speculation_safe_value): Add prototype.
8331 (default_speculation_safe_value): Add prototype.
8332
8333 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8334
8335 * dump-context.h (dump_context::dump_loc): New decl.
8336 * dumpfile.c (dump_context::dump_loc): New member function.
8337 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
8338 and dump_gimple_stmt.
8339 (dump_context::dump_gimple_expr_loc): Likewise, using
8340 dump_gimple_expr.
8341 (dump_context::dump_generic_expr_loc): Likewise, using
8342 dump_generic_expr.
8343 (dump_context::dump_printf_loc_va): Likewise, using
8344 dump_printf_va.
8345 (dump_context::begin_scope): Explicitly using the global function
8346 "dump_loc", rather than the member function.
8347
8348 2018-07-31 Martin Sebor <msebor@redhat.com>
8349
8350 PR tree-optimization/86741
8351 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
8352
8353 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
8354
8355 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
8356 depend on whether prefetch instructions will be emitted or not.
8357 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
8358 will be emitted or not.
8359 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
8360 (TARGET_SETMEM_PFD): New macros.
8361
8362 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8363
8364 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
8365 (NULL_STMT_VEC_INFO): Delete.
8366 (stmt_vec_info::operator*): Likewise.
8367 (stmt_vec_info::operator gimple *): Likewise.
8368 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
8369 of NULL_STMT_VEC_INFO.
8370 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
8371 (vect_reassociating_reduction_p): Likewise.
8372 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
8373 (vectorizable_store): Likewise.
8374 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
8375 (vec_info::free_stmt_vec_infos): Likewise.
8376
8377 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8378
8379 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
8380 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
8381
8382 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8383
8384 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
8385 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8386 (vec_info::free_stmt_vec_info): New private member functions.
8387 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
8388 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
8389 * tree-parloops.c (gather_scalar_reductions): Remove calls to
8390 set_stmt_vec_info_vec and free_stmt_vec_infos.
8391 * tree-vect-loop.c (_loop_vec_info): Remove call to
8392 set_stmt_vec_info_vec.
8393 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
8394 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
8395 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
8396 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8397 (vec_info::free_stmt_vec_info): ...these new functions. Remove
8398 assignments in {vec_info::,}new_stmt_vec_info that are redundant
8399 with the clearing in the xcalloc.
8400 (stmt_vec_info_vec): Delete.
8401 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
8402 (vectorize_loops): Likewise.
8403 (vec_info::~vec_info): Remove argument from call to
8404 free_stmt_vec_infos.
8405 (vec_info::add_stmt): Remove vinfo argument from call to
8406 new_stmt_vec_info.
8407
8408 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8409
8410 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
8411 rather than a gimple stmt.
8412 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
8413 information for pattern statements when passed the original
8414 statement; instead wait to be passed the pattern statement itself.
8415 Don't call set_vinfo_for_stmt here.
8416 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
8417 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
8418 stmt_vec_infos here.
8419 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
8420 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
8421 stmt_vec_infos entry.
8422
8423 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8424
8425 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
8426 * tree-vectorizer.c (vec_info::replace_stmt): New function.
8427 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
8428 * tree-vect-stmts.c (vectorizable_call): Likewise.
8429 (vectorizable_simd_clone_call): Likewise.
8430
8431 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8432
8433 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
8434 * tree-vectorizer.c (vec_info::remove_stmt): New function.
8435 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
8436 * tree-vect-loop.c (vect_transform_loop): Likewise.
8437 * tree-vect-slp.c (vect_schedule_slp): Likewise.
8438 * tree-vect-stmts.c (vect_remove_stores): Likewise.
8439
8440 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8441
8442 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
8443 (vect_dr_stmt): Delete.
8444 * tree-vectorizer.c (vec_info::lookup_dr): New function.
8445 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
8446 of DR_VECT_AUX.
8447 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
8448 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
8449 (vect_verify_datarefs_alignment, vect_peeling_supportable)
8450 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8451 (vect_analyze_data_refs): Likewise.
8452 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
8453 argument.
8454 (vect_find_same_alignment_drs): Likewise.
8455 (vect_slp_analyze_node_dependences): Update calls accordingly.
8456 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8457 instead of DR_VECT_AUX.
8458 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
8459 of a vector data references. Use vec_info::lookup_dr instead of
8460 DR_VECT_AUX.
8461 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
8462 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8463 instead of DR_VECT_AUX.
8464
8465 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8466
8467 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
8468 dr_vec_info.
8469 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8470 accordingly.
8471 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8472 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
8473 (vect_gen_prolog_loop_niters): Likewise.
8474
8475 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8476
8477 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
8478 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
8479 (vect_known_alignment_in_bytes, vect_dr_behavior)
8480 (vect_get_scalar_dr_size): Take references as dr_vec_infos
8481 instead of data_references. Update calls to other routines for
8482 which the same change has been made.
8483 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
8484 dr_vec_infos instead of stmt_vec_infos.
8485 (vect_analyze_data_ref_dependence): Update call accordingly.
8486 (vect_slp_analyze_data_ref_dependence)
8487 (vect_record_base_alignments): Use DR_VECT_AUX.
8488 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
8489 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
8490 (vector_alignment_reachable_p, vect_get_data_access_cost)
8491 (vect_peeling_supportable, vect_analyze_group_access_1)
8492 (vect_analyze_group_access, vect_analyze_data_ref_access)
8493 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
8494 (vect_compile_time_alias, vect_small_gap_p)
8495 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
8496 (vect_supportable_dr_alignment): Take references as dr_vec_infos
8497 instead of data_references. Update calls to other routines for
8498 which the same change has been made.
8499 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
8500 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8501 (vect_slp_analyze_and_verify_node_alignment)
8502 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8503 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8504 (vect_setup_realignment): Use dr_vec_infos. Update calls after
8505 above changes.
8506 (_vect_peel_info::dr): Replace with...
8507 (_vect_peel_info::dr_info): ...this new field.
8508 (vect_peeling_hash_get_most_frequent)
8509 (vect_peeling_hash_choose_best_peeling): Update accordingly.
8510 (vect_peeling_hash_get_lowest_cost):
8511 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
8512 routines for which the same change has been made.
8513 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
8514 data_reference.
8515 * tree-vect-loop-manip.c (get_misalign_in_elems)
8516 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
8517 above changes.
8518 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8519 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
8520 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
8521 (get_group_load_store_type, get_negative_load_store_type)
8522 (vect_get_data_ptr_increment, vectorizable_store)
8523 (vectorizable_load): Likewise.
8524 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
8525 Update calls to other routines for which the same change has been made.
8526
8527 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8528
8529 * tree-vectorizer.h (vec_info::move_dr): New member function.
8530 (dataref_aux): Rename to...
8531 (dr_vec_info): ...this and add "dr" and "stmt" fields.
8532 (_stmt_vec_info::dr_aux): Update accordingly.
8533 (_stmt_vec_info::data_ref_info): Delete.
8534 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
8535 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
8536 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
8537 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
8538 of data_ref.
8539 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
8540 (STMT_VINFO_DR_INFO): New macro.
8541 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
8542 (set_dr_misalignment): Update after rename of dataref_aux.
8543 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
8544 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
8545 initialization of STMT_VINFO_DATA_REF.
8546 * tree-vectorizer.c (vec_info::move_dr): New function.
8547 * tree-vect-patterns.c (vect_recog_bool_pattern)
8548 (vect_recog_mask_conversion_pattern)
8549 (vect_recog_gather_scatter_pattern): Use it.
8550 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
8551 the "dr" and "stmt" fields of dr_vec_info instead of
8552 STMT_VINFO_DATA_REF.
8553
8554 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8555
8556 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
8557 (is_pattern_stmt_p): Use it.
8558 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
8559 on pattern statements.
8560
8561 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8562
8563 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
8564 original stmt as a stmt_vec_info rather than a gimple stmt.
8565 (vect_pattern_recog_1): Take the statement directly as a
8566 stmt_vec_info, rather than via a gimple_stmt_iterator.
8567 Update call to vect_mark_pattern_stmts.
8568 (vect_pattern_recog): Update calls accordingly.
8569
8570 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8571
8572 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
8573 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
8574 a vect_def_type for the first argument.
8575 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
8576 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
8577 operand if it isn't defined by a vectorized statement.
8578 (vect_build_gather_load_calls): Remove the mask_dt argument and
8579 update calls to vect_get_vec_def_for_stmt_copy.
8580 (vectorizable_bswap): Likewise the dt argument.
8581 (vectorizable_call): Update calls to vectorizable_bswap and
8582 vect_get_vec_def_for_stmt_copy.
8583 (vectorizable_simd_clone_call, vectorizable_assignment)
8584 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
8585 (vectorizable_comparison): Update calls to
8586 vect_get_vec_def_for_stmt_copy.
8587 (vectorizable_store): Likewise. Remove now-unnecessary calls to
8588 vect_is_simple_use.
8589 (vect_get_loop_based_defs): Remove dt argument and update call
8590 to vect_get_vec_def_for_stmt_copy.
8591 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
8592 and vect_get_vec_def_for_stmt_copy.
8593 (vectorizable_load): Update calls to vect_build_gather_load_calls
8594 and vect_get_vec_def_for_stmt_copy.
8595 * tree-vect-loop.c (vect_create_epilog_for_reduction)
8596 (vectorizable_reduction, vectorizable_live_operation): Update calls
8597 to vect_get_vec_def_for_stmt_copy.
8598
8599 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8600
8601 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
8602 and gimple stmt arguments with a stmt_vec_info.
8603 (vect_record_base_alignments): Update calls accordingly.
8604 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
8605 and gimple stmt arguments with a stmt_vec_info.
8606 (vect_build_slp_tree_1): Remove vinfo argument and update call
8607 to vect_record_max_nunits.
8608 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
8609 and vect_record_max_nunits.
8610
8611 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8612
8613 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
8614 file and take a stmt_vec_info instead of a gimple stmt.
8615 (supportable_widening_operation, vect_finish_replace_stmt)
8616 (vect_finish_stmt_generation, vect_get_store_rhs)
8617 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
8618 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
8619 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
8620 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
8621 (vect_create_data_ref_ptr, bump_vector_ptr)
8622 (vect_permute_store_chain, vect_setup_realignment)
8623 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
8624 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
8625 (vectorizable_reduction, vectorizable_induction)
8626 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
8627 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
8628 than gimple stmts as arguments.
8629 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
8630 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
8631 (can_group_stmts_p, vect_check_gather_scatter)
8632 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8633 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
8634 (vect_permute_load_chain, vect_shift_permute_load_chain)
8635 (vect_transform_grouped_load)
8636 (vect_record_grouped_load_vectors): Likewise.
8637 * tree-vect-loop.c (vect_fixup_reduc_chain)
8638 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
8639 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
8640 (vectorizable_reduction, vectorizable_induction)
8641 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
8642 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
8643 (vect_get_load_store_mask): Likewise.
8644 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
8645 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
8646 * tree-vect-stmts.c (vect_mark_relevant)
8647 (is_simple_and_all_uses_invariant)
8648 (exist_non_indexing_operands_for_use_p, process_use)
8649 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
8650 (vect_get_vec_def_for_operand, vect_get_vec_defs)
8651 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
8652 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
8653 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
8654 (get_negative_load_store_type, get_load_store_type)
8655 (vect_check_load_store_mask, vect_check_store_rhs)
8656 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
8657 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8658 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8659 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8660 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
8661 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
8662 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
8663 (supportable_widening_operation): Likewise.
8664
8665 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8666
8667 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
8668 a stmt_vec_info instead of a gcall.
8669 (vect_check_gather_scatter): Update call accordingly.
8670 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
8671 of a gphi.
8672 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
8673 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
8674 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
8675 instead of a gimple stmt.
8676 (vect_transform_loop): Update calls accordingly.
8677 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
8678 stmt_vec_infos instead of gimple stmts.
8679 (vect_analyze_slp_instance): Update use accordingly.
8680 * tree-vect-stmts.c (read_vector_array, write_vector_array)
8681 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
8682 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
8683 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
8684 (vect_gen_widened_results_half, vect_get_loop_based_defs)
8685 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
8686 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
8687 down to subroutines.
8688
8689 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8690
8691 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
8692 of the worklist from a vector of gimple stmts to a vector of
8693 stmt_vec_infos.
8694 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8695 (vect_mark_stmts_to_be_vectorized): Likewise
8696
8697 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8698
8699 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
8700 statement before passing it to vect_analyze_stmt.
8701 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
8702 the chain of phi vector definitions. Track the exit phi via its
8703 stmt_vec_info.
8704 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
8705 STMT_VINFO_REDUC_DEF.
8706 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
8707 stmt_vec_infos to handle the statement chains.
8708 (vect_get_slp_defs): Record the first statement in the node
8709 using a stmt_vec_info.
8710 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
8711 statements here and pass their stmt_vec_info down to subroutines.
8712 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
8713 down to vect_finish_stmt_generation.
8714 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
8715 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
8716 stmt_vec_infos to subroutines.
8717 (vect_remove_stores): Use stmt_vec_infos to handle the statement
8718 chains.
8719
8720 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8721
8722 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
8723 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
8724 (vect_permute_store_chain, vect_setup_realignment)
8725 (vect_permute_load_chain, vect_shift_permute_load_chain)
8726 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
8727 stmts internally, and when passing values to other vectorizer routines.
8728 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8729 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
8730 (vect_analyze_loop_operations, get_initial_def_for_reduction)
8731 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
8732 (vectorizable_reduction, vectorizable_induction)
8733 (vectorizable_live_operation, vect_transform_loop_stmt)
8734 (vect_transform_loop): Likewise.
8735 * tree-vect-patterns.c (vect_reassociating_reduction_p)
8736 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
8737 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
8738 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8739 (vect_slp_analyze_node_operations_1): Likewise.
8740 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8741 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
8742 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
8743 (vect_finish_stmt_generation_1, get_group_load_store_type)
8744 (get_load_store_type, vect_build_gather_load_calls)
8745 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8746 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8747 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8748 (vectorizable_store, vectorizable_load, vectorizable_condition)
8749 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
8750 (supportable_widening_operation): Likewise.
8751 (vect_get_vector_types_for_stmt): Likewise.
8752 * tree-vectorizer.h (vect_dr_behavior): Likewise.
8753
8754 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8755
8756 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8757 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
8758 (vect_permute_store_chain, vect_permute_load_chain)
8759 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
8760 repeated stmt_vec_info lookups.
8761 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8762 (vect_update_ivs_after_vectorizer): Likewise.
8763 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
8764 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
8765 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
8766 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8767 (vect_bb_slp_scalar_cost): Likewise.
8768 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
8769
8770 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8771
8772 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
8773 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
8774 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
8775 to get gassigns and gcalls, rather than operating on generc gimple
8776 stmts.
8777 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
8778 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
8779 (vectorizable_load, vect_analyze_stmt): Likewise.
8780 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
8781
8782 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8783
8784 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
8785 return stmt_vec_infos rather than gimple stmts. Do not accept
8786 null arguments.
8787 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
8788 of a gimple stmt.
8789 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8790 Update use of get_later_stmt.
8791 (vect_get_constant_vectors): Update call accordingly.
8792 (vect_schedule_slp_instance): Likewise
8793 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
8794 (vect_slp_analyze_instance_dependence): Likewise.
8795 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
8796
8797 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8798
8799 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
8800 (stmt_info_for_cost::stmt_info): ...this new field.
8801 (add_stmt_costs): Update accordingly.
8802 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
8803 (vect_get_known_peeling_cost): Likewise.
8804 (vect_estimate_min_profitable_iters): Likewise.
8805 * tree-vect-stmts.c (record_stmt_cost): Likewise.
8806
8807 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8808
8809 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
8810 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8811 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8812 accordingly.
8813 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
8814
8815 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8816
8817 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
8818 a gimple stmt to a stmt_vec_info.
8819 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
8820
8821 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8822
8823 * tree-vectorizer.h (vec_info::grouped_stores): Change from
8824 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8825 (_loop_vec_info::reduction_chains): Likewise.
8826 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
8827 accordingly.
8828 * tree-vect-slp.c (vect_analyze_slp): Likewise.
8829
8830 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8831
8832 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
8833 a gimple stmt to a stmt_vec_info.
8834 (_stmt_vec_info::next_element): Likewise.
8835 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
8836 (vect_slp_analyze_and_verify_node_alignment)
8837 (vect_analyze_group_access_1, vect_analyze_group_access)
8838 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
8839 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
8840 (vect_supportable_dr_alignment): Update accordingly.
8841 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
8842 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
8843 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
8844 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
8845 * tree-vect-slp.c (vect_build_slp_tree_1)
8846 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
8847 (vect_split_slp_store_group, vect_analyze_slp_instance)
8848 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
8849 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
8850 (get_group_load_store_type, get_load_store_type)
8851 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
8852 (vect_transform_stmt, vect_remove_stores): Likewise.
8853
8854 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8855
8856 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
8857 than a gimple stmt.
8858 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8859 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
8860 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
8861 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
8862 (vector_alignment_reachable_p, vect_get_data_access_cost)
8863 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
8864 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
8865 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8866 (vect_analyze_group_access_1, vect_analyze_group_access)
8867 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
8868 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
8869 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
8870 result of vect_dr_stmt and use the stmt_vec_info instead of
8871 the associated gimple stmt.
8872 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
8873 (vect_gen_prolog_loop_niters): Likewise.
8874 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8875
8876 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8877
8878 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
8879 to a vec<stmt_vec_info>.
8880 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
8881 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
8882 vec<stmt_vec_info>.
8883 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
8884 to a vec<stmt_vec_info>.
8885 (bst_traits::value_type, bst_traits::value_type): Likewise.
8886 (bst_traits::hash): Update accordingly.
8887 (vect_get_and_check_slp_defs): Change the stmts parameter from
8888 a vec<gimple *> to a vec<stmt_vec_info>.
8889 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
8890 (vect_build_slp_tree): Likewise.
8891 (vect_build_slp_tree_2): Likewise. Update uses of
8892 SLP_TREE_SCALAR_STMTS.
8893 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
8894 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
8895 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
8896 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
8897 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
8898 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
8899 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
8900 (vect_get_constant_vectors, vect_get_slp_defs)
8901 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
8902 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
8903 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
8904 instead of gimple stmts.
8905 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
8906 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
8907 (vect_slp_analyze_instance_dependence): Update uses of
8908 SLP_TREE_SCALAR_STMTS.
8909 (vect_slp_analyze_and_verify_node_alignment): Likewise.
8910 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
8911 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
8912 (get_initial_defs_for_reduction): Likewise.
8913 (vect_create_epilog_for_reduction): Likewise.
8914 (vectorize_fold_left_reduction): Likewise.
8915 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
8916 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
8917 (can_vectorize_live_stmts): Likewise.
8918
8919 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8920
8921 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
8922 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8923 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
8924 than gimple stmts.
8925 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
8926 of a gimple stmt.
8927 (gather_scalar_reductions): Update after above interface changes.
8928 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
8929 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
8930 than gimple stmts.
8931 (vect_force_simple_reduction): Likewise.
8932 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
8933 LOOP_VINFO_REDUCTIONS.
8934 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8935
8936 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8937
8938 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
8939 a gimple stmt to a stmt_vec_info.
8940 * tree-vect-loop.c (vect_active_double_reduction_p)
8941 (vect_force_simple_reduction, vectorizable_reduction): Update
8942 accordingly.
8943
8944 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8945
8946 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
8947 vec<gimple *> to a vec<stmt_vec_info>.
8948 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
8949 the reduction_phis argument from a vec<gimple *> to a
8950 vec<stmt_vec_info>.
8951 (vectorizable_reduction): Likewise the phis local variable that
8952 is passed to vect_create_epilog_for_reduction. Update for new type
8953 of SLP_TREE_VEC_STMTS.
8954 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
8955 (vectorizable_live_operation): Likewise.
8956 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
8957 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
8958
8959 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8960
8961 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
8962 a gimple stmt to a stmt_vec_info.
8963 (vectorizable_condition, vectorizable_live_operation)
8964 (vectorizable_reduction, vectorizable_induction): Pass back the
8965 vectorized statement as a stmt_vec_info.
8966 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
8967 use of STMT_VINFO_VEC_STMT.
8968 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
8969 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
8970 as stmt_vec_infos rather than gimple stmts.
8971 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
8972 to a stmt_vec_info.
8973 (vectorizable_live_operation): Likewise.
8974 (vectorizable_reduction, vectorizable_induction): Likewise,
8975 updating use of STMT_VINFO_VEC_STMT.
8976 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
8977 of STMT_VINFO_VEC_STMT.
8978 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
8979 (vectorizable_simd_clone_call, vectorizable_conversion)
8980 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8981 (vectorizable_store, vectorizable_load, vectorizable_condition)
8982 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
8983 from a gimple stmt to a stmt_vec_info.
8984 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
8985 pointer to a stmt_vec_info to the vectorizable_* routines.
8986
8987 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8988
8989 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
8990 a gimple stmt to a stmt_vec_info.
8991 (is_pattern_stmt_p): Update accordingly.
8992 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
8993 (vect_record_grouped_load_vectors): Likewise.
8994 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
8995 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
8996 (vect_model_reduction_cost): Likewise.
8997 (vect_create_epilog_for_reduction): Likewise.
8998 (vectorizable_reduction, vectorizable_induction): Likewise.
8999 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9000 Return the stmt_vec_info for the pattern statement.
9001 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
9002 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
9003 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9004 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
9005 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
9006 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
9007 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
9008 (free_stmt_vec_info, vect_is_simple_use): Likewise.
9009
9010 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9011
9012 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
9013 (vect_finish_stmt_generation): Likewise.
9014 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9015 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
9016 (vect_build_gather_load_calls): Use the return value of the above
9017 functions instead of a separate call to vinfo_for_stmt. Use narrow
9018 scopes for the input gimple stmt and wider scopes for the associated
9019 stmt_vec_info. Use vec_info::lookup_def when setting these
9020 stmt_vec_infos from an SSA_NAME definition.
9021 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
9022 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
9023 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
9024 (vectorizable_store, vectorizable_load, vectorizable_condition)
9025 (vectorizable_comparison): Likewise.
9026 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
9027 (vectorizable_reduction): Likewise.
9028
9029 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9030
9031 * tree-vectorizer.h (vect_is_simple_use): Add an optional
9032 stmt_vec_info * parameter before the optional gimple **.
9033 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9034 (process_use, vect_get_vec_def_for_operand_1): Update callers.
9035 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
9036 * tree-vect-loop.c (vectorizable_reduction): Likewise.
9037 (vectorizable_live_operation): Likewise.
9038 * tree-vect-patterns.c (type_conversion_p): Likewise.
9039 (vect_look_through_possible_promotion): Likewise.
9040 (vect_recog_rotate_pattern): Likewise.
9041 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
9042
9043 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9044
9045 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
9046 a typedef to a wrapper class.
9047 (NULL_STMT_VEC_INFO): New macro.
9048 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
9049 (stmt_vec_info::operator*): New function.
9050 (stmt_vec_info::operator gimple *): Likewise.
9051 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
9052 (add_stmt_costs): Likewise.
9053 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
9054 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
9055 (vect_get_known_peeling_cost): Likewise.
9056 (vect_estimate_min_profitable_iters): Likewise.
9057 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9058 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
9059 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
9060 (vectorizable_store, free_stmt_vec_infos): Likewise.
9061 (new_stmt_vec_info): Change return type of xcalloc to
9062 _stmt_vec_info *.
9063
9064 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9065
9066 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
9067 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
9068 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
9069 a single_imm_use-based sequence.
9070 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
9071
9072 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9073
9074 * tree-vectorizer.h (vec_info::lookup_def): Declare.
9075 * tree-vectorizer.c (vec_info::lookup_def): New function.
9076 * tree-vect-patterns.c (vect_get_internal_def): Use it.
9077 (vect_widened_op_tree): Likewise.
9078 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9079 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
9080 (vectorizable_reduction): Likewise.
9081 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
9082 of a gimple *.
9083 (vect_is_slp_reduction): Update calls accordingly. Use
9084 vec_info::lookup_def.
9085 (vect_is_simple_reduction): Likewise
9086 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
9087
9088 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9089
9090 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
9091 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
9092 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
9093 of vinfo_for_stmt.
9094 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
9095 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
9096 (vect_update_vf_for_slp, vect_analyze_loop_operations)
9097 (vect_is_slp_reduction, vectorizable_induction)
9098 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
9099 * tree-vect-patterns.c (vect_init_pattern_stmt):
9100 (vect_determine_min_output_precision_1, vect_determine_precisions)
9101 (vect_pattern_recog): Likewise.
9102 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
9103 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
9104 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
9105 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9106 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
9107 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
9108 info field from a loop to a loop_vec_info.
9109
9110 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9111
9112 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
9113 (vec_info::add_stmt): Declare.
9114 * tree-vectorizer.c (vec_info::add_stmt): New function.
9115 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
9116 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
9117 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
9118 (vectorizable_induction): Likewise.
9119 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
9120 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9121 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
9122 (vectorizable_load): Likewise.
9123 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9124 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
9125 (vect_recog_gather_scatter_pattern): Likewise.
9126 (append_pattern_def_seq): Likewise. Remove a check that is
9127 performed by add_stmt itself.
9128
9129 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9130
9131 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
9132 which make_ssa_name was called with new_stmt before new_stmt
9133 had been created.
9134
9135 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9136
9137 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
9138 split out from...
9139 (vect_is_slp_reduction): ...here...
9140 (vect_is_simple_reduction): ...and here. Remove repetition of tests
9141 that are already known to be false.
9142
9143 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9144
9145 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
9146 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
9147 STMT_VINFO_NUM_SLP_USES when it's true.
9148 (vect_free_slp_instance): Add a final_p parameter and pass it to
9149 vect_free_slp_tree.
9150 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
9151 (vect_analyze_slp_instance): Likewise.
9152 (vect_slp_analyze_operations): Likewise.
9153 (vect_slp_analyze_bb_1): Likewise.
9154 * tree-vectorizer.c (vec_info): Likewise.
9155 * tree-vect-loop.c (vect_transform_loop): Likewise.
9156
9157 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9158
9159 * tree-vect-loop.c (vectorizable_reduction): Assert that the
9160 function is not called for second and subsequent members of
9161 a reduction group.
9162
9163 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9164
9165 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
9166 cases for nested loops from here to ...
9167 (vect_create_epilog_for_reduction): ...here. Only call
9168 vect_is_simple_use for inner-loop reductions.
9169
9170 2018-07-31 Martin Liska <mliska@suse.cz>
9171
9172 PR gcov-profile/85338
9173 PR gcov-profile/85350
9174 PR gcov-profile/85372
9175 * profile.c (struct location_triplet): New.
9176 (struct location_triplet_hash): Likewise.
9177 (output_location): Do not output a BB that
9178 is already recorded for a line.
9179 (branch_prob): Use streamed_locations.
9180
9181 2018-07-31 Martin Liska <mliska@suse.cz>
9182
9183 PR gcov-profile/85370
9184 * coverage.c (coverage_begin_function): Do not mark target
9185 clones as artificial functions.
9186
9187 2018-07-31 Martin Liska <mliska@suse.cz>
9188
9189 PR gcov-profile/83813
9190 PR gcov-profile/84758
9191 PR gcov-profile/85217
9192 PR gcov-profile/85332
9193 * profile.c (branch_prob): Do not record GOTO expressions
9194 for GIMPLE statements which locations are already streamed.
9195
9196 2018-07-31 Olivier Hainque <hainque@adacore.com>
9197
9198 * gcc.c (handle_spec_function): Accept a soft_matched_part
9199 argument, as do_spec_1. Pass it down to ...
9200 (eval_spec_function): Accept a soft_matched_part argument,
9201 and pass it down to ...
9202 (do_spec_2): Accept a soft_matched_part argument, and pass
9203 it down to do_spec_1.
9204 (do_spec_1): Pass soft_matched_part to handle_spec_function.
9205 (handle_braces): Update call to handle_spec_function.
9206 (driver::set_up_specs): Update calls to do_spec_2.
9207 (compare_debug_dump_opt_spec_function): Likewise.
9208 (compare_debug_self_opt_spec_function): Likewise.
9209
9210 2018-07-31 Olivier Hainque <hainque@adacore.com>
9211
9212 * common.opt (nolibc): New option.
9213 * doc/invoke.texi (Link Options): Document it.
9214 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
9215 * config/alpha/linux.h: Likewise.
9216 * config/arc/elf.h: Likewise.
9217 * config/arm/uclinux-elf.h: Likewise.
9218 * config/arm/unknown-elf.h: Likewise.
9219 * config/avr/avrlibc.h: Likewise.
9220 * config/bfin/bfin.h: Likewise.
9221 * config/bfin/linux.h: Likewise.
9222 * config/bfin/uclinux.h: Likewise.
9223 * config/darwin.h: Likewise.
9224 * config/darwin10.h: Likewise.
9225 * config/darwin12.h: Likewise.
9226 * config/gnu-user.h: Likewise.
9227 * config/lm32/uclinux-elf.h: Likewise.
9228 * config/pa/pa-hpux11.h: Likewise.
9229 * config/pa/pa64-hpux.h: Likewise.
9230 * config/sparc/sparc.h: Likewise.
9231
9232 2018-07-31 Olivier Hainque <hainque@adacore.com>
9233
9234 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
9235 undefined variables.
9236
9237 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9238
9239 PR target/86640
9240 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
9241 instead of GEN_INT.
9242
9243 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
9244
9245 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
9246 terminated string literal.
9247
9248 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9249
9250 PR rtl-optimization/85160
9251 * combine.c (is_just_move): New function.
9252 (try_combine): Allow combining two instructions into two if neither of
9253 the original instructions was a move.
9254
9255 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
9256
9257 PR target/86673
9258 * doc/extend.texi (Global Register Variables): Discourage use of type
9259 qualifiers.
9260 (Local Register Variables): Likewise.
9261
9262 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
9263
9264 PR tree-optimization/86506
9265 * hwint.h (ceil_log2): Resync with hwint.c implementation.
9266
9267 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
9268
9269 PR target/86547
9270 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
9271 hard_regno, make sure no insn between `from` and `to` clobbers it.
9272
9273 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
9274 Tom de Vries <tdevries@suse.de>
9275
9276 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
9277 (PTX_DEFAULT_RUNTIME_DIM): ... this.
9278 (nvptx_goacc_validate_dims): Set default worker and gang dims to
9279 PTX_DEFAULT_RUNTIME_DIM.
9280 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
9281
9282 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
9283
9284 * config/pa/pa.c (pa_output_addr_vec): Align address table.
9285 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
9286 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
9287
9288 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
9289
9290 * config/rs6000/constraints.md (wG constraint): Delete, no longer
9291 used.
9292 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
9293 predicate to reflect toc fusion has been deleted.
9294 (toc_fusion_mem_raw): Delete, no longer used.
9295 (toc_fusion_mem_wrapped): Likewise.
9296 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
9297 fusion mask bit.
9298 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
9299 Delete, no longer used.
9300 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
9301 meant to be used for toc fusion.
9302 (rs6000_debug_print_mode): Delete toc fusion debugging.
9303 (rs6000_debug_reg_global): Likewise.
9304 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
9305 fusion and secondary reload support that were never used.
9306 (rs6000_option_override_internal): Delete TOC fusion, that was only
9307 partially defined, and it did not work unless you also used the
9308 -mcmodel= switch.
9309 (rs6000_legitimate_address_p): Delete TOC fusion support.
9310 (rs6000_opt_masks): Likewise.
9311 (fusion_wrap_memory_address): Delete function, no longer used.
9312 (fusion_split_address); Delete TOC fusion support.
9313 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
9314 longer used with toc fusion being deleted.
9315 (TARGET_TOC_FUSION_FP): Likewise.
9316 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
9317 UNSPEC.
9318 (toc fusion spliter): Delete TOC fusion support.
9319 (toc_fusionload_<mode>): Likewise.
9320 (toc_fusionload_di): Likewise.
9321 (fusion_gpr_load_<mode>): Delete generator function, this insn no
9322 longer needs to be named. Rename predicate to delete TOC fusion.
9323 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9324 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9325 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9326 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9327 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
9328
9329 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
9330
9331 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
9332 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
9333 __int128 in built-in function prototypes.
9334 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
9335 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
9336
9337 2018-07-27 Martin Sebor <msebor@redhat.com>
9338
9339 PR tree-optimization/86696
9340 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
9341 types, including enums.
9342 (handle_char_store): Be prepared for the above function to fail.
9343
9344 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
9345
9346 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
9347 when optimization level is lower than 2 or optimize for size.
9348
9349 2018-07-26 Martin Sebor <msebor@redhat.com>
9350
9351 PR tree-optimization/86043
9352 PR tree-optimization/86042
9353 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
9354 (get_string_cst_length): Rename...
9355 (get_min_string_length): ...to this. Add argument.
9356 (handle_char_store): Extend to handle multi-character stores by
9357 MEM_REF.
9358 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
9359 * tree.h (initializer_zerop): Add argument.
9360
9361 2018-07-26 Jakub Jelinek <jakub@redhat.com>
9362
9363 PR middle-end/86660
9364 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
9365 declare target to variables if they have always,{to,from,tofrom} map
9366 kinds.
9367
9368 2018-07-26 Martin Liska <mliska@suse.cz>
9369
9370 PR lto/86548
9371 * lto-wrapper.c: Add linker_output as prefix
9372 for ltrans_output_file.
9373
9374 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
9375
9376 PR rtl-optimization/85805
9377 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
9378 value for hard registers if that was written in the same mode.
9379
9380 2018-07-26 Martin Liska <mliska@suse.cz>
9381
9382 PR gcov-profile/86536
9383 * gcov.c (format_gcov): Use printf format %.*f directly
9384 and do not handle special values.
9385
9386 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9387
9388 * common/config/arc/arc-common.c (arc_option_optimization_table):
9389 Update default optimizations for size.
9390
9391 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9392
9393 * config/arc/arc.md (movsf_insn): Add short instruction selection.
9394 * config/arc/constraints.md (CfZ): New constraint.
9395 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
9396 (subsf3_fpu): Likewise.
9397 (cmpsf_fpu): Likewise.
9398 (cmpsf_fpu_uneq): Likewise.
9399
9400 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9401
9402 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
9403 accesses as well.
9404 (arc_is_uncached_mem_p): uncached applies to both the variable and
9405 the pointer.
9406
9407 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9408
9409 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
9410 register names.
9411
9412 2018-07-25 David Malcolm <dmalcolm@redhat.com>
9413
9414 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
9415 field "m_scopes" from vec to auto_vec.
9416
9417 2018-07-25 Martin Liska <mliska@suse.cz>
9418
9419 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
9420 return type.
9421
9422 2018-07-25 Richard Biener <rguenther@suse.de>
9423
9424 PR debug/86654
9425 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
9426 special wrt context_die late.
9427 (gen_subprogram_die): Re-use DIEs in local scope.
9428
9429 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
9430
9431 PR tree-optimization/86644
9432 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
9433
9434 2018-07-25 Martin Liska <mliska@suse.cz>
9435
9436 PR middle-end/86645
9437 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
9438 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
9439
9440 2018-07-25 Martin Liska <mliska@suse.cz>
9441
9442 PR sanitizer/79635
9443 * params.def: Explain ASan abbreviation and provide
9444 a documentation link.
9445
9446 2018-07-24 Martin Sebor <msebor@redhat.com>
9447
9448 PR tree-optimization/86622
9449 PR tree-optimization/86532
9450 * builtins.h (string_length): Declare.
9451 * builtins.c (c_strlen): Correct handling of non-constant offsets.
9452 (check_access): Be prepared for non-constant length ranges.
9453 (string_length): Make extern.
9454 * expr.c (string_constant): Only handle the minor non-constant
9455 array index. Use string_constant to compute the length of
9456 a generic string constant.
9457
9458 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
9459
9460 PR tree-optimization/86618
9461 * tree-vect-stmts.c (vectorizable_call): Don't take the address
9462 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
9463
9464 2018-07-24 David Malcolm <dmalcolm@redhat.com>
9465
9466 PR tree-optimization/86636
9467 * json.cc (json::object::set): Fix comment. Add assertions.
9468 (json::array::append): Move here from json.h. Add comment and an
9469 assertion.
9470 (json::string::string): Likewise.
9471 * json.h (json::array::append): Move to json.cc.
9472 (json::string::string): Likewise.
9473 * optinfo-emit-json.cc
9474 (optrecord_json_writer::impl_location_to_json): Assert that we
9475 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
9476 wrapper around it. Expand the location once, rather than three
9477 times.
9478 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
9479 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
9480 wrappers.
9481 (optrecord_json_writer::optinfo_to_json): Likewise, in four
9482 places. Fix some overlong lines.
9483
9484 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
9485
9486 * config/aarch64/aarch64-simd.md
9487 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
9488 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
9489 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
9490 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
9491 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
9492 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
9493 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
9494 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
9495 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
9496
9497 2018-07-24 Jakub Jelinek <jakub@redhat.com>
9498
9499 PR middle-end/86627
9500 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
9501 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
9502 and abs_d == d, do the power of two handling if profitable.
9503
9504 2018-07-24 Richard Biener <rguenther@suse.de>
9505
9506 * match.pd: Add BIT_FIELD_REF canonicalizations.
9507
9508 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9509
9510 PR c/86617
9511 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
9512
9513 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9514
9515 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
9516 terminated STRING_CST object.
9517
9518 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9519
9520 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
9521
9522 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9523
9524 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
9525 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
9526 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
9527 the elements into a register.
9528 (rs6000_split_v4si_init_di_reg): Delete.
9529 (rs6000_split_v4si_init): Delete.
9530 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
9531 (vsx_init_v4si): Rewrite as a define_expand.
9532
9533 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9534
9535 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
9536 zero_extend argument from memory): New.
9537
9538 2018-07-22 Martin Sebor <msebor@redhat.com>
9539
9540 PR bootstrap/86621
9541 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
9542 diagnosing calls with unknown arguments unless -Walloca-larger-than
9543 is restricted to less than PTRDIFF_MAX bytes.
9544
9545 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
9546
9547 * doc/gcov.texi (Invoking Gcov): Editorial changes.
9548
9549 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9550
9551 * pretty-print.c (text_info::set_location): Remove redundant
9552 "line_table" parameter from call to rich_location::set_range.
9553
9554 2018-07-20 Martin Sebor <msebor@redhat.com>
9555
9556 PR middle-end/82063
9557 * builtins.c (expand_builtin_alloca): Adjust.
9558 * calls.c (alloc_max_size): Simplify.
9559 * cgraphunit.c (cgraph_node::expand): Adjust.
9560 * common.opt (larger_than_size, warn_frame_larger_than): Remove
9561 variables.
9562 (frame_larger_than_size): Same.
9563 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
9564 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
9565 Initialize.
9566 * doc/invoke.texi (GCC Command Options): Document option arguments.
9567 Explain byte-size arguments and suffixes.
9568 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
9569 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
9570 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
9571 * doc/options.texi (UInteger): Expand.
9572 (Host_Wide_Int, ByteSize): Document new properties.
9573 * final.c (final_start_function_1): Include sizes in an error message.
9574 * function.c (frame_offset_overflow): Same.
9575 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
9576 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
9577 Diagnose unbounded alloca calls only for limits of less than
9578 PTRDIFF_MAX.
9579 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
9580 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
9581 for alloca(0).
9582 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
9583 only for limits of less than PTRDIFF_MAX.
9584 * langhooks-def.h (lhd_handle_option): Change function argument
9585 to HOST_WIDE_INT.
9586 * langhooks.c (lhd_handle_option): Same.
9587 * langhooks.h (handle_option): Same.
9588 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
9589 ByteSize flags.
9590 (var_type, var_type_struct): Same.
9591 (var_set): Handle ByteSize flag.
9592 * optc-gen.awk: Add comments to output to ease debugging. Make
9593 use of HOST_WIDE_INT where appropriate.
9594 * opts-gen-save.awk: Use %lx to format unsigned long.
9595 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
9596 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
9597 arguments. Parse bytes-size suffixes.
9598 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
9599 (enum_value_to_arg): Same.
9600 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
9601 (handle_option): Adjust.
9602 (generate_option): Change function argument to HOST_WIDE_INT.
9603 (cmdline_handle_error): Adjust.
9604 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
9605 (set_option): Change function argument to HOST_WIDE_INT.
9606 (option_enabled): Handle cl_host_wide_int.
9607 (get_option_state): Handle CLVC_SIZE.
9608 (control_warning_option): Same.
9609 * opts.c (common_handle_option): Change function argument to
9610 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
9611 OPT_Wvla_larger_than_.
9612 * opts.h (enum cl_var_type): Add an enumerator.
9613 * stor-layout.c (layout_decl): Print a more meaningful warning.
9614 * toplev.c (output_stack_usage): Adjust.
9615
9616 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
9617
9618 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
9619 call to inline_expand_builtin_string_cmp.
9620 (expand_builtin_strcmp): Likewise.
9621 (expand_builtin_strncmp): Likewise.
9622 (inline_string_cmp): Delete the last parameter, change char_type_node
9623 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
9624 two operands.
9625 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
9626 the inlining expansion on target where the type of the call has same or
9627 narrower precision than unsigned char.
9628
9629 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9630
9631 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
9632 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
9633 * common.opt (fsave-optimization-record): New option.
9634 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
9635 * doc/invoke.texi (-fsave-optimization-record): New option.
9636 * dumpfile.c: Include "optinfo-emit-json.h".
9637 (struct kv_pair): Move to coretypes.h.
9638 (optgroup_options): Make non-static.
9639 (dump_context::end_scope): Call
9640 optimization_records_maybe_pop_dump_scope.
9641 * dumpfile.h (optgroup_options): New decl.
9642 * json.cc: New file.
9643 * json.h: New file.
9644 * optinfo-emit-json.cc: New file.
9645 * optinfo-emit-json.h: New file.
9646 * optinfo.cc: Include "optinfo-emit-json.h".
9647 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
9648 (optinfo_enabled_p): Check optimization_records_enabled_p.
9649 (optinfo_wants_inlining_info_p): Likewise.
9650 * optinfo.h: Update comment.
9651 * profile-count.c (profile_quality_as_string): New function.
9652 * profile-count.h (profile_quality_as_string): New decl.
9653 (profile_count::quality): New accessor.
9654 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
9655 and optinfo_emit_json_cc_tests.
9656 * selftest.h (selftest::json_cc_tests): New decl.
9657 (selftest::optinfo_emit_json_cc_tests): New decl.
9658 * toplev.c: Include "optinfo-emit-json.h".
9659 (compile_file): Call optimization_records_finish.
9660 (do_compile): Call optimization_records_start.
9661 * tree-ssa-live.c: Include optinfo.h.
9662 (remove_unused_scope_block_p): Retain inlining information if
9663 optinfo_wants_inlining_info_p returns true.
9664
9665 2018-07-20 Richard Biener <rguenther@suse.de>
9666
9667 PR debug/86585
9668 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
9669 to cover -flto-partition=none.
9670
9671 2018-07-20 Martin Liska <mliska@suse.cz>
9672
9673 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
9674 (get_decl_source_range): Remove unused function.
9675
9676 2018-07-20 Richard Biener <rguenther@suse.de>
9677
9678 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
9679 (struct vn_phi_s): Likewise.
9680 (struct vn_reference_s): Likewise.
9681 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
9682 for searching the slot of an entry known to be in the hash itself.
9683 (vn_phi_hasher::equal): Likewise.
9684 (vn_reference_hasher::equal): Likewise.
9685 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
9686 globals.
9687 (optimistic_info, current_info): Remove, keeping only valid_info.
9688 (vn_reference_lookup_1): Remove fallback lookup.
9689 (vn_reference_lookup_2): Likewise.
9690 (vn_nary_op_lookup_1): Likewise.
9691 (vn_phi_lookup): Likewise.
9692 (vn_nary_build_or_lookup_1): Make sure to not chain the built
9693 hash element.
9694 (vn_reference_insert): Adjust, chain the inserted hash element
9695 at last_inserted_ref.
9696 (vn_reference_insert_pieces): Likewise.
9697 (visit_reference_op_call): Likewise.
9698 (vn_nary_op_insert_into): Chain the inserted hash element at
9699 last_inserted_nary.
9700 (vn_nary_op_insert_pieces): Adjust.
9701 (vn_nary_op_insert): Likewise.
9702 (vn_nary_op_insert_stmt): Likewise.
9703 (vn_phi_insert): Adjust, chain the inserted hash element at
9704 last_inserted_phi.
9705 (process_scc): Remove clearing and copying the optimistic
9706 table. Instead remove elements inserted during an optimistic
9707 iteration from the single table we maintain.
9708 (init_scc_vn): Adjust.
9709 (free_scc_vn): Likewise.
9710 (sccvn_dom_walker::record_cond): Likewise.
9711 (sccvn_dom_walker::after_dom_children): Likewise.
9712
9713 2018-07-19 Martin Sebor <msebor@redhat.com>
9714
9715 PR tree-optimization/84047
9716 PR tree-optimization/83776
9717 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
9718 (check_array_bounds): Call it.
9719
9720 2018-07-19 Martin Sebor <msebor@redhat.com>
9721
9722 * align.h (align_flags): Use member initialization.
9723
9724 2018-07-19 David Malcolm <dmalcolm@redhat.com>
9725
9726 * Makefile.in (OBJS): Add optinfo.o.
9727 * coretypes.h (class symtab_node): New forward decl.
9728 (struct cgraph_node): New forward decl.
9729 (class varpool_node): New forward decl.
9730 * dump-context.h: New file.
9731 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
9732 "tree-pass.h".
9733 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
9734 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
9735 (set_alt_dump_file): Likewise.
9736 (dump_context::~dump_context): New dtor.
9737 (dump_gimple_stmt): Move implementation to...
9738 (dump_context::dump_gimple_stmt): ...this new member function.
9739 Add the stmt to any pending optinfo, creating one if need be.
9740 (dump_gimple_stmt_loc): Move implementation to...
9741 (dump_context::dump_gimple_stmt_loc): ...this new member function.
9742 Start a new optinfo and add the stmt to it.
9743 (dump_gimple_expr): Move implementation to...
9744 (dump_context::dump_gimple_expr): ...this new member function.
9745 Add the stmt to any pending optinfo, creating one if need be.
9746 (dump_gimple_expr_loc): Move implementation to...
9747 (dump_context::dump_gimple_expr_loc): ...this new member function.
9748 Start a new optinfo and add the stmt to it.
9749 (dump_generic_expr): Move implementation to...
9750 (dump_context::dump_generic_expr): ...this new member function.
9751 Add the tree to any pending optinfo, creating one if need be.
9752 (dump_generic_expr_loc): Move implementation to...
9753 (dump_context::dump_generic_expr_loc): ...this new member
9754 function. Add the tree to any pending optinfo, creating one if
9755 need be.
9756 (dump_printf): Move implementation to...
9757 (dump_context::dump_printf_va): ...this new member function. Add
9758 the text to any pending optinfo, creating one if need be.
9759 (dump_printf_loc): Move implementation to...
9760 (dump_context::dump_printf_loc_va): ...this new member function.
9761 Start a new optinfo and add the stmt to it.
9762 (dump_dec): Move implementation to...
9763 (dump_context::dump_dec): ...this new member function. Add the
9764 value to any pending optinfo, creating one if need be.
9765 (dump_context::dump_symtab_node): New member function.
9766 (dump_context::get_scope_depth): New member function.
9767 (dump_context::begin_scope): New member function.
9768 (dump_context::end_scope): New member function.
9769 (dump_context::ensure_pending_optinfo): New member function.
9770 (dump_context::begin_next_optinfo): New member function.
9771 (dump_context::end_any_optinfo): New member function.
9772 (dump_context::s_current): New global.
9773 (dump_context::s_default): New global.
9774 (dump_scope_depth): Delete global.
9775 (dumpfile_ensure_any_optinfo_are_flushed): New function.
9776 (dump_symtab_node): New function.
9777 (get_dump_scope_depth): Reimplement in terms of dump_context.
9778 (dump_begin_scope): Likewise.
9779 (dump_end_scope): Likewise.
9780 (selftest::temp_dump_context::temp_dump_context): New ctor.
9781 (selftest::temp_dump_context::~temp_dump_context): New dtor.
9782 (selftest::verify_item): New function.
9783 (ASSERT_IS_TEXT): New macro.
9784 (ASSERT_IS_TREE): New macro.
9785 (ASSERT_IS_GIMPLE): New macro.
9786 (selftest::test_capture_of_dump_calls): New test.
9787 (selftest::dumpfile_c_tests): Call it.
9788 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
9789 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
9790 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
9791 descriptive comment.
9792 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
9793 (dump_node, dump_bb): Move these unrelated decls.
9794 (class dump_manager): Add leading comment.
9795 * optinfo.cc: New file.
9796 * optinfo.h: New file.
9797
9798 2018-07-19 Michael Collison <michael.collison@arm.com>
9799 Richard Henderson <rth@redhat.com>
9800
9801 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
9802 (subti): Handle op1 zero.
9803 (subvti4, usub4ti4): New.
9804 (*sub<GPI>3_compare1_imm): New.
9805 (sub<GPI>3_carryinCV): New.
9806 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
9807 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
9808
9809 2018-07-19 Michael Collison <michael.collison@arm.com>
9810 Richard Henderson <rth@redhat.com>
9811
9812 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
9813 (addti3): Create simpler code if low part is already known to be 0.
9814 (addvti4, uaddvti4): New.
9815 (*add<GPI>3_compareC_cconly_imm): New.
9816 (*add<GPI>3_compareC_cconly): New.
9817 (*add<GPI>3_compareC_imm): New.
9818 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
9819 handle constants within this pattern..
9820 (*add<GPI>3_compareV_cconly_imm): New.
9821 (*add<GPI>3_compareV_cconly): New.
9822 (*add<GPI>3_compareV_imm): New.
9823 (add<GPI>3_compareV): New.
9824 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
9825 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
9826 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
9827 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
9828 with 'comparison' operator.
9829 (*add<GPI>3_compareV_cconly_imm): Ditto.
9830 (*add<GPI>3_compareV_cconly): Ditto.
9831 (*add<GPI>3_compareV_imm): Ditto.
9832 (add<GPI>3_compareV): Ditto.
9833 (add<mode>3_carryinC): Ditto.
9834 (*add<mode>3_carryinC_zero): Ditto.
9835 (*add<mode>3_carryinC): Ditto.
9836 (add<mode>3_carryinV): Ditto.
9837 (*add<mode>3_carryinV_zero): Ditto.
9838 (*add<mode>3_carryinV): Ditto.
9839
9840 2018-07-19 Michael Collison <michael.collison@arm.com>
9841 Richard Henderson <rth@redhat.com>
9842
9843 * config/aarch64/aarch64-modes.def (CC_V): New.
9844 * config/aarch64/aarch64-protos.h
9845 (aarch64_addti_scratch_regs): Declare
9846 (aarch64_subvti_scratch_regs): Declare.
9847 (aarch64_expand_subvti): Declare.
9848 (aarch64_gen_unlikely_cbranch): Declare
9849 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
9850 for signed overflow using CC_Vmode.
9851 (aarch64_get_condition_code_1): Handle CC_Vmode.
9852 (aarch64_gen_unlikely_cbranch): New function.
9853 (aarch64_addti_scratch_regs): New function.
9854 (aarch64_subvti_scratch_regs): New function.
9855 (aarch64_expand_subvti): New function.
9856
9857 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9858
9859 * config/aarch64/aarch64-option-extensions.def: New entry for profile
9860 extension.
9861 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
9862 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
9863 extension.
9864
9865 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9866
9867 PR target/83009
9868 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
9869 address check not strict.
9870
9871 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9872
9873 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
9874 Umq with Umn.
9875 (store_pair_lanes<mode>): Likewise.
9876 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
9877 enum value 'ADDR_QUERY_LDP_STP_N'.
9878 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
9879 (aarch64_print_address_internal): Add declaration.
9880 (aarch64_print_ldpstp_address): Remove.
9881 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
9882 (aarch64_print_operand): Change printing of 'y'.
9883 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
9884 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
9885 'true' rather than '1'.
9886 * config/aarch64/constraints.md (Uml): Likewise.
9887 (Uml): Rename to Umn.
9888 (Umq): Remove.
9889
9890 2018-07-19 Richard Biener <rguenther@suse.de>
9891
9892 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
9893 a trailing array.
9894 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
9895 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
9896 (vn_reference_hasher): Likewise.
9897 (struct vn_tables_s): Remove obstack and alloc-pool members.
9898 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
9899 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
9900 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
9901 (vn_reference_insert_pieces): Likewise.
9902 (alloc_vn_nary_op_noinit): Adjust.
9903 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
9904 (vn_phi_eq): Adjust.
9905 (shared_lookup_phiargs): Remove.
9906 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
9907 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
9908 (visit_reference_op_call): Likewise.
9909 (copy_nary, copy_phi, copy_reference): Remove.
9910 (process_scc): Rewind the obstack when iterating. Do not
9911 copy the elements to valid_info but just move them from one
9912 hashtable to the other.
9913 (allocate_vn_table): Adjust.
9914 (free_vn_table): Likewise.
9915 (init_scc_vn): Likewise.
9916 (free_scc_vn): Likewise.
9917
9918 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
9919
9920 PR target/86560
9921 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
9922 indirect_return as function type attribute.
9923 (ix86_attribute_table): Change indirect_return to function
9924 type attribute.
9925 * doc/extend.texi: Update indirect_return attribute.
9926
9927 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
9928
9929 * wide-int.h (widest2_int): New.
9930 * gimple-fold.c (arith_overflowed_p): Use it.
9931 * tree.h (widest2_int_cst): New.
9932 * tree-vrp.c (wide_int_binop_overflow): Rename from
9933 vrp_int_const_binop.
9934 Rewrite to work on trees.
9935 (extract_range_from_multiplicative_op_1): Abstract code to...
9936 (wide_int_range_min_max): ...here.
9937 (wide_int_range_cross_product): ...and here.
9938 (extract_range_from_binary_expr_1): Abstract overflow code to...
9939 (wide_int_range_mult_wrapping): ...here.
9940 * tree-vrp.h (wide_int_range_cross_product): New.
9941 (wide_int_range_mult_wrapping): New.
9942
9943 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
9944 Julia Koval <julia.koval@intel.com>
9945
9946 * config/i386/x86-tune-costs.h (skylake_memcpy,
9947 skylake_memset): Replace rep_prefix with unrolling for size 512.
9948
9949 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
9950
9951 PR middle-end/86544
9952 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
9953 comparision with EQ_EXPR in last stmt.
9954
9955 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
9956
9957 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
9958 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
9959 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
9960 previously known as "PowerPC AltiVec Built-in Functions". Move
9961 some material to new subsubsections "PowerPC AltiVec Built-in
9962 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
9963 ISA 2.07".
9964 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
9965 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
9966 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
9967 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
9968
9969 2018-07-18 Richard Biener <rguenther@suse.de>
9970
9971 PR tree-optimization/86557
9972 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
9973 EXACT_DIV_EXPR.
9974
9975 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
9976
9977 * config/s390/s390.c (s390_function_profiler): Generate CFI.
9978
9979 2018-07-17 Jeff Law <law@redhat.com>
9980
9981 * config/arm/arm.c (get_label_padding): Update for recent
9982 changes to label_to_alignment.
9983
9984 PR tree-optimization/86010
9985 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
9986
9987 * config/mips/mips.c (vr4130_align_insns): Update for recent
9988 changes to label_to_alignment.
9989
9990 * config/frv/frv.c (frv_label_align): Update for recent changes
9991 to label_to_alignment.
9992
9993 * config/nios2/nios2.c (nios2_label_align): Update for recent
9994 changes which dropped ALIGN_LABELS_LOG.
9995
9996 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
9997
9998 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
9999 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
10000
10001 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
10002
10003 * config/arc/arc.c (arc_label_align): Use align_labels instead of
10004 deprecated align_labels_log.
10005
10006 2018-07-17 Richard Biener <rguenther@suse.de>
10007
10008 PR lto/86456
10009 * dwarf2out.c (init_sections_and_labels): Always generate
10010 a debug_line_str_section for early LTO debug.
10011 (dwarf2out_finish): Reset debug_line_str_hash output early.
10012 Bump counter for extra dwarf5 .debug_loc labels to not conflict
10013 with fat LTO part.
10014 (dwarf2out_early_finish): Output debug_line_str.
10015
10016 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10017
10018 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
10019 index register on z196 or later.
10020
10021 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10022
10023 * config/s390/s390.c (s390_default_align): Set default function
10024 alignment to 16.
10025 (s390_override_options_after_change): Call s390_default align.
10026 (s390_option_override_internal): Call s390_default_align.
10027 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
10028
10029 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10030
10031 PR middle-end/86542
10032 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
10033 to _looptemp_ clauses, other than the first two.
10034
10035 2018-07-17 Martin Liska <mliska@suse.cz>
10036
10037 * opts.c: Do not enable OPT_falign_* for -Os.
10038
10039 2018-07-17 Martin Liska <mliska@suse.cz>
10040
10041 * align.h (MAX_CODE_ALIGN): New.
10042 (MAX_CODE_ALIGN_VALUE): New.
10043 * common/config/i386/i386-common.c (ix86_handle_option):
10044 (MAX_CODE_ALIGN): Moved to align.h.
10045 * final.c (MAX_CODE_ALIGN): Likewise.
10046 * opts.c (parse_and_check_align_values):
10047 (MAX_CODE_ALIGN): Likewise.
10048 (MAX_CODE_ALIGN_VALUE): Likewise.
10049
10050 2018-07-17 Martin Liska <mliska@suse.cz>
10051
10052 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
10053 in order to fulfil coding style.
10054 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
10055 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10056 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
10057 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
10058 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
10059 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
10060 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
10061 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
10062 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10063
10064 2018-07-17 Martin Liska <mliska@suse.cz>
10065
10066 * align.h: New file.
10067 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
10068 directly.
10069 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
10070 align_flags of label_to_alignment.
10071 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
10072 align_flags class.
10073 * config/m68k/m68k.c: Do not use removed align_labels_value and
10074 align_loops_value.
10075 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
10076 (LOOP_ALIGN): Likewise.
10077 (LABEL_ALIGN): Likewise.
10078 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10079 Remove not used macro.
10080 (rs6000_loop_align): Change return type to align_flags.
10081 (rs6000_loop_align_max_skip): Remove.
10082 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
10083 Change return type to align_flags.
10084 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10085 Remove not used macro.
10086 (rs6000_loop_align): Change return type to align_flags.
10087 (rs6000_loop_align_max_skip): Remove.
10088 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
10089 * config/rx/rx-protos.h (rx_align_for_label): Make it
10090 static function.
10091 * config/rx/rx.c (rx_align_for_label): Change return type
10092 to align_flags.
10093 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
10094 macro definitions.
10095 into align_flags class.
10096 (LABEL_ALIGN): Likewise.
10097 (LOOP_ALIGN): Likewise.
10098 * config/s390/s390.c (s390_label_align): Use align_flags
10099 class member.
10100 (s390_asm_output_function_label): Likewise.
10101 * config/sh/sh.c (sh_override_options_after_change):
10102 Use align_flags class directly without macros.
10103 (find_barrier): Likewise.
10104 (barrier_align): Likewise.
10105 (sh_loop_align): Likewise.
10106 * config/spu/spu.c (spu_option_override):
10107 Use align_flags_tuple::get_value instead of removed macros.
10108 (spu_sched_init): Likewise.
10109 * config/spu/spu.h (GTY): Likewise.
10110 * config/visium/visium.c (visium_option_override):
10111 Set "8" as default secondary alignment.
10112 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
10113 in order to guarantee secondary alignment of 8.
10114 * coretypes.h: Include align.h header file.
10115 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
10116 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
10117 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
10118 * doc/tm.texi.in: Likewise.
10119 * final.c (struct label_alignment): Remove not used structure.
10120 (LABEL_ALIGN): Change type to align_flags.
10121 (LOOP_ALIGN): Likewise.
10122 (JUMP_ALIGN): Likewise.
10123 (default_loop_align_max_skip): Remove.
10124 (default_label_align_max_skip): Likewise.
10125 (default_jump_align_max_skip): Likewise.
10126 (default_label_align_after_barrier_max_skip):
10127 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
10128 (LABEL_TO_MAX_SKIP): Remove.
10129 (label_to_alignment): Return align_flags type instead of integer.
10130 (label_to_max_skip): Remove.
10131 (align_fuzz): Use align_flags type.
10132 (compute_alignments): Use align_flags type and use align_flags::max
10133 to combine multiple alignments.
10134 (grow_label_align): Grow vec instead of C array.
10135 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
10136 (shorten_branches): Use align_flags type and use align_flags::max
10137 to combine multiple alignments.
10138 (final_scan_insn_1): Remove usage of secondary alignment that comes
10139 from label alignment, but instead use proper secondary alignment
10140 which is computed in grow_label_align.
10141 * flags.h (struct align_flags_tuple): Move to align.h.
10142 (struct align_flags): Likewise.
10143 (state_align_loops): Rename to align_loops.
10144 (state_align_jumps): Rename to align_jumps.
10145 (state_align_labels): Rename to align_labels.
10146 (state_align_functions): Rename to align_functions.
10147 (align_loops_log): Remove.
10148 (align_jumps_log): Remove.
10149 (align_labels_log): Remove.
10150 (align_functions_log): Remove.
10151 (align_loops_max_skip): Remove.
10152 (align_jumps_max_skip): Remove.
10153 (align_labels_max_skip): Remove.
10154 (align_functions_max_skip): Remove.
10155 (align_loops_value): Remove.
10156 (align_jumps_value): Remove.
10157 (align_labels_value): Remove.
10158 (align_functions_value): Remove.
10159 * output.h (label_to_alignment): Change return type to align_flags.
10160 (label_to_max_skip): Remove.
10161 * target.def: Remove loop_align_max_skip, label_align_max_skip,
10162 jump_align_max_skip macros.
10163 * targhooks.h (default_loop_align_max_skip): Remove.
10164 (default_label_align_max_skip): Likewise.
10165 (default_jump_align_max_skip): Likewise.
10166 (default_label_align_after_barrier_max_skip): Remove.
10167 * toplev.c (read_log_maxskip): Use ::normalize function.
10168 (parse_N_M): Remove not used argument and also call ::normalize.
10169 (parse_alignment_opts): Do not pass unused arguments.
10170 * varasm.c (assemble_start_function): Use directly align_functions
10171 instead of removed macros.
10172 * system.h: Do not poison removed macros.
10173
10174 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10175
10176 PR middle-end/86539
10177 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
10178 and cond temporaries don't have reference type if iterator has
10179 pointer type. For init use &for_pre_body instead of pre_p if
10180 for_pre_body is non-empty.
10181
10182 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10183
10184 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
10185 double-double modes to SFmode directly directly.
10186 (trunc<mode>sf2_fprs): Delete.
10187
10188 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10189
10190 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
10191 for conversions between IFmode and the decimal floating point modes.
10192 (init_float128_ieee): Use the correct names for conversions between
10193 KFmode and the decimal floating point modes.
10194
10195 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10196
10197 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
10198 for the conversions between TDmode and IFmode.
10199 (init_float128_ieee): Use more correct names for the conversions
10200 between TDmode and KFmode.
10201
10202 2018-07-16 Jakub Jelinek <jakub@redhat.com>
10203
10204 PR tree-optimization/86526
10205 * builtins.c (expand_builtin_memcmp): Formatting fixes.
10206 (inline_expand_builtin_string_cmp): Likewise.
10207 (inline_string_cmp): Likewise. Use c_readstr instead of
10208 builtin_memcpy_read_str. Add unit_mode temporary.
10209
10210 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
10211
10212 PR middle-end/86528
10213 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
10214 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
10215
10216 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
10217
10218 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
10219 Alphabetize prototypes of built-in functions, separating out
10220 built-in functions that are listed in this section but should be
10221 described elsewhere.
10222
10223 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
10224
10225 PR target/86511
10226 * expmed.c (emit_store_flag): Do not emit setcc followed by a
10227 conditional move when trapping comparison was split to a
10228 non-trapping one (and vice versa).
10229
10230 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10231
10232 * config/s390/s390.c (s390_function_profiler): Generate nops
10233 instead of profiler call sequences.
10234 * config/s390/s390.opt: Add the new option.
10235
10236 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10237
10238 * config/s390/s390.c (s390_function_profiler): Generate
10239 __mcount_loc section.
10240 * config/s390/s390.opt: Add the new option.
10241
10242 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10243
10244 * common.opt: Add the new warning.
10245 * config/s390/s390.c (s390_function_profiler): Emit "brasl
10246 %r0,__fentry__" when -mfentry is specified.
10247 (s390_option_override_internal): Disallow -mfentry for 31-bit
10248 CPUs.
10249 * config/s390/s390.opt: Add the new option.
10250
10251 2018-07-16 Richard Biener <rguenther@suse.de>
10252
10253 PR lto/86523
10254 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
10255 for function-local FUNCTION_DECL and RESULT_DECL immediately.
10256
10257 2018-07-16 Martin Liska <mliska@suse.cz>
10258
10259 PR ipa/86529
10260 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
10261 to ::get_create.
10262
10263 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10264
10265 * config/arc/arcHS.md: Update ARCHS scheduling rules.
10266
10267 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10268
10269 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
10270 for ARCHS4x.
10271 * config/arc/arc-cpus.def (hs4x): New cpu.
10272 (hs4xd): Likewise.
10273 * config/arc/arc-tables.opt: Regenerate.
10274 * config/arc/arc.c (arc_sched_issue_rate): New function.
10275 (TARGET_SCHED_ISSUE_RATE): Define.
10276 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
10277 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
10278 fpu_cvt.
10279 (attr tune): Add ARCHS4x tune values.
10280 (attr tune_dspmpy): Define.
10281 (*tst): Correct instruction type.
10282 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
10283 * config/arc/arcHS4x.md: New file.
10284 * config/arc/fpu.md: Update instruction type attributes.
10285 * config/arc/t-multilib: Regenerate.
10286
10287 2018-07-16 Tom de Vries <tdevries@suse.de>
10288
10289 PR debug/86455
10290 * var-tracking.c (vt_initialize): Fix pre_dec handling.
10291
10292 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10293
10294 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
10295 early clobber.
10296
10297 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
10298
10299 PR tree-optimization/86514
10300 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
10301 conversion to a boolean type from a type with greater precision.
10302
10303 2018-07-16 Tom de Vries <tdevries@suse.de>
10304
10305 * var-tracking.c (vt_initialize): Print adjusted insn slim if
10306 dump_flags request TDF_SLIM.
10307
10308 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
10309
10310 * fold-const.c (int_const_binop_1): Abstract...
10311 (wide_int_binop): ...wide int code here.
10312 (poly_int_binop): ...poly int code here.
10313 Abstract the rest of int_const_binop_1 into int_const_binop.
10314 * fold-const.h (wide_int_binop): New.
10315 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
10316 Remove useless PLUS/MINUS_EXPR case.
10317 (zero_nonzero_bits_from_vr): Move wide int code...
10318 (zero_nonzero_bits_from_bounds): ...here.
10319 (extract_range_from_binary_expr_1): Move mask optimization code...
10320 (range_easy_mask_min_max): ...here.
10321 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
10322 (range_easy_mask_min_max): New.
10323
10324 2018-07-15 Jeff Law <law@redhat.com>
10325
10326 PR target/85993
10327 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
10328 block.
10329
10330 2018-07-14 Jim Wilson <jimw@sifive.com>
10331
10332 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
10333
10334 2018-07-14 Paul Koning <ni1d@arrl.net>
10335
10336 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
10337
10338 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
10339
10340 * lto-streamer-out.c (copy_function_or_variable): Dump info about
10341 copying section.
10342
10343 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
10344 Steve Munroe <munroesj52@gmail.com>
10345
10346 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
10347 (_mm_andnot_si128): Likewise.
10348 (_mm_or_si128): Likewise.
10349 (_mm_xor_si128): Likewise.
10350
10351 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
10352
10353 PR middle-end/78809
10354 * builtins.c (expand_builtin_memcmp): Inline the calls first
10355 when result_eq is false.
10356 (expand_builtin_strcmp): Inline the calls first.
10357 (expand_builtin_strncmp): Likewise.
10358 (inline_string_cmp): New routine. Expand a string compare
10359 call by using a sequence of char comparison.
10360 (inline_expand_builtin_string_cmp): New routine. Inline expansion
10361 a call to str(n)cmp/memcmp.
10362 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
10363 New option.
10364 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
10365
10366 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
10367
10368 * config/arm/driver-arm.c: Include arm-native.h.
10369 (host_detect_local_cpu): Use auto-generated data tables.
10370 (vendors, arm_cpu_table): Delete. Move part information to ...
10371 * config/arm/arm-cpus.in: ... here.
10372 * config/arm/parsecpu.awk (gen_native): New function.
10373 (vendor, part): New CPU fields.
10374 (END): Add support for building the native CPU detection tables.
10375 * config/arm/t-arm (arm-native.h): Add build rule.
10376 (driver-arm.o): Add dependency on arm-native.h.
10377
10378 2018-07-13 Richard Biener <rguenther@suse.de>
10379
10380 PR middle-end/85974
10381 * match.pd (addr1 - addr2): Allow either of the operand to
10382 have a conversion.
10383
10384 2018-07-13 Tom de Vries <tdevries@suse.de>
10385
10386 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
10387 in remap_ssa_name.
10388
10389 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
10390
10391 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
10392 arrays instead of numbered variables.
10393
10394 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
10395
10396 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
10397 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
10398
10399 2018-07-13 Richard Biener <rguenther@suse.de>
10400
10401 PR debug/86452
10402 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
10403 instead of get_context_die.
10404
10405 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
10406 Richard Biener <rguenther@suse.de>
10407
10408 PR middle-end/86489
10409 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
10410 that the loop latch destination where phi is defined.
10411
10412 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
10413
10414 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
10415 (riscv_expand_epilogue): Add assertion to check interrupt mode.
10416 (riscv_set_current_function): Extract getting interrupt type to new
10417 function.
10418 (riscv_get_interrupt_type): New function.
10419 (riscv_merge_decl_attributes): New function, checking interrupt type is
10420 same.
10421 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
10422
10423 2018-07-12 Paul Koning <ni1d@arrl.net>
10424
10425 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
10426 directive.
10427
10428 2018-07-12 Paul Koning <ni1d@arrl.net>
10429
10430 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
10431 zero reference, add doloop_end instead.
10432 * doc/md.texi (decrement_and_branch_until_zero): Remove.
10433 (Looping patterns): Remove decrement_and_branch_until_zero. Add
10434 detail for doloop_end.
10435
10436 2018-07-12 Martin Sebor <msebor@redhat.com>
10437
10438 PR c/86453
10439 * attribs.c (decl_attributes): Reject conflicting attributes before
10440 calling attribute handlers.
10441
10442 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10443
10444 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
10445 parameter.
10446 (gcc::dump_manager::get_dump_file_name): likewise.
10447 (dump_begin): Likewise.
10448 * dumpfile.h (dump_begin): Update prototype.
10449 (gcc::dump_manager::get_dump_file_name,
10450 gcc::dump_manager::get_dump_file_name): Update prototype.
10451
10452 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10453
10454 * internal-fn.h (vectorizable_internal_fn_p): New function.
10455 * tree-vect-slp.c (compatible_calls_p): Likewise.
10456 (vect_build_slp_tree_1): Remove nops argument. Handle calls
10457 to internal functions.
10458 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
10459
10460 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10461
10462 * fold-const.h (inverse_conditions_p): Declare.
10463 * fold-const.c (inverse_conditions_p): New function.
10464 * match.pd: Use inverse_conditions_p. Add folds of view_converts
10465 that test the inverse condition of a conditional internal function.
10466 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
10467 * internal-fn.c (internal_fn_mask_index): Handle conditional
10468 internal functions.
10469 (vectorized_internal_fn_supported_p): New function.
10470 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
10471 (any_pred_load_store): Replace with...
10472 (need_to_predicate): ...this new variable.
10473 (redundant_ssa_names): New variable.
10474 (ifcvt_can_use_mask_load_store): Move initial checks to...
10475 (ifcvt_can_predicate): ...this new function. Handle tree codes
10476 for which a conditional internal function exists.
10477 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
10478 instead of ifcvt_can_use_mask_load_store. Update after variable
10479 name change.
10480 (predicate_load_or_store): New function, split out from
10481 predicate_mem_writes.
10482 (check_redundant_cond_expr): New function.
10483 (value_available_p): Likewise.
10484 (predicate_rhs_code): Likewise.
10485 (predicate_mem_writes): Rename to...
10486 (predicate_statements): ...this. Use predicate_load_or_store
10487 and predicate_rhs_code.
10488 (combine_blocks, tree_if_conversion): Update after above name changes.
10489 (ifcvt_local_dce): Handle redundant_ssa_names.
10490 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
10491 general conditional functions.
10492 * tree-vect-stmts.c (vectorizable_call): Likewise.
10493
10494 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10495 Alan Hayward <alan.hayward@arm.com>
10496 David Sherwood <david.sherwood@arm.com>
10497
10498 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
10499 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
10500 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
10501 plus and minus and convert them into IFN_COND_FMA-based sequences.
10502 (convert_mult_to_fma): Handle conditional plus and minus.
10503
10504 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10505
10506 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
10507 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
10508 (cond_fnms_optab): New optabs.
10509 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
10510 internal functions.
10511 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
10512 * internal-fn.h (get_conditional_internal_fn): Declare.
10513 (get_unconditional_internal_fn): Likewise.
10514 * internal-fn.c (cond_ternary_direct): New macro.
10515 (expand_cond_ternary_optab_fn): Likewise.
10516 (direct_cond_ternary_optab_supported_p): Likewise.
10517 (FOR_EACH_COND_FN_PAIR): Likewise.
10518 (get_conditional_internal_fn): New function.
10519 (get_unconditional_internal_fn): Likewise.
10520 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
10521 (gimple_match_op::gimple_match_op): Add a new overload for 5
10522 operands.
10523 (gimple_match_op::set_op): Likewise.
10524 (gimple_resimplify5): Declare.
10525 * genmatch.c (decision_tree::gen): Generate simplifications for
10526 5 operands.
10527 * gimple-match-head.c (gimple_simplify): Define an overload for
10528 5 operands. Handle calls with 5 arguments in the top-level overload.
10529 (convert_conditional_op): Handle conversions from unconditional
10530 internal functions to conditional ones.
10531 (gimple_resimplify5): New function.
10532 (build_call_internal): Pass a fifth operand.
10533 (maybe_push_res_to_seq): Likewise.
10534 (try_conditional_simplification): Try converting conditional
10535 internal functions to unconditional internal functions.
10536 Handle 3-operand unconditional forms.
10537 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
10538 Define ternary equivalents of the current rules for binary conditional
10539 internal functions.
10540 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
10541 ternary operations.
10542 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
10543 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
10544 (optab): Handle them.
10545 (SVE_COND_FP_TERNARY): New int iterator.
10546 (sve_fmla_op, sve_fmad_op): New int attributes.
10547 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
10548 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
10549 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
10550
10551 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10552
10553 * target.def (preferred_else_value): New target hook.
10554 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
10555 * doc/tm.texi: Regenerate.
10556 * targhooks.h (default_preferred_else_value): Declare.
10557 * targhooks.c (default_preferred_else_value): New function.
10558 * internal-fn.h (conditional_internal_fn_code): Declare.
10559 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
10560 (get_conditional_internal_fn): Use it.
10561 (conditional_internal_fn_code): New function.
10562 * gimple-match.h (gimple_match_cond): New struct.
10563 (gimple_match_op): Add a cond member function.
10564 (gimple_match_op::gimple_match_op): Update all forms to take a
10565 gimple_match_cond.
10566 * genmatch.c (expr::gen_transform): Use the same condition as res_op
10567 for the suboperation, but don't specify a particular else_value.
10568 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
10569 (visit_nary_op, visit_reference_op_load): Pass
10570 gimple_match_cond::UNCOND to the gimple_match_op constructor.
10571 * gimple-match-head.c: Include tree-eh.h
10572 (convert_conditional_op): New function.
10573 (maybe_resimplify_conditional_op): Likewise.
10574 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
10575 (gimple_resimplify2): Likewise.
10576 (gimple_resimplify3): Likewise.
10577 (gimple_resimplify4): Likewise.
10578 (maybe_push_res_to_seq): Return null for conditional operations.
10579 (try_conditional_simplification): New function.
10580 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
10581 constructor.
10582 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
10583 IFN_COND_* call.
10584 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
10585 function.
10586 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
10587
10588 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10589
10590 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
10591 DECL_FCONTEXT
10592 (hash_tree): Do not hash DECL_FCONTEXT
10593 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
10594 Do not stream DECL_FCONTEXT.
10595 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
10596 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
10597
10598 2018-07-12 Richard Biener <rguenther@suse.de>
10599
10600 PR debug/86462
10601 * dwarf2out.c (gen_block_die): Only output blocks when they have
10602 at least one !DECL_IGNORED_P variable.
10603
10604 2018-07-12 Richard Biener <rguenther@suse.de>
10605
10606 PR target/84829
10607 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
10608 Remove -mieee-fp handling.
10609
10610 2018-07-12 Richard Biener <rguenther@suse.de>
10611
10612 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
10613 left-over from last patch.
10614
10615 2018-07-12 Jakub Jelinek <jakub@redhat.com>
10616
10617 PR tree-optimization/86492
10618 * gimple-ssa-store-merging.c
10619 (imm_store_chain_info::coalesce_immediate_stores): Call
10620 check_no_overlap even for the merge_overlapping case. Formatting fix.
10621
10622 2018-07-12 Richard Biener <rguenther@suse.de>
10623
10624 PR middle-end/86479
10625 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
10626 move possibly trapping operations into the conditional.
10627
10628 2018-07-12 Richard Biener <rguenther@suse.de>
10629
10630 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
10631 (vn_lookup_simplify_result): Remove recursion limit applied
10632 here.
10633 (vn_nary_build_or_lookup_1): Adjust.
10634 (try_to_simplify): Likewise.
10635 * gimple-match-head.c (gimple_resimplify1): Instead apply one
10636 here.
10637 (gimple_resimplify2): Likewise.
10638 (gimple_resimplify3): Likewise.
10639 (gimple_resimplify4): Likewise.
10640
10641 2018-07-11 Jakub Jelinek <jakub@redhat.com>
10642
10643 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
10644 Use __mmask64 type instead of __mmask8 for __M argument.
10645 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
10646 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
10647 __U argument.
10648 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
10649 __mmask16 for __M argument.
10650 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
10651 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
10652 to __mmask16 instead of __mmask8.
10653 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
10654 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
10655 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
10656 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
10657 instead of __mmask16 for __U argument.
10658 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
10659 __mmask16 instead of __mmask8 for __U argument.
10660 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
10661 __U argument.
10662 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
10663 __mmask16.
10664 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
10665 argument.
10666 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
10667 __U argument.
10668 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
10669 __mmask16.
10670 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
10671 of __mmask16.
10672 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
10673 __U argument.
10674 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
10675 __U argument.
10676 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
10677 __U argument.
10678 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
10679 __U argument.
10680 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
10681 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
10682 return type as well as __M argument type and all casts from __mmask8
10683 to __mmask32.
10684 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
10685 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
10686 return type as well as __M argument type and all casts from __mmask8
10687 to __mmask16.
10688 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
10689 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
10690 return type as well as __M argument type and all casts from __mmask8
10691 to __mmask32.
10692 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
10693 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
10694 return type as well as __M argument type and all casts from __mmask8
10695 to __mmask16.
10696 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
10697 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
10698 __mmask16.
10699
10700 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
10701
10702 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
10703 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
10704 for __U argument.
10705
10706 2018-07-11 Paul Koning <ni1d@arrl.net>
10707
10708 * doc/md.texi (define_subst): Document how multiple occurrences of
10709 the same argument in the replacement pattern are handled.
10710
10711 2018-07-11 Paul Koning <ni1d@arrl.net>
10712
10713 * doc/extend.texi (Common Variable Attributes): Move "mode" into
10714 alphabetical order.
10715 (Common Type Attributes): Add "mode" attribute.
10716
10717 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
10718
10719 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
10720 stream DECL_ORIGINAL_TYPE.
10721 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
10722 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
10723 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
10724 Do not walk original type.
10725 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
10726 external decls.
10727 (write_ts_decl_non_common_tree_pointers): Do not stream
10728 DECL_ORIGINAL_TYPE
10729 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
10730 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
10731
10732 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10733
10734 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
10735 thread twice from the same starting edge.
10736
10737 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10738
10739 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
10740 * gimple.c (gimple_call_nonnull_result_p): ...here...
10741 (gimple_call_nonnull_arg): ...and here.
10742 * gimple.h (gimple_call_nonnull_result_p): New.
10743 (gimple_call_nonnull_arg): New.
10744
10745 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
10746
10747 * config/arm/arm-cpus.in: Move information from fpu field of each
10748 cpu definition to the isa field.
10749 * config/arm/parsecpu.awk (fpu): Delete match rule.
10750 (gen_comm_data): Don't add bits from the CPU's FPU entry.
10751
10752 2018-07-11 Richard Biener <rguenther@suse.de>
10753
10754 PR debug/86457
10755 * dwarf2out.c (init_sections_and_labels): Use
10756 output_asm_line_debug_info consistently.
10757 (dwarf2out_early_finish): Likewise.
10758 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
10759 type units.
10760
10761 2018-07-11 Richard Biener <rguenther@suse.de>
10762
10763 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
10764 Rework father_bb setting in a way to avoid propagating constants
10765 multiple times on a loop body.
10766
10767 2018-07-10 Mark Wielaard <mark@klomp.org>
10768
10769 PR debug/86459
10770 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
10771
10772 2018-07-10 Richard Biener <rguenther@suse.de>
10773
10774 * hash-map.h (hash_map::iterator::operator*): Return
10775 references to key and value.
10776
10777 2018-07-10 Jakub Jelinek <jakub@redhat.com>
10778
10779 PR c++/86443
10780 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
10781 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
10782 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
10783 (gimplify_omp_for): For composite loops, move outer
10784 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
10785 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
10786 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
10787 TREE_LIST for both the original class iterator and the "last" helper
10788 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
10789 loop, remember has_decl_expr from outer composite loops for the
10790 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
10791
10792 2018-07-09 Martin Sebor <msebor@redhat.com>
10793
10794 PR middle-end/77357
10795 PR middle-end/86428
10796 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
10797 accessing implicitly initialized array elements.
10798 * expr.c (string_constant): Handle string initializers of
10799 character arrays within aggregates.
10800 * gimple-fold.c (fold_array_ctor_reference): Add argument.
10801 Store element offset. As a special case, handle zero size.
10802 (fold_nonarray_ctor_reference): Same.
10803 (fold_ctor_reference): Add argument. Store subobject offset.
10804 * gimple-fold.h (fold_ctor_reference): Add argument.
10805
10806 2018-07-09 Paul Koning <ni1d@arrl.net>
10807
10808 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
10809 (pdp11_insn_cost): New function.
10810 (pdp11_md_asm_adjust): New function.
10811 (TARGET_INVALID_WITHIN_DOLOOP): Define.
10812 (pdp11_rtx_costs): Update to match machine better.
10813 (output_addr_const_pdp11): Correct format mismatch warnings.
10814 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
10815 * config/pdp11/pdp11.md: General change to add base_cost and/or
10816 length attributes for use by new pdp11_insn_cost function.
10817 (MIN_BRANCH): Correct definition.
10818 (MIN_SOB): Ditto.
10819 (doloop_end): Use standard pattern name for looping pattern.
10820 (doloop_end_nocc): New.
10821 (movsf): Add another constraint alternative.
10822 (zero_extendqihi2): Add constraint alternatives for not in place
10823 extend.
10824 (zero_extendhisi2): Remove.
10825 (shift patterns): Add CC handling variants.
10826 (bswaphi2): New.
10827 (bswapsi2): New.
10828 (rothi3): New.
10829 (define_peephole2): New peephole to recognize mov that sets CC for
10830 subsequent test.
10831
10832 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10833
10834 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
10835 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
10836 wi::add.
10837
10838 2018-07-09 Jakub Jelinek <jakub@redhat.com>
10839
10840 PR c/86420
10841 * real.c (real_nextafter): Return true if result is denormal.
10842
10843 2018-07-09 Martin Liska <mliska@suse.cz>
10844
10845 * common.opt: Add back wrongly removed attribute.
10846
10847 2018-07-09 Richard Biener <rguenther@suse.de>
10848
10849 PR debug/86413
10850 * dwarf2out.c (gen_block_die): For an early generated DIE
10851 always output high/low PC attributes.
10852
10853 2018-07-09 Tom de Vries <tdevries@suse.de>
10854
10855 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
10856 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
10857 onto VAR_DECL with abstract origin.
10858
10859 2018-07-07 Jim Wilson <jimw@sifive.com>
10860
10861 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
10862
10863 2018-07-07 Tom de Vries <tdevries@suse.de>
10864
10865 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
10866
10867 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
10868
10869 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
10870 overflow_type.
10871 (combine_bound): Use wide-int overflow calculation instead of
10872 rolling our own.
10873 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
10874 overflow_type.
10875 * fold-const.c (int_const_binop_2): Same.
10876 (extract_muldiv_1): Same.
10877 (fold_div_compare): Same.
10878 (fold_abs_const): Same.
10879 * match.pd: Same.
10880 * poly-int.h (add): Same.
10881 (sub): Same.
10882 (neg): Same.
10883 (mul): Same.
10884 * predict.c (predict_iv_comparison): Same.
10885 * profile-count.c (slow_safe_scale_64bit): Same.
10886 * simplify-rtx.c (simplify_const_binary_operation): Same.
10887 * tree-chrec.c (tree_fold_binomial): Same.
10888 * tree-data-ref.c (split_constant_offset_1): Same.
10889 * tree-if-conv.c (idx_within_array_bound): Same.
10890 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
10891 * tree-ssa-phiopt.c (minmax_replacement): Same.
10892 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
10893 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
10894 * vr-values.c (vr_values::adjust_range_with_scev): Same.
10895 * wide-int.cc (wi::add_large): Same.
10896 (wi::mul_internal): Same.
10897 (wi::sub_large): Same.
10898 (wi::divmod_internal): Same.
10899 * wide-int.h: Change overflow type to overflow_type for neg, add,
10900 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
10901 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
10902 mul_internal, divmod_internal.
10903 (overflow_type): New enum.
10904 (accumulate_overflow): New.
10905
10906 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
10907
10908 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
10909 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
10910
10911 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
10912
10913 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
10914 argument is checked for zero before entering loop, avoid checking again.
10915
10916 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
10917
10918 * gimplify.h (generic_expr_could_trap_p): Set as global function.
10919 * gimplify.h (generic_expr_could_trap_p): Likwise.
10920 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
10921
10922 2018-07-06 Jakub Jelinek <jakub@redhat.com>
10923
10924 PR tree-optimization/86401
10925 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
10926 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
10927 (fold_bit_and_mask): ... here. New helper function for match.pd.
10928 * fold-const.h (fold_bit_and_mask): Declare.
10929 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
10930
10931 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
10932
10933 PR target/86324
10934 * target.def (translate_mode_attribute): New hook.
10935 * targhooks.h (default_translate_mode_attribute): Declare.
10936 * targhooks.c (default_translate_mode_attribute): New function.
10937 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
10938 * doc/tm.texi: Regenerate.
10939 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
10940 (rs6000_translate_mode_attribute): New function.
10941
10942 2018-07-06 Paul Koning <ni1d@arrl.net>
10943
10944 * doc/md.texi (define_split): Document DONE and FAIL.
10945 (define_peephole2): Ditto.
10946
10947 2018-07-05 Jeff Law <law@redhat.com>
10948
10949 PR tree-optimization/86010
10950 * tree-ssa-dse.c (compute_trims): More aggressively trim at
10951 both the head and tail of mem* and str* calls.
10952
10953 2018-07-05 Jim Wilson <jimw@sifive.com>
10954
10955 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
10956
10957 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
10958
10959 * config/aarch64/aarch64-simd.md: correct flags text for
10960 MIN_EXPR replacement.
10961
10962 2018-07-05 James Clarke <jrtc27@jrtc27.com>
10963
10964 * configure: Regenerated.
10965
10966 2018-07-05 Carl Love <cel@us.ibm.com>
10967
10968 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
10969 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
10970 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
10971 VSX_BUILTIN_DOUBLEL_V4SF.
10972
10973 2018-07-05 Martin Sebor <msebor@redhat.com>
10974
10975 PR c++/86400
10976 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
10977 than its domain to compute its the upper bound of a char array.
10978
10979 2018-07-05 Nathan Sidwell <nathan@acm.org>
10980
10981 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
10982 * doc/cpp.texi: Update comment.
10983 * doc/tm.texi: Rebuilt.
10984 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
10985 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
10986 * doc/extend.texi (Backwards Compatibility): Clarify it is system
10987 headers affected by extern "C".
10988 * system.h: Poison NO_IMPLICIT_EXTERN_C.
10989 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
10990 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
10991 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
10992 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
10993 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
10994 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
10995 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
10996 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
10997 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
10998 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
10999 config/sparc/sp64-elf.h, config/spu/spu.h,
11000 config/stormy16/stormy16.h, config/v850/v850.h,
11001 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
11002 define NO_IMPLICIT_EXTERN_C.
11003 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
11004
11005 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11006
11007 PR target/84711
11008 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
11009 instead of GET_MODE_SIZE when comparing Units.
11010
11011 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11012
11013 PR target/84711
11014 * rtlanal.c (set_noop_p): Constrain on mode change,
11015 include hard-reg-set.h
11016
11017 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11018
11019 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
11020
11021 2018-07-05 Jakub Jelinek <jakub@redhat.com>
11022
11023 Revert
11024 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11025
11026 PR sanitizer/84250
11027 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11028 libasan.
11029 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11030
11031 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11032
11033 PR sanitizer/84250
11034 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11035 libasan.
11036 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11037
11038 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
11039
11040 PR middle-end/86380
11041 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
11042
11043 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
11044
11045 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
11046 neg_*_op* variables.
11047
11048 2018-07-04 Martin Liska <mliska@suse.cz>
11049
11050 * tree-switch-conversion.c: Define
11051 max_ratio_for_speed and max_ratio_for_size constants.
11052
11053 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11054 Martin Liska <mliska@suse.cz>
11055
11056 PR middle-end/66240
11057 PR target/45996
11058 PR c/84100
11059 * common.opt: Rename align options with 'str_' prefix.
11060 * common/config/i386/i386-common.c (set_malign_value): New
11061 function.
11062 (ix86_handle_option): Use it to set -falign-* options/
11063 * config/aarch64/aarch64-protos.h (struct tune_params): Change
11064 type from int to string.
11065 * config/aarch64/aarch64.c: Update default values from int
11066 to string.
11067 * config/alpha/alpha.c (alpha_override_options_after_change):
11068 Likewise.
11069 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
11070 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11071 max skip conditionally.
11072 * config/i386/freebsd.h (SUBALIGN_LOG): New.
11073 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11074 max skip conditionally.
11075 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11076 max skip conditionally.
11077 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
11078 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11079 max skip conditionally.
11080 * config/i386/i386.c (struct ptt): Change type from int to
11081 string.
11082 (ix86_default_align): Set default values.
11083 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
11084 max skip conditionally.
11085 * config/i386/iamcu.h (SUBALIGN_LOG): New.
11086 (ASM_OUTPUT_MAX_SKIP_ALIGN):
11087 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
11088 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11089 max skip conditionally.
11090 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
11091 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
11092 * config/i386/x86-64.h (SUBALIGN_LOG): New.
11093 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11094 max skip conditionally.
11095 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11096 * config/ia64/ia64.c (ia64_option_override): Set default values
11097 for alignment options.
11098 * config/m68k/m68k.c: Handle new str_align_* options.
11099 * config/mips/mips.c (mips_set_compression_mode): Change
11100 type of constants.
11101 (mips_option_override): Set default values for options.
11102 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
11103 Likewise.
11104 * config/rs6000/rs6000.c (rs6000_option_override_internal):
11105 Likewise.
11106 * config/rx/rx.c (rx_option_override): Likewise.
11107 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
11108 (LABEL_ALIGN): Use align_labels_log.
11109 (LOOP_ALIGN): Use align_loops_align.
11110 * config/s390/s390.c (s390_asm_output_function_label): Use new
11111 macros.
11112 * config/sh/sh.c (sh_override_options_after_change):
11113 Change type of constants.
11114 * config/spu/spu.c (spu_sched_init): Likewise.
11115 * config/sparc/sparc.c (sparc_option_override): Set default
11116 values for options.
11117 * config/visium/visium.c (visium_option_override): Likewise.
11118 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
11119 emit p2align format with last argument if it's not needed.
11120 * doc/invoke.texi: Document extended format of -falign-*.
11121 * final.c: Use align_labels alignment.
11122 * flags.h (struct target_flag_state): Change type to use
11123 align_flags.
11124 (struct align_flags_tuple): New.
11125 (struct align_flags): Likewise.
11126 (align_loops_log): Redefine macro to use new types.
11127 (align_loops_max_skip): Redefine macro to use new types.
11128 (align_jumps_log): Redefine macro to use new types.
11129 (align_jumps_max_skip): Redefine macro to use new types.
11130 (align_labels_log): Redefine macro to use new types.
11131 (align_labels_max_skip): Redefine macro to use new types.
11132 (align_functions_log): Redefine macro to use new types.
11133 (align_loops): Redefine macro to use new types.
11134 (align_jumps): Redefine macro to use new types.
11135 (align_labels): Redefine macro to use new types.
11136 (align_functions): Redefine macro to use new types.
11137 (align_functions_max_skip): Redefine macro to use new types.
11138 (align_loops_value): New macro.
11139 (align_jumps_value): New macro.
11140 (align_labels_value): New macro.
11141 (align_functions_value): New macro.
11142 * function.c (invoke_set_current_function_hook): Propagate
11143 alignment values from flags to global variables default in
11144 topleev.h.
11145 * ipa-icf.c (sem_function::equals_wpa): Use
11146 cl_optimization_option_eq instead of memcmp.
11147 * lto-streamer.h (cl_optimization_stream_out): Support streaming
11148 of string types.
11149 (cl_optimization_stream_in): Likewise.
11150 * optc-save-gen.awk: Support strings in cl_optimization.
11151 * opth-gen.awk: Likewise.
11152 * opts.c (finish_options): Remove error checking of invalid
11153 value ranges.
11154 (MAX_CODE_ALIGN): Remove.
11155 (MAX_CODE_ALIGN_VALUE): Likewise.
11156 (parse_and_check_align_values): New function.
11157 (check_alignment_argument): Likewise.
11158 (common_handle_option): Use check_alignment_argument.
11159 * opts.h (parse_and_check_align_values): Declare.
11160 * toplev.c (init_alignments): Remove.
11161 (read_log_maxskip): New.
11162 (parse_N_M): Likewise.
11163 (parse_alignment_opts): Likewise.
11164 (backend_init_target): Remove usage of init_alignments.
11165 * toplev.h (parse_alignment_opts): Declare.
11166 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
11167 argument.
11168 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
11169 * tree.c (cl_option_hasher::equal): New.
11170 * varasm.c: Use new global macros.
11171
11172 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11173
11174 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
11175 Use a simpler align directive also if MAXSKIP = ALIGN-1.
11176 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11177 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11178 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11179 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11180 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
11181 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
11182 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
11183 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11184 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11185 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11186 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11187
11188 2018-07-04 Martin Liska <mliska@suse.cz>
11189 Jonathan Wakely <jwakely@redhat.com>
11190
11191 * coverage.c: Use correct type.
11192 * doc/invoke.texi: Language correction.
11193
11194 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
11195
11196 PR target/85620
11197 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
11198 ENDBRANCH for non-tail call which may return via indirect branch.
11199 * doc/extend.texi: Document indirect_return attribute.
11200
11201 2018-07-03 Martin Sebor <msebor@redhat.com>
11202
11203 PR tree-optimization/86274
11204 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
11205 precondition.
11206 (format_floating): Correct handling of infinities and NaNs.
11207
11208 2018-07-03 Martin Sebor <msebor@redhat.com>
11209
11210 * print-tree.c (print_real_cst): New function.
11211 (print_node_brief): Call it.
11212 (print_node): Ditto.
11213
11214 2018-07-03 Jeff Law <law@redhat.com>
11215
11216 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
11217 into a single pattern.
11218
11219 * config/h8300/h8300.md (ors code_iterator): New.
11220 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
11221 a single pattern and single splitter.
11222 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
11223 (iorqi3_1, xorqi3_1): Likewise.
11224 (iorqi3, xorqi3 expanders): Similarly.
11225
11226 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
11227 (movmd_internal) into a single pattern using the P mode iterator.
11228 (movmd splitters): Similarly.
11229 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
11230 (movsd splitters): Similarly.
11231
11232 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
11233 ADDB, ADDW and ADDL into a single ADD attribute which selects the
11234 right table based on the size of the operand.
11235 * config/h8300/h8300.md (length_table): Corresponding changes. All
11236 references to "addb", "addw" and "addl" changed to "add".
11237 (btst patterns): Merge two variants into a single pattern.
11238 (tstqi, tsthi): Likewise.
11239 (addhi3_incdec, addsi3_incdec): Likewise.
11240 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
11241 (mulhi3, mulsi3): Likewise.
11242 (udivhi3, udivsi3): Likewise.
11243 (divhi3, divsi3): Likewise.
11244 (andorqi3, andorhi3, andorsi3): Likewise.
11245
11246 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
11247
11248 PR target/85694
11249 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
11250 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
11251
11252 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11253
11254 PR tree-optimization/85694
11255 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
11256 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
11257 UNSPEC_URHADD.
11258 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
11259 (<u>avg<mode>3_ceil): New patterns.
11260
11261 2018-07-03 David Malcolm <dmalcolm@redhat.com>
11262
11263 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
11264 scan-tree-dump directive.
11265 * gcc.dg/vect/slp-perm-2.c: Likewise.
11266 * gcc.dg/vect/slp-perm-3.c: Likewise.
11267 * gcc.dg/vect/slp-perm-5.c: Likewise.
11268 * gcc.dg/vect/slp-perm-6.c: Likewise.
11269 * gcc.dg/vect/slp-perm-7.c: Likewise.
11270 * gcc.dg/vect/slp-perm-8.c: Likewise.
11271
11272 2018-07-03 Marek Polacek <polacek@redhat.com>
11273
11274 PR middle-end/86202
11275 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
11276
11277 2018-07-03 Richard Biener <rguenther@suse.de>
11278
11279 PR ipa/86389
11280 * tree-ssa-structalias.c (find_func_clobbers): Properly
11281 handle indirect calls.
11282
11283 2018-07-03 Jeff Law <law@redhat.com>
11284
11285 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
11286 (shifts): New code iterator.
11287 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
11288 expander. Fix HImode handling on H8/SX.
11289 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
11290 (subqi3, subhi3, subsi3 expanders): Likewise.
11291 (andqi3, andhi3, andsi3 expanders): Likewise.
11292 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
11293 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
11294 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
11295 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
11296 (zero_extendqihi2, zero_extendqisi2): Likewise.
11297 (extendqihi2, extendqisi2): Likewise.
11298 (rotlqi3, rotlhi3, rotlsi3): Likewise.
11299 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
11300 (rotlqi3_1, rotlhi3_1): Likewise.
11301 (logicalhi3_sn, logicalsi3_sn): Likewise.
11302 (logicalhi3, logicalsi3): Likewise.
11303
11304 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11305
11306 * tree-vect-patterns.c (vect_recog_rotate_pattern)
11307 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11308 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
11309 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
11310 type to append_pattern_def_seq instead of creating a stmt_vec_info
11311 directly.
11312 (build_mask_conversion): Likewise. Remove vinfo argument.
11313 (vect_add_conversion_to_patterm): Likewise, renaming to...
11314 (vect_add_conversion_to_pattern): ...this.
11315 (vect_recog_mask_conversion_pattern): Update call to
11316 build_mask_conversion. Pass the vector type to
11317 append_pattern_def_seq here too.
11318 (vect_recog_gather_scatter_pattern): Update call to
11319 vect_add_conversion_to_pattern.
11320
11321 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11322
11323 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
11324 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11325 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
11326 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
11327 STMT_VINFO_PATTERN_DEF_SEQ to null here.
11328 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
11329 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
11330 append_pattern_def_seq instead of new_pattern_def_seq.
11331 (vect_recog_divmod_pattern): Do both of the above.
11332 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
11333 is null.
11334
11335 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11336
11337 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
11338 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
11339 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
11340 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
11341 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
11342 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11343 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
11344 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
11345 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
11346 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
11347 parameter with a single stmt_vec_info.
11348 (vect_recog_func_ptr): Likewise.
11349 (vect_recog_gather_scatter_pattern): Likewise, folding in...
11350 (vect_try_gather_scatter_pattern): ...this.
11351 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
11352 the stmt_vec_info of the statement to be matched. Don't clear
11353 STMT_VINFO_RELATED_STMT.
11354 (vect_pattern_recog): Update call accordingly.
11355
11356 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11357
11358 PR tree-optimization/85694
11359 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
11360 (uavgM3_ceil): Document new optabs.
11361 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
11362 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
11363 functions.
11364 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
11365 (savg_ceil_optab): New optabs.
11366 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
11367 (vect_vect_recog_func_ptrs): Add it.
11368 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
11369 constant directly from the associated lhs.
11370
11371 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11372
11373 * tree-vect-patterns.c (vect_split_statement): New function.
11374 (vect_convert_input): Use it to try to split an existing cast.
11375
11376 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11377
11378 * poly-int.h (print_hex): New function.
11379 * dumpfile.h (dump_dec, dump_hex): Declare.
11380 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
11381 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
11382 min_input_precision, operation_precision and operation_sign.
11383 * tree-vect-patterns.c (vect_get_range_info): New function.
11384 (vect_same_loop_or_bb_p, vect_single_imm_use)
11385 (vect_operation_fits_smaller_type): Delete.
11386 (vect_look_through_possible_promotion): Add an optional
11387 single_use_p parameter.
11388 (vect_recog_over_widening_pattern): Rewrite to use new
11389 stmt_vec_info infomration. Handle one operation at a time.
11390 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
11391 (vect_truncatable_operation_p, vect_set_operation_type)
11392 (vect_set_min_input_precision): New functions.
11393 (vect_determine_min_output_precision_1): Likewise.
11394 (vect_determine_min_output_precision): Likewise.
11395 (vect_determine_precisions_from_range): Likewise.
11396 (vect_determine_precisions_from_users): Likewise.
11397 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
11398 (vect_vect_recog_func_ptrs): Put over_widening first.
11399 Add cast_forwprop.
11400 (vect_pattern_recog): Call vect_determine_precisions.
11401
11402 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11403
11404 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
11405 statements that have been replaced by further pattern statements.
11406 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
11407
11408 2018-07-03 Richard Biener <rguenther@suse.de>
11409
11410 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
11411 always set *dt. Dump vectype in vectype overload.
11412 * dumpfile.h (dump_gimple_expr): New function.
11413 (dump_gimple_expr_loc): Likewise.
11414 * dumpfile.c (dump_gimple_expr): New function.
11415 (dump_gimple_expr_loc): Likewise.
11416
11417 2018-07-02 Jeff Law <law@redhat.com>
11418
11419 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
11420 the H8/300, H8/300H and H8/S variants into a single pattern.
11421 (movhi_h8300, movqi_h8300hs): Similarly.
11422 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
11423 (QHI mode iterator): New.
11424
11425 * config/h8300/h8300.md: Remove trailing whitespace.
11426
11427 2018-07-02 Jim Wilson <jimw@sifive.com>
11428
11429 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
11430 instead of emit_insn for interrupt returns.
11431 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
11432 (riscv_sret, riscv_uret): Likewise.
11433
11434 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11435
11436 * pretty-print.c (selftest::test_pp_format): Move save and restore
11437 of quotes to class auto_fix_quotes, and add an instance.
11438 * selftest.c: Include "intl.h".
11439 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
11440 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
11441 * selftest.h (selftest::auto_fix_quotes): New class.
11442
11443 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
11444
11445 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
11446 (aarch64_sve_prepare_conditional_op): Remove.
11447 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
11448 Allow aarch64_simd_reg_or_zero as select operand; remove
11449 the aarch64_sve_prepare_conditional_op call.
11450 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
11451 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11452 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
11453 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
11454 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
11455 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
11456 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
11457 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
11458 and a splitters to match all of the *_any patterns.
11459 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
11460
11461 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
11462 (SVE_COND_FP_BINARY_REV): Remove.
11463 (sve_int_op_rev, sve_fp_op_rev): New.
11464 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
11465 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
11466 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
11467 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
11468 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
11469 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
11470 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
11471 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
11472 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
11473
11474 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
11475 Remove match_dup 1 from the inner unspec.
11476 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11477
11478 * config/aarch64/aarch64.md (movprfx): New attr.
11479 (length): Default movprfx to 8.
11480 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
11481 (*madd<SVE_I>, *msub<SVE_I): Likewise.
11482 (*<su>mul<SVE_I>3_highpart): Likewise.
11483 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
11484 (*v<ASHIFT><SVE_I>3): Likewise.
11485 (*<su><MAXMIN><SVE_I>3): Likewise.
11486 (*<su><MAXMIN><SVE_F>3): Likewise.
11487 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
11488 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
11489 (*div<SVE_F>4): Likewise.
11490
11491 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
11492
11493 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
11494 in dump string.
11495
11496 2018-07-02 Richard Biener <rguenther@suse.de>
11497
11498 PR tree-optimization/86363
11499 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
11500 memset argument refers to a non-variable address.
11501
11502 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11503
11504 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
11505 {PLUS,MINUS}_EXPR code to...
11506 (adjust_symbolic_bound): ...here,
11507 (combine_bound): ...here,
11508 (set_value_range_with_overflow): ...and here.
11509
11510 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11511
11512 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
11513 code...
11514 (extract_range_from_abs_expr): ...here.
11515
11516 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
11517
11518 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
11519 -fno-omit-frame-pointer when not optimizing.
11520
11521 2018-07-02 Martin Liska <mliska@suse.cz>
11522
11523 PR ipa/86279
11524 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
11525 (propagate_nothrow): Likewise.
11526
11527 2018-07-02 Martin Liska <mliska@suse.cz>
11528
11529 PR ipa/86323
11530 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
11531
11532 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11533
11534 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
11535 function in r262149, changing "loc" param from source_location to
11536 const dump_location_t &.
11537 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
11538 declaration, as above.
11539
11540 2018-07-01 Paul Koning <ni1d@arrl.net>
11541
11542 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
11543 -munit-asm, -mgnu-asm, -mdec-asm.
11544 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
11545 (pdp11_output_labelref): New.
11546 (pdp11_output_def): New.
11547 (pdp11_output_addr_vec_elt): New.
11548 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
11549 %# and %@ format codes.
11550 (pdp11_option_override): New.
11551 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
11552 (pdp11_output_ident): New.
11553 (pdp11_asm_named_section): New.
11554 (pdp11_asm_init_sections): New.
11555 (pdp11_file_start): New.
11556 (pdp11_file_end): New.
11557 (output_ascii): Use .ascii/.asciz for -mdec-asm.
11558 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
11559 %o, like %c but octal.
11560 (pdp11_option_override): New.
11561 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
11562 -mdec-asm.
11563 (DATA_SECTION_ASM_OP): Ditto.
11564 (READONLY_DATA_SECTION_ASM_OP): New.
11565 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
11566 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
11567 (ASM_OUTPUT_LABELREF): Ditto.
11568 (ASM_OUTPUT_DEF): Ditto.
11569 (ASM_OUTPUT_EXTERNAL): New.
11570 (ASM_OUTPUT_SOURCE_FILENAME): New.
11571 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
11572 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
11573 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
11574 %# and %@ format codes.
11575 * config/pdp11/pdp11.opt (mgnu-asm): New.
11576 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
11577 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
11578 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
11579
11580 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
11581
11582 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
11583 dereferencing path[] beyond its length.
11584 (debug_path): New.
11585 (debug_all_paths): New.
11586 (rewire_first_differing_edge): New.
11587 (adjust_paths_after_duplication): New.
11588 (duplicate_thread_path): Call adjust_paths_after_duplication.
11589 Add new argument.
11590 (thread_through_all_blocks): Add new argument to
11591 duplicate_thread_path.
11592
11593 2018-06-30 Jim Wilson <jimw@sifive.com>
11594
11595 * config/riscv/predicates.md (p2m1_shift_operand): New.
11596 (high_mask_shift_operand): New.
11597 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
11598 pattern using p2m1_shift_operand.
11599 (lshsi3_zero_extend_3+2): New combiner pattern using
11600 high_mask_shift_operand.
11601
11602 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11603
11604 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
11605 split out from...
11606 (vect_recog_rotate_pattern): ...here.
11607 (vect_convert_input): Try to insert casts of invariants in the
11608 preheader.
11609 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
11610 preheader to be empty.
11611
11612 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11613
11614 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
11615 vector type. If given, install it in the new statement's
11616 STMT_VINFO_VECTYPE.
11617 (vect_element_precision): New function.
11618 (vect_unpromoted_value): New struct.
11619 (vect_unpromoted_value::vect_unpromoted_value): New function.
11620 (vect_unpromoted_value::set_op): Likewise.
11621 (vect_look_through_possible_promotion): Likewise.
11622 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
11623 (vect_widened_op_tree, vect_convert_input): Likewise.
11624 (vect_convert_inputs, vect_convert_output): Likewise.
11625 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
11626 to handle the optional cast of the multiplication result and
11627 vect_widened_op_tree to detect the widened multiplication itself.
11628 Do not require the input and output of promotion casts to have
11629 the same sign, but base the signedness of the operation on the
11630 input rather than the result. If the pattern includes two
11631 promotions, check that those promotions have the same sign.
11632 Do not restrict the MULT_EXPR handling to a double-width result;
11633 handle quadruple-width results and wider. Use vect_convert_inputs
11634 to convert the inputs to the common type.
11635 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
11636 to handle the optional cast of the ABS result. Also allow a sign
11637 change or a sign extension between the ABS and MINUS.
11638 Use vect_widened_op_tree to detect the widened subtraction and use
11639 vect_convert_inputs to convert the inputs to the common type.
11640 (vect_handle_widen_op_by_const): Delete.
11641 (vect_recog_widen_op_pattern): New function.
11642 (vect_recog_widen_mult_pattern): Use it.
11643 (vect_recog_widen_shift_pattern): Likewise.
11644 (vect_recog_widen_sum_pattern): Use
11645 vect_look_through_possible_promotion to handle the promoted
11646 PLUS_EXPR operand.
11647
11648 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11649
11650 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
11651 the containing gimple_seq *.
11652 * gimple-iterator.h (gsi_for_stmt): Declare it.
11653 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
11654 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
11655 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11656 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11657 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
11658 checks.
11659 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
11660 split out from...
11661 (vect_mark_pattern_stmts): ...here. Handle cases in which the
11662 statement being replaced is part of an existing pattern
11663 definition sequence, inserting the new pattern statements before
11664 the original one.
11665 (vect_pattern_recog_1): Don't return a bool. If the statement
11666 is already part of a pattern, instead apply pattern matching
11667 to the pattern definition statements. Don't clear the
11668 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
11669 (vect_pattern_recog): Don't break after the first match;
11670 continue processing the pattern definition statements instead.
11671 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
11672
11673 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11674
11675 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
11676 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11677 (vect_recog_widen_sum_pattern): Use it.
11678
11679 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11680
11681 * tree-vect-loop.c (vectorizable_reduction): Assert that the
11682 phi is not a pattern statement and has not been replaced by
11683 a pattern statement.
11684 * tree-vect-patterns.c (type_conversion_p): Don't check
11685 STMT_VINFO_IN_PATTERN_P.
11686 (vect_recog_vector_vector_shift_pattern): Likewise.
11687 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
11688 the pattern statement rather than the original statement; check
11689 directly for a WIDEN_MULT_EXPR here.
11690 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
11691 vect_is_simple_use to return the pattern statement rather
11692 than the original statement; use is_pattern_stmt_p to check
11693 for such a pattern statement.
11694 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
11695 to return the pattern statement rather than the original statement;
11696 don't do the same transformation here.
11697 (vect_is_simple_use): If the defining statement has been replaced
11698 by a pattern statement, return the pattern statement instead.
11699 Remove the corresponding (local) transformation from the vectype
11700 overload.
11701
11702 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11703
11704 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
11705 end and default to null.
11706 * tree-vect-loop.c (vect_create_epilog_for_reduction)
11707 (vectorizable_reduction): Update calls accordingly, dropping the
11708 gimple ** argument if the passed-back statement isn't needed.
11709 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
11710 (vect_recog_rotate_pattern): Likewise.
11711 (vect_recog_mask_conversion_pattern): Likewise.
11712 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
11713 (vect_mask_constant_operand_p): Likewise.
11714 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
11715 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
11716 (get_group_load_store_type, get_load_store_type): Likewise.
11717 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
11718 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
11719 (vectorizable_conversion, vectorizable_assignment): Likewise.
11720 (vectorizable_shift, vectorizable_operation): Likewise.
11721 (vectorizable_store, vect_is_simple_cond): Likewise.
11722 (vectorizable_condition, vectorizable_comparison): Likewise.
11723 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
11724 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
11725 and move it to the end. Cope with null def_stmt_outs.
11726
11727 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
11728
11729 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
11730
11731 2018-06-29 Jeff Law <law@redhat.com>
11732
11733 * config/v850/v850.c (v850_legitimate_address_p): Handle large
11734 displacements for TARGET_V850E2V3 and newer.
11735 (TARGET_LRA_P): Remove. Defaults to LRA now.
11736 * config/v850/v850.md (sign23byte_load): Remove.
11737 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
11738 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
11739
11740 2018-06-29 Martin Liska <mliska@suse.cz>
11741
11742 PR lto/85759
11743 * coverage.c (coverage_init): Mangle full path name.
11744 * doc/invoke.texi: Document the change.
11745 * gcov-io.c (mangle_path): New.
11746 * gcov-io.h (mangle_path): Likewise.
11747 * gcov.c (mangle_name): Use mangle_path for path mangling.
11748
11749 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11750
11751 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
11752 if starting source register is not even.
11753
11754 2018-06-29 Martin Liska <mliska@suse.cz>
11755
11756 PR tree-optimization/86263
11757 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
11758 Make edge redirection.
11759
11760 2018-06-29 David Malcolm <dmalcolm@redhat.com>
11761
11762 * dumpfile.c (dump_loc): Add indentation based on scope depth.
11763 (dump_scope_depth): New variable.
11764 (get_dump_scope_depth): New function.
11765 (dump_begin_scope): New function.
11766 (dump_end_scope): New function.
11767 * dumpfile.h (get_dump_scope_depth): New declaration.
11768 (dump_begin_scope): New declaration.
11769 (dump_end_scope): New declaration.
11770 (class auto_dump_scope): New class.
11771 (AUTO_DUMP_SCOPE): New macro.
11772 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
11773 AUTO_DUMP_SCOPE.
11774
11775 2018-06-29 Richard Biener <rguenther@suse.de>
11776
11777 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
11778 compute_all_dependences succeeds.
11779 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
11780 exceed --param loop-max-datarefs-for-datadeps.
11781
11782 2018-06-29 Jakub Jelinek <jakub@redhat.com>
11783
11784 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
11785
11786 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
11787
11788 PR target/86348
11789 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
11790 alternative 0 in preferred_for_speed attribute.
11791
11792 2018-06-28 Paul Koning <ni1d@arrl.net>
11793
11794 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
11795 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
11796 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
11797 * config/pdp11/pdp11.md: Correct "length" attribute calculation
11798 for shift insn patterns.
11799
11800 2018-06-28 David Malcolm <dmalcolm@redhat.com>
11801
11802 * cgraph.c (cgraph_node::get_body): Replace assignments to
11803 "dump_file" with calls to set_dump_file.
11804 * dumpfile.c (alt_dump_file): Make static, and group with...
11805 (alt_flags): ...this definition.
11806 (dumps_are_enabled): New variable.
11807 (refresh_dumps_are_enabled): New function.
11808 (set_dump_file): New function.
11809 (set_alt_dump_file): New function.
11810 (gcc::dump_manager::dump_start): Replace assignments to
11811 "dump_file" and "alt_dump_file" with calls to set_dump_file and
11812 set_alt_dump_file.
11813 (gcc::dump_manager::dump_finish): Likewise.
11814 * dumpfile.h (alt_dump_file): Delete decl.
11815 (dumps_are_enabled): New variable decl.
11816 (set_dump_file): New function decl.
11817 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
11818 global.
11819 * tree-nested.c (lower_nested_functions): Replace assignments to
11820 "dump_file" with calls to set_dump_file.
11821
11822 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
11823
11824 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
11825 goto_locus of each outgoing edge of each basic block.
11826
11827 2018-06-28 Richard Biener <rguenther@suse.de>
11828
11829 * dwarf2out.c (decl_scope_table): Remove.
11830 (push_decl_scope): Likewise.
11831 (pop_decl_scope): Likewise.
11832 (gen_type_die_for_member): Do not call push/pop_decl_scope.
11833 (gen_struct_or_union_type_die): Likewise.
11834 (gen_tagged_type_die): Likewise.
11835 (dwarf2out_init): Do not initialize decl_scope_table.
11836 (dwarf2out_c_finalize): Do not free it.
11837
11838 2018-06-28 Richard Biener <rguenther@suse.de>
11839
11840 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
11841 deciding whether to not re-use a DIE.
11842
11843 2018-06-28 Richard Biener <rguenther@suse.de>
11844
11845 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
11846 DW_AT_abstract_origin attribute.
11847
11848 2018-06-28 Martin Liska <mliska@suse.cz>
11849
11850 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
11851 Use newly introduced constants.
11852 * tree-switch-conversion.h (struct jump_table_cluster):
11853 Define max_ratio_for_size and max_ratio_for_speed.
11854
11855 2018-06-28 Martin Liska <mliska@suse.cz>
11856
11857 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
11858 Add new checking assert to catch invalid state.
11859 (jump_table_cluster::can_be_handled): Handle single case
11860 clusters.
11861 (jump_table_cluster::is_beneficial): Bail out for such case.
11862 (bit_test_cluster::find_bit_tests):
11863 Add new checking assert to catch invalid state.
11864 (bit_test_cluster::can_be_handled): Handle single case
11865 clusters.
11866 (bit_test_cluster::is_beneficial): Bail out for such case.
11867 (switch_decision_tree::analyze_switch_statement):
11868 Fix comment.
11869
11870 2018-06-28 Martin Liska <mliska@suse.cz>
11871
11872 * common.opt: Introduce -completion option.
11873 * gcc.c (driver_handle_option): Handle it.
11874 (driver::main): Print completions if completion
11875 is set.
11876 * opt-suggestions.c (option_proposer::get_completions):
11877 New function.
11878 (option_proposer::suggest_completion): Likewise.
11879 (option_proposer::find_param_completions): Likewise.
11880 (verify_autocompletions): Likewise.
11881 (test_completion_valid_options): Likewise.
11882 (test_completion_valid_params): Likewise.
11883 (in_completion_p): Likewise.
11884 (empty_completion_p): Likewise.
11885 (test_completion_partial_match): Likewise.
11886 (test_completion_garbage): Likewise.
11887 (opt_proposer_c_tests): Likewise.
11888 * opt-suggestions.h: Declare new functions.
11889 * opts.c (common_handle_option): Handle OPT__completion_.
11890 * selftest-run-tests.c (selftest::run_tests): Add
11891 opt_proposer_c_tests.
11892 * selftest.c (assert_str_startswith): New.
11893 * selftest.h (assert_str_startswith): Likewise.
11894 (opt_proposer_c_tests): New.
11895 (ASSERT_STR_STARTSWITH): Likewise.
11896
11897 2018-06-28 Martin Liska <mliska@suse.cz>
11898
11899 * Makefile.in: Add opt-suggestions.o.
11900 * gcc-main.c: Include opt-suggestions.h.
11901 * gcc.c (driver::driver): Likewise.
11902 (driver::~driver): Remove m_option_suggestions.
11903 (driver::build_option_suggestions): Moved to option_proposer.
11904 (driver::suggest_option): Likewise.
11905 (driver::handle_unrecognized_options): Use option_proposer.
11906 * gcc.h (class driver): Add new memver m_option_proposer.
11907 * opt-suggestions.c: New file.
11908 * opt-suggestions.h: New file.
11909
11910 2018-06-28 Martin Liska <mliska@suse.cz>
11911
11912 * vec.h (class auto_string_vec): New (moved from auto_argvec).
11913 (auto_string_vec::~auto_string_vec): Likewise.
11914
11915 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
11916
11917 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
11918 prevent_decl_creation_for_types fields up and add reset_location field.
11919 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
11920 statement if id->reset_location is true.
11921 (copy_edges_for_bb): Do not set goto_locus on the new edges if
11922 id->reset_location is true.
11923 (copy_phis_for_bb): Force input_location on the arguments if
11924 id->reset_location is true.
11925 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
11926 is set on the function to be inlined.
11927
11928 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
11929
11930 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
11931
11932 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
11933
11934 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
11935 registers for Pmode.
11936 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
11937 hard registers for the clobbered pseudo.
11938
11939 2018-06-27 Paul Koning <ni1d@arrl.net>
11940
11941 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
11942 mutually exclusive options.
11943 * config/pdp11/constraints.md (h): New constraint.
11944 (O): Update definition to match shift code generation.
11945 (D): New constraint.
11946 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
11947 (CCFP): Remove.
11948 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
11949 function.
11950 (output_jump): Change arguments.
11951 (pdp11_fixed_cc_regs): New function.
11952 (pdp11_cc_mode): Ditto.
11953 (pdp11_expand_shift): Ditto.
11954 (pdp11_assemble_shift): Ditto.
11955 (pdp11_small_shift): Ditto.
11956 (pdp11_branch_cost): Remove.
11957 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
11958 from output.
11959 (pdp11_register_move_cost): Update for CC registers.
11960 (pdp11_rtx_costs): Add case for LSHIFTRT.
11961 (pdp11_output_jump): Add CCNZ mode conditional branches.
11962 (notice_update_cc_on_set): Remove.
11963 (pdp11_cc_mode): New function.
11964 (simple_memory_operand): Correct pre/post decrement case.
11965 (no_side_effect_operand): New function.
11966 (pdp11_regno_reg_class): Add CC_REGS class.
11967 (pdp11_fixed_cc_regs): New function.
11968 (pdp11_small_shift): New function.
11969 (pdp11_expand_shift): New function to expand shift insns.
11970 (pdp11_assemble_shift): New function to output shifts.
11971 (pdp11_branch_cost): Remove.
11972 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
11973 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
11974 (WCHAR_TYPE): Ditto.
11975 (PTRDIFF_TYPE): Ditto.
11976 (ADJUST_INSN_LENGTH): New macro.
11977 (FIXED_REGISTERS): Add CC registers.
11978 (CALL_USED_REGISTERS): Ditto.
11979 (reg_class): Ditto.
11980 (REG_CLASS_NAMES): Ditto.
11981 (REG_CLASS_CONTENTS): Ditto.
11982 (SELECT_CC_MODE): Use new function.
11983 (TARGET_FLAGS_REGNUM): New macro.
11984 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
11985 (cc0_reg_rtx): Remove.
11986 (CC_STATUS_MDEP): Remove.
11987 (CC_STATUS_MDEFP_INIT): Remove.
11988 (CC_IN_FPU): Remove.
11989 (NOTICE_UPDATE_CC): Remove.
11990 (REGISTER_NAMES): Add CC registers.
11991 (BRANCH_COST): Change to constant 1.
11992 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
11993 handling.
11994 * config/pdp11/pdp11.opt (mbcopy): Remove.
11995 (mbcopy-builtin): Remove.
11996 (mbranch-cheap): Remove.
11997 (mbranch-expensive): Remove.
11998 * config/pdp11/predicates.md (expand_shift_operand): Update to
11999 match shift code generation.
12000 (ccnz_operator): New predicate.
12001 * doc/invoke.texi (PDP-11 Options): Remove deleted options
12002 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
12003 Remove non-existent option -mabshi, -mno-abshi. Document mutually
12004 exclusive options.
12005 * doc/md.texi (PDP-11): Document new D and h constraints. Update
12006 description of O constraint.
12007
12008 2018-06-27 Jeff Law <law@redhat.com>
12009 Austin Law <austinklaw@gmail.com>
12010
12011 * config/v850/v850.md (addsi3_set_flags): New pattern.
12012 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
12013 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
12014 (zero_extendhisi2_v850_set_flags): Likewise.
12015 (zero_extendqisi2_v850_set_flags): Likewise.
12016 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
12017 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
12018 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
12019
12020 * config/v850/v850-protos.h (notice_update_cc): Remove.
12021 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
12022 (v850_print_operand): Handle 'D' and "d".
12023 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
12024 Add handling of arithmetic/logical operations compared against zero.
12025 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
12026 Do not look at v850_compare_op, instead get mode from last argument.
12027 (v850_gen_compare): Remove
12028 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
12029 after reload for prologue insns.
12030 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
12031 patterns.
12032 (construct_save_jarl): Likewise.
12033 (TARGET_FLAGS_REGNUM): Define.
12034 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
12035 (NOTICE_UPDATE_CC): Remove.
12036 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
12037 than cc0. Conditionalize on reload_completed.
12038 (cmpsi_insn, setfcc_insn): Likewise.
12039 (tst1 splitter): Turn into define_and_split which sets the flags
12040 after reload.
12041 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
12042 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
12043 (cstoresf4, cstoredf4): Clobber the flags.
12044 (cmpsi, cmpsf, cmpdf): Remove expanders.
12045 (setf_insn): Remove pattern.
12046 (addsi3): Turn into define_and_split which clobbers the flags after
12047 reload and a suitable pattern (addsi3_clobber_flags) for use after
12048 reload.
12049 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
12050 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
12051 (ashrsi3, ashrsi3_v850e2): Likewise.
12052 (bins): Clobber the flags.
12053 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
12054 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
12055 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
12056 (call_value_internal_short, call_value_internal_long): Likewise.
12057 (callt_save_interrupt, callt_return_interrupt): Likewise.
12058 (save_interrupt, return_interrupt): Likewise.
12059 (callt_save_all_interrupt, save_all_interrupt): Likewise.
12060 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
12061 (restore_all_interrupt, _restore_all_interrupt): Likewise.
12062 (All FP comparisons): Only allow after reload has completed.
12063 (trfsr): Likewise.
12064 (divh, divhu): Tweak output template.
12065 (branch_z_normal, branch_z_invert): Remove
12066 (branch_nz_normal, branch_nz_invert): Likewise.
12067 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
12068
12069 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
12070 * config/v850/v850.c (notice_update_cc): Remove.
12071 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
12072 (CC_NO_CARRY): Likewise.
12073 (NOTICE_UPDATE_CC): Define to nothing.
12074 * config/v850/v850.md: Remove block comment on cc0 handling
12075 Remove "cc" attribute from all patterns. Remove cc_status handling
12076 from all patterns. Minor formatting fixes.
12077
12078 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12079
12080 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
12081 (cortex-a76.cortex-a55): Likewise.
12082 * config/aarch64/aarch64-tune.md: Regenerate.
12083 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
12084 cortex-a76.cortex-a55.
12085
12086 2018-06-27 Jeff Law <law@redhat.com>
12087
12088 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
12089 (MULTILIB_DIRNAMES): Similarly.
12090
12091 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
12092
12093 * gimple.h (gimple_return_retbnd): Delete.
12094 (gimple_return_set_retbnd): Likewise.
12095 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
12096 gimple_return_set_retbnd.
12097 * gimple-pretty-print.c (dump_gimple_return): Remove call to
12098 gimple_return_retbnd and adjust.
12099 * tree-inline.h (struct copy_body_data): Remove retbnd field.
12100 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
12101 Explicitly return NULL in a couple more cases. Move assertion
12102 on debug statements and remove unreachable code.
12103 (reset_debug_binding): Do not test id->retbnd.
12104 (expand_call_inline): Do not set it.
12105
12106 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12107
12108 * configure.ac: Add --disable-gcov option.
12109 * configure: Regenerate.
12110 * Makefile.in: Honour @enable_gcov@.
12111 * doc/install.texi: Document --disable-gcov.
12112
12113 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12114
12115 * config/arm/arm-cpus.in (cortex-a76): New entry.
12116 (cortex-a76.cortex-a55): Likewise.
12117 * config/arm/arm-tables.opt: Regenerate.
12118 * config/arm/arm-tune.md: Likewise.
12119 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
12120 * doc/invoke.texi (ARM Options): Document cortex-a76 and
12121 cortex-a76.cortex-a55.
12122
12123 2018-06-27 Tamar Christina <tamar.christina@arm.com>
12124
12125 PR target/85769
12126 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
12127
12128 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
12129
12130 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
12131 comment.
12132 (EPILOGUE_USES): Likewise.
12133
12134 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
12135
12136 * tree-inline.c (remap_location): New function extracted from...
12137 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
12138 (copy_phis_for_bb): ...here. Call remap_location.
12139 (copy_cfg_body): Adjust call to copy_edges_for_bb.
12140
12141 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
12142
12143 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
12144 unaligned vsx for 16B memset.
12145
12146 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
12147
12148 PR target/86285
12149 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
12150 ieee128_float_type_node to long_double_type_node unless
12151 TARGET_LONG_DOUBLE_128 is set.
12152
12153 2018-06-26 David Malcolm <dmalcolm@redhat.com>
12154
12155 * cfgloop.c (get_loop_location): Convert return type from
12156 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
12157 by implicit construction from rtx_insn *, and using
12158 dump_user_location_t::from_function_decl for the fallback case.
12159 * cfgloop.h (get_loop_location): Convert return type from
12160 location_t to dump_user_location_t.
12161 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
12162 dump_printf_loc to pass in a dump_location_t rather than a
12163 location_t, via the gimple stmt.
12164 * coverage.c (get_coverage_counts): Update calls to
12165 dump_printf_loc to pass in dump_location_t rather than a
12166 location_t.
12167 * doc/optinfo.texi (Dump types): Convert example of
12168 dump_printf_loc from taking "locus" to taking "insn". Update
12169 description of the "_loc" calls to cover dump_location_t.
12170 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
12171 "selftest.h".
12172 (dump_user_location_t::dump_user_location_t): New constructors,
12173 from gimple *stmt and rtx_insn *.
12174 (dump_user_location_t::from_function_decl): New function.
12175 (dump_loc): Make static.
12176 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
12177 const dump_location_t &.
12178 (dump_generic_expr_loc): Delete.
12179 (dump_printf_loc): Convert param "loc" from location_t to
12180 const dump_location_t &.
12181 (selftest::test_impl_location): New function.
12182 (selftest::dumpfile_c_tests): New function.
12183 * dumpfile.h: Include "profile-count.h".
12184 (class dump_user_location_t): New class.
12185 (struct dump_impl_location_t): New struct.
12186 (class dump_location_t): New class.
12187 (dump_printf_loc): Convert 2nd param from source_location to
12188 const dump_location_t &.
12189 (dump_generic_expr_loc): Delete.
12190 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
12191 const dump_location_t &.
12192 * gimple-fold.c (fold_gimple_assign): Update call to
12193 dump_printf_loc to pass in a dump_location_t rather than a
12194 location_t, via the gimple stmt.
12195 (gimple_fold_call): Likewise.
12196 * gimple-loop-interchange.cc
12197 (loop_cand::analyze_iloop_reduction_var): Update for change to
12198 check_reduction_path.
12199 (tree_loop_interchange::interchange): Update for change to
12200 find_loop_location.
12201 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
12202 change in return-type of find_loop_location.
12203 (graphite_regenerate_ast_isl): Likewise.
12204 * graphite-optimize-isl.c (optimize_isl): Likewise.
12205 * graphite.c (graphite_transform_loops): Likewise.
12206 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
12207 pass in a dump_location_t rather than a location_t, via the
12208 gimple stmt.
12209 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
12210 * ipa.c (walk_polymorphic_call_targets): Likewise.
12211 * loop-unroll.c (report_unroll): Convert "locus" param from
12212 location_t to dump_location_t.
12213 (decide_unrolling): Update for change to get_loop_location's
12214 return type.
12215 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
12216 location_t to dump_user_location_t.
12217 (grid_find_single_omp_among_assignments_1): Updates calls to
12218 dump_printf_loc to pass in a dump_location_t rather than a
12219 location_t, via the gimple stmt.
12220 (grid_parallel_clauses_gridifiable): Convert "tloc" from
12221 location_t to dump_location_t. Updates calls to dump_printf_loc
12222 to pass in a dump_location_t rather than a location_t, via the
12223 gimple stmt.
12224 (grid_inner_loop_gridifiable_p): Likewise.
12225 (grid_dist_follows_simple_pattern): Likewise.
12226 (grid_gfor_follows_tiling_pattern): Likewise.
12227 (grid_target_follows_gridifiable_pattern): Likewise.
12228 (grid_attempt_target_gridification): Convert initialization
12229 of local "grid" from memset to zero-initialization; FIXME: does
12230 this require C++11? Update call to dump_printf_loc to pass in a
12231 optinfo_location rather than a location_t, via the gimple stmt.
12232 * profile.c (read_profile_edge_counts): Updates call to
12233 dump_printf_loc to pass in a dump_location_t rather than a
12234 location_t
12235 (compute_branch_probabilities): Likewise.
12236 * selftest-run-tests.c (selftest::run_tests): Call
12237 dumpfile_c_tests.
12238 * selftest.h (dumpfile_c_tests): New decl.
12239 * tree-loop-distribution.c (pass_loop_distribution::execute):
12240 Update for change in return type of find_loop_location.
12241 * tree-parloops.c (parallelize_loops): Likewise.
12242 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
12243 "locus" from location_t to dump_user_location_t.
12244 (canonicalize_loop_induction_variables): Likewise.
12245 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
12246 for change in return type of find_loop_location.
12247 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
12248 to dump_printf_loc to pass in a dump_location_t rather than a
12249 location_t, via the stmt.
12250 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
12251 Likewise.
12252 * tree-vect-loop-manip.c (find_loop_location): Convert return
12253 type from source_location to dump_user_location_t.
12254 (vect_do_peeling): Update for above change.
12255 (vect_loop_versioning): Update for change in type of
12256 vect_location.
12257 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
12258 from location_t to dump_user_location_t.
12259 (vect_estimate_min_profitable_iters): Update for change in type
12260 of vect_location.
12261 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
12262 location_t to dump_location_t.
12263 (vect_slp_bb): Update for change in type of vect_location.
12264 * tree-vectorizer.c (vect_location): Convert from source_location
12265 to dump_user_location_t.
12266 (try_vectorize_loop_1): Update for change in vect_location's type.
12267 (vectorize_loops): Likewise.
12268 (increase_alignment): Likewise.
12269 * tree-vectorizer.h (vect_location): Convert from source_location
12270 to dump_user_location_t.
12271 (find_loop_location): Convert return type from source_location to
12272 dump_user_location_t.
12273 (check_reduction_path): Convert 1st param from location_t to
12274 dump_user_location_t.
12275 * value-prof.c (check_counter): Update call to dump_printf_loc to
12276 pass in a dump_user_location_t rather than a location_t; update
12277 call to error_at for change in type of "locus".
12278 (check_ic_target): Update call to dump_printf_loc to
12279 pass in a dump_user_location_t rather than a location_t, via the
12280 call_stmt.
12281
12282 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
12283
12284 * config/s390/s390.h (enum processor_flags): Do not use
12285 default tune parameter when -march was specified.
12286
12287 2018-06-26 Jakub Jelinek <jakub@redhat.com>
12288
12289 PR target/86314
12290 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
12291 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
12292 operands.
12293
12294 2018-06-26 Richard Biener <rguenther@suse.de>
12295
12296 PR tree-optimization/86287
12297 PR bootstrap/86316
12298 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
12299 (vect_analyze_loop): Initialize n_stmts.
12300
12301 2018-06-26 Richard Biener <rguenther@suse.de>
12302
12303 PR middle-end/86271
12304 * fold-const.c (fold_convertible_p): Pointer extension
12305 isn't valid.
12306
12307 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
12308
12309 PR debug/86064
12310 * dwarf2out.c (loc_list_has_views): Adjust comments.
12311 (dw_loc_list): Split single cross-partition range with
12312 nonzero locview.
12313
12314 2018-06-25 Jeff Law <law@redhat.com>
12315
12316 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
12317 on -mbig-switch by default.
12318
12319 * config/v850/predicates.md (const_float_1_operand): Fix match_code
12320 test.
12321 (const_float_0_operand): Remove unused predicate.
12322 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
12323 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
12324 (recipsf2): New expander. Original pattern now called
12325 (recipsf2_insn).
12326 (recipdf2, recipdf2_insn): Similarly.
12327 (rsqrtsf2, rsqrtsf2_insn): Similarly
12328 (rsqrtdf2, rsqrtdf2_insn): Similarly
12329
12330 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
12331
12332 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
12333 Simplify logic for FreeBSD (twice).
12334
12335 2018-06-25 Martin Sebor <msebor@redhat.com>
12336
12337 PR tree-optimization/86204
12338 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
12339 a strnlen result if it's less than the length of the string.
12340
12341 2018-06-25 Martin Sebor <msebor@redhat.com>
12342
12343 PR tree-optimization/85700
12344 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
12345 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
12346 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
12347
12348 2018-06-25 Martin Sebor <msebor@redhat.com>
12349
12350 * doc/extend.texi (Zero-length arrays): Update and clarify.
12351
12352 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
12353
12354 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
12355 added IEEE/IBM long double multilib support on PowerPC little
12356 endian Linux systems.
12357 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
12358 (MULTILIB_DEFAULTS): Likewise.
12359 * config/rs6000/rs6000.c (rs6000_option_override_internal):
12360 Likewise.
12361 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
12362 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
12363 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
12364
12365 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
12366
12367 PR middle-end/86311
12368 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
12369 (REORDER_45): Likewise.
12370
12371 2018-06-25 Jeff Law <law@redhat.com>
12372
12373 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
12374 dividend to 32 bits. Adjust length.
12375 (udivmodhi4): Cleanup output template. Fix length.
12376
12377 2018-06-25 Carl Love <cel@us.ibm.com>
12378
12379 * config/rs6000/vsx.md: Change word selector to prefered location.
12380
12381 2018-06-25 Richard Biener <rguenther@suse.de>
12382
12383 PR tree-optimization/86304
12384 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
12385 epilogue-if-converted loops as well.
12386
12387 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
12388
12389 * lto-section-out.c (lto_begin_section): Do not print section
12390 name for noaddr and unnumbered dumps.
12391
12392 2018-06-25 Richard Biener <rguenther@suse.de>
12393
12394 * tree-vectorizer.h (struct vec_info_shared): New structure
12395 with parts split out from struct vec_info and loop_nest from
12396 struct _loop_vec_info.
12397 (struct vec_info): Adjust accordingly.
12398 (struct _loop_vec_info): Likewise.
12399 (LOOP_VINFO_LOOP_NEST): Adjust.
12400 (LOOP_VINFO_DATAREFS): Likewise.
12401 (LOOP_VINFO_DDRS): Likewise.
12402 (struct _bb_vec_info): Likewise.
12403 (BB_VINFO_DATAREFS): Likewise.
12404 (BB_VINFO_DDRS): Likewise.
12405 (struct _stmt_vec_info): Add dr_aux member.
12406 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
12407 (DR_MISALIGNMENT_UNINITIALIZED): New.
12408 (set_dr_misalignment): Adjust.
12409 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
12410 (vect_analyze_loop): Adjust prototype.
12411 (vect_analyze_loop_form): Likewise.
12412 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
12413 Compute dependences lazily.
12414 (vect_record_base_alignments): Use shared datarefs/ddrs.
12415 (vect_verify_datarefs_alignment): Likewise.
12416 (vect_analyze_data_refs_alignment): Likewise.
12417 (vect_analyze_data_ref_accesses): Likewise.
12418 (vect_analyze_data_refs): Likewise.
12419 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
12420 constructor parameter for shared part.
12421 (vect_analyze_loop_form): Pass in shared part and adjust.
12422 (vect_analyze_loop_2): Pass in storage for the number of
12423 stmts. Move loop nest finding to the caller. Compute
12424 datarefs lazily.
12425 (vect_analyze_loop): Pass in shared part.
12426 (vect_transform_loop): Verify shared datarefs are unchanged.
12427 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
12428 constructor parameter for shared part.
12429 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
12430 (vect_slp_bb): Verify shared datarefs are unchanged before
12431 transform.
12432 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
12433 change.
12434 (new_stmt_vec_info): Initialize DR_AUX misalignment to
12435 DR_MISALIGNMENT_UNINITIALIZED.
12436 * tree-vectorizer.c (vec_info::vec_info): Add constructor
12437 parameter for shared part.
12438 (vec_info::~vec_info): Adjust.
12439 (vec_info_shared::vec_info_shared): New.
12440 (vec_info_shared::~vec_info_shared): Likewise.
12441 (vec_info_shared::save_datarefs): Likewise.
12442 (vec_info_shared::check_datarefs): Likewise.
12443 (try_vectorize_loop_1): Construct shared part live for analyses
12444 of a single loop for multiple vector sizes.
12445 * tree-parloops.c (gather_scalar_reductions): Adjust.
12446
12447 2018-06-25 Richard Biener <rguenther@suse.de>
12448
12449 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
12450 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
12451 (vect_analyze_data_refs): Remove similar code from here and
12452 simplify accordingly.
12453
12454 2018-06-25 Richard Biener <rguenther@suse.de>
12455
12456 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
12457 for reverse storage order accesses rather than asserting
12458 they cannot happen here.
12459
12460 2018-06-25 Tom de Vries <tdevries@suse.de>
12461
12462 PR debug/86257
12463 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
12464 Use data16 instead of .byte for insn prefix.
12465
12466 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
12467
12468 PR C++/86082
12469 * parser.c (make_char_string_pack): Pass this literal chars
12470 through cpp_interpret_string.
12471 (cp_parser_userdef_numeric_literal): Check the result of
12472 make_char_string_pack.
12473
12474 2018-06-24 Maya Rashish <coypu@sdf.org>
12475
12476 * ginclude/stddef.h: Simplify conditions around avoiding
12477 re-definition of __size_t.
12478
12479 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12480
12481 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
12482 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
12483
12484 2018-06-22 Maya Rashish <coypu@sdf.org>
12485
12486 * doc/invoke.texi (mno-fancy-math-387): Update for changes
12487 made to OpenBSD and NetBSD through the years.
12488
12489 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
12490
12491 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12492 behavior of vec_pack (vector double, vector double) to match
12493 behavior of vec_float2 (vector double, vector double).
12494
12495 2018-06-22 Olivier Hainque <hainque@adacore.com>
12496
12497 * gimplify.c (gimplify_function_tree): Prevent creation
12498 of a trampoline for the address of the current function
12499 passed to entry/exit instrumentation hooks.
12500
12501 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
12502
12503 PR target/86222
12504 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
12505 correctly.
12506
12507 2018-06-22 Martin Liska <mliska@suse.cz>
12508
12509 PR tree-optimization/86263
12510 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12511 Bail out if is_enabled is false.
12512 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
12513 New declaration.
12514 (jump_table_cluster::is_enabled): New function.
12515
12516 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12517
12518 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
12519 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
12520 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
12521 (lto_input_ts_binfo_tree_pointers): Likewise.
12522 * tree-streamer-out.c (streamer_write_tree_bitfields,
12523 write_ts_binfo_tree_pointers): Likewise.
12524 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
12525
12526 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12527
12528 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
12529
12530 2018-06-22 Martin Liska <mliska@suse.cz>
12531
12532 * symbol-summary.h (get): Make it pure and inline move
12533 functionality from ::get function.
12534 (get): Remove and inline into ::get and ::get_create.
12535 (get_create): Move code from ::get function.
12536
12537 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12538
12539 PR target/85994
12540 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
12541 -x assembler-with-cpp.
12542
12543 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12544
12545 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
12546 _FILE_OFFSET_BITS=64 for C++.
12547
12548 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
12549
12550 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
12551 conversion insn that shows up when pr85657-3.c is compiled using
12552 IEEE 128-bit long double.
12553 (neg<mode>2_internal): Use the correct mode to check whether the
12554 mode is IBM extended.
12555 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
12556 multiply and divide external functions from being created more
12557 than once.
12558
12559 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12560
12561 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
12562 functions.
12563 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
12564 the edge can be forwarded.
12565 (cfg_layout_merge_blocks): Likewise.
12566
12567 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12568
12569 * except.c (finish_eh_generation): Commit edge insertions only after
12570 the EH edges have been redirected from post-landing to landing pads.
12571
12572 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12573
12574 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
12575 create_tmp_var_for to create the FRAME decl.
12576 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
12577
12578 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12579
12580 * tree-inline.c (copy_edges_for_bb): Minor tweak.
12581 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
12582 debug statement when resetting its value.
12583 (expand_call_inline): Copy the locus of the call onto the assignment
12584 of the return value, if any. Use local variable in more cases.
12585
12586 2018-06-21 Martin Liska <mliska@suse.cz>
12587
12588 * ipa-pure-const.c (propagate_nothrow): Use
12589 funct_state_summaries->get.
12590 (dump_malloc_lattice): Likewise.
12591 (propagate_malloc): Likewise.
12592
12593 2018-06-21 Richard Biener <rguenther@suse.de>
12594
12595 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
12596 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
12597 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
12598 comment.
12599 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
12600 BLOCK_ABSTRACT_ORIGIN unconditionally.
12601
12602 2018-06-21 David Malcolm <dmalcolm@redhat.com>
12603
12604 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
12605 deleting it.
12606 * ipa-reference.c (ipa_reference_c_finalize): Delete
12607 ipa_ref_opt_sum_summaries and set it to NULL.
12608
12609 2018-06-21 Tom de Vries <tdevries@suse.de>
12610
12611 PR tree-optimization/85859
12612 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
12613 test with comment from bb_no_side_effects_p.
12614
12615 2018-06-21 Richard Biener <rguenther@suse.de>
12616
12617 PR tree-optimization/86232
12618 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
12619 max for constant niter.
12620
12621 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12622
12623 * config/aarch64/aarch64-simd.md
12624 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
12625
12626 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12627
12628 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
12629 Make opernads of the unspec commutative.
12630
12631 2018-06-21 Richard Biener <rguenther@suse.de>
12632
12633 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
12634 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
12635 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
12636 (vect_analyze_data_ref_dependence): Re-order checks to deal with
12637 NULL DR_STEP.
12638 (vect_record_base_alignments): Do not record base alignment
12639 for gathers or scatters.
12640 (vect_compute_data_ref_alignment): Drop return value that is always
12641 true. Bail out early for gathers or scatters.
12642 (vect_enhance_data_refs_alignment): Bail out early for gathers
12643 or scatters.
12644 (vect_find_same_alignment_drs): Likewise.
12645 (vect_analyze_data_refs_alignment): Remove dead code.
12646 (vect_slp_analyze_and_verify_node_alignment): Likewise.
12647 (vect_analyze_data_refs): For possible gathers or scatters do
12648 not create an alternate DR, just check their possible validity
12649 and mark them. Adjust DECL_NONALIASED handling to not rely
12650 on DR_BASE_ADDRESS.
12651 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
12652 update inits of gathers or scatters.
12653 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
12654 Also copy gather/scatter flag to pattern vinfo.
12655
12656 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
12657
12658 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12659 behavior of vec_packsu (vector unsigned long long, vector unsigned
12660 long long) to match behavior of vec_packs with same signature.
12661
12662 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
12663 Thomas Schwinge <thomas@codesourcery.com>
12664 Cesar Philippidis <cesar@codesourcery.com>
12665
12666 * gimplify.c (gimplify_scan_omp_clauses): Add support for
12667 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12668 (gimplify_adjust_omp_clauses): Likewise.
12669 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
12670 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
12671 (gimplify_omp_target_update): Update handling of acc update and
12672 enter/exit data.
12673 * omp-low.c (install_var_field): Remove unused parameter
12674 base_pointers_restrict.
12675 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
12676 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
12677 FINALIZE}
12678 (omp_target_base_pointers_restrict_p): Delete.
12679 (scan_omp_target): Update call to scan_sharing_clauses.
12680 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
12681 FINALIZE}.
12682 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
12683 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12684 (convert_local_omp_clauses): Likewise.
12685 * tree-pretty-print.c (dump_omp_clause): Likewise.
12686 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
12687 FINALIZE}.
12688 (omp_clause_code_name): Likewise.
12689
12690 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12691
12692 PR debug/86194
12693 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
12694 be narrowed.
12695
12696 PR tree-optimization/86231
12697 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
12698 anti-range don't overwrite *vr0min before using it to compute *vr0max.
12699
12700 2018-06-20 Tom de Vries <tdevries@suse.de>
12701
12702 PR tree-optimization/86097
12703 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
12704 iv type if signedness of iv type is not the same as that of *nit.
12705
12706 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12707
12708 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
12709 EDGE_EH edges, verify they are all EDGE_EH.
12710
12711 2018-06-20 Maya Rashish <coypu@sdf.org>
12712
12713 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
12714
12715 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12716
12717 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
12718 * config/aarch64/aarch64.c (xgene1_tunings): Add
12719 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
12720 (aarch64_mode_valid_for_sched_fusion_p):
12721 Allow 16-byte modes.
12722 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
12723 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
12724 128-bit modes.
12725 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
12726 New pattern.
12727 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
12728 * config/aarch64/iterators.md (VQ2): New mode iterator.
12729
12730 2018-06-20 Martin Liska <mliska@suse.cz>
12731
12732 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
12733 Change default ratio from 10 to 8.
12734
12735 2018-06-20 Martin Liska <mliska@suse.cz>
12736
12737 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12738 New.
12739 (bit_test_cluster::find_bit_tests): Likewise.
12740 (switch_decision_tree::analyze_switch_statement): Find clusters.
12741 * tree-switch-conversion.h (struct jump_table_cluster): Document
12742 hierarchy.
12743
12744 2018-06-20 Martin Liska <mliska@suse.cz>
12745
12746 * tree-switch-conversion.c (switch_conversion::collect):
12747 Record m_uniq property.
12748 (switch_conversion::expand): Bail out for special conditions.
12749 (group_cluster::~group_cluster): New.
12750 (group_cluster::group_cluster): Likewise.
12751 (group_cluster::dump): Likewise.
12752 (jump_table_cluster::emit): New.
12753 (switch_decision_tree::fix_phi_operands_for_edges): New.
12754 (struct case_node): Remove struct.
12755 (jump_table_cluster::can_be_handled): New.
12756 (case_values_threshold): Moved to header.
12757 (reset_out_edges_aux): Likewise.
12758 (jump_table_cluster::is_beneficial): New.
12759 (bit_test_cluster::can_be_handled): Likewise.
12760 (add_case_node): Remove.
12761 (bit_test_cluster::is_beneficial): New.
12762 (case_bit_test::cmp): New.
12763 (bit_test_cluster::emit): New.
12764 (expand_switch_as_decision_tree_p): Remove.
12765 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
12766 (fix_phi_operands_for_edge): Likewise.
12767 (switch_decision_tree::analyze_switch_statement): New.
12768 (compute_cases_per_edge): Move ...
12769 (switch_decision_tree::compute_cases_per_edge): ... here.
12770 (try_switch_expansion): Likewise.
12771 (switch_decision_tree::try_switch_expansion): Likewise.
12772 (record_phi_operand_mapping): Likewise.
12773 (switch_decision_tree::record_phi_operand_mapping): Likewise.
12774 (emit_case_decision_tree): Likewise.
12775 (switch_decision_tree::emit): Likewise.
12776 (balance_case_nodes): Likewise.
12777 (switch_decision_tree::balance_case_nodes): Likewise.
12778 (dump_case_nodes): Likewise.
12779 (switch_decision_tree::dump_case_nodes): Likewise.
12780 (emit_jump): Likewise.
12781 (switch_decision_tree::emit_jump): Likewise.
12782 (emit_cmp_and_jump_insns): Likewise.
12783 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
12784 (emit_case_nodes): Likewise.
12785 (switch_decision_tree::emit_case_nodes): Likewise.
12786 (conditional_probability): Remove.
12787 * tree-switch-conversion.h (enum cluster_type): New.
12788 (PRINT_CASE): New.
12789 (struct cluster): Likewise.
12790 (cluster::cluster): Likewise.
12791 (struct simple_cluster): Likewise.
12792 (simple_cluster::simple_cluster): Likewise.
12793 (struct group_cluster): Likewise.
12794 (struct jump_table_cluster): Likewise.
12795 (struct bit_test_cluster): Likewise.
12796 (struct min_cluster_item): Likewise.
12797 (struct case_tree_node): Likewise.
12798 (case_tree_node::case_tree_node): Likewise.
12799 (jump_table_cluster::case_values_threshold): Likewise.
12800 (struct case_bit_test): Likewise.
12801 (struct switch_decision_tree): Likewise.
12802 (struct switch_conversion): Likewise.
12803 (switch_decision_tree::reset_out_edges_aux): Likewise.
12804
12805 2018-06-20 Martin Liska <mliska@suse.cz>
12806
12807 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
12808 (hoist_edge_and_branch_if_true): Likewise.
12809 (expand_switch_using_bit_tests_p): Likewise.
12810 (struct case_bit_test): Likewise.
12811 (case_bit_test_cmp): Likewise.
12812 (emit_case_bit_tests): Likewise.
12813 (switch_conversion::switch_conversion): New class.
12814 (struct switch_conv_info): Remove old struct.
12815 (collect_switch_conv_info): More to ...
12816 (switch_conversion::collect): ... this.
12817 (check_range): Likewise.
12818 (switch_conversion::check_range): Likewise.
12819 (check_all_empty_except_final): Likewise.
12820 (switch_conversion::check_all_empty_except_final): Likewise.
12821 (check_final_bb): Likewise.
12822 (switch_conversion::check_final_bb): Likewise.
12823 (create_temp_arrays): Likewise.
12824 (switch_conversion::create_temp_arrays): Likewise.
12825 (free_temp_arrays): Likewise.
12826 (gather_default_values): Likewise.
12827 (switch_conversion::gather_default_values): Likewise.
12828 (build_constructors): Likewise.
12829 (switch_conversion::build_constructors): Likewise.
12830 (constructor_contains_same_values_p): Likewise.
12831 (switch_conversion::contains_same_values_p): Likewise.
12832 (array_value_type): Likewise.
12833 (switch_conversion::array_value_type): Likewise.
12834 (build_one_array): Likewise.
12835 (switch_conversion::build_one_array): Likewise.
12836 (build_arrays): Likewise.
12837 (switch_conversion::build_arrays): Likewise.
12838 (gen_def_assigns): Likewise.
12839 (switch_conversion::gen_def_assigns): Likewise.
12840 (prune_bbs): Likewise.
12841 (switch_conversion::prune_bbs): Likewise.
12842 (fix_phi_nodes): Likewise.
12843 (switch_conversion::fix_phi_nodes): Likewise.
12844 (gen_inbound_check): Likewise.
12845 (switch_conversion::gen_inbound_check): Likewise.
12846 (process_switch): Use the newly created class.
12847 (switch_conversion::expand): New.
12848 (switch_conversion::~switch_conversion): New.
12849 * tree-switch-conversion.h: New file.
12850
12851 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12852
12853 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
12854 tree-vect-patterns.c.
12855 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
12856 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
12857 (vect_recog_sad_pattern): Likewise.
12858 (vect_recog_widen_sum_pattern): Likewise.
12859 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
12860 (vect_recog_widen_shift_pattern): Remove the type_in argument.
12861 (vect_recog_rotate_pattern): Likewise.
12862 (vect_recog_mult_pattern): Likewise.
12863 (vect_recog_vector_vector_shift_pattern): Likewise.
12864 (vect_recog_divmod_pattern): Likewise.
12865 (vect_recog_mixed_size_cond_pattern): Likewise.
12866 (vect_recog_bool_pattern): Likewise.
12867 (vect_recog_mask_conversion_pattern): Likewise.
12868 (vect_try_gather_scatter_pattern): Likewise.
12869 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
12870 (vect_recog_over_widening_pattern): Likewise.
12871 (vect_recog_gather_scatter_pattern): Likewise.
12872 (vect_recog_func_ptr): Move from tree-vectorizer.h
12873 (vect_vect_recog_func_ptrs): Move further down the file.
12874 (vect_recog_func): Likewise. Remove the third argument.
12875 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
12876 (vect_pattern_recog_1): Expect the pattern function to do any
12877 necessary target tests. Also expect it to provide a vector type.
12878 Remove the type_in handling.
12879
12880 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12881
12882 * tree-vect-patterns.c (vect_pattern_detected): New function.
12883 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
12884 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
12885 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
12886 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
12887 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
12888 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
12889 (vect_recog_mask_conversion_pattern)
12890 (vect_try_gather_scatter_pattern): Likewise.
12891
12892 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12893
12894 * tree-vect-patterns.c (vect_get_internal_def): New function.
12895 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
12896 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
12897 (search_type_for_mask_1): Use it.
12898
12899 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12900
12901 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
12902 redundant WIDEN_SUM_EXPR handling.
12903 (vect_recog_sad_pattern): Likewise.
12904
12905 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12906
12907 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
12908 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
12909 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
12910 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
12911 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
12912
12913 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12914
12915 * tree-vect-stmts.c (vectorizable_call): Make sure that we
12916 use the stmt_vec_info of the original bb statement for the
12917 new zero assignment, even if the call is part of a pattern.
12918
12919 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12920
12921 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
12922 that the sequence is attached to the original statement rather
12923 than the pattern statement.
12924 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
12925 PATTERN_DEF_SEQ from the original statement rather than
12926 the main pattern statement.
12927 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
12928 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
12929 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
12930
12931 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12932
12933 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
12934 definition statements before the early exit for statements that aren't
12935 live or relevant.
12936 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
12937 split out from...
12938 (vect_transform_loop): ...here. Process pattern definition
12939 statements without first checking whether the main pattern
12940 statement is live or relevant.
12941
12942 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
12943
12944 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
12945 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
12946
12947 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
12948
12949 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
12950 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
12951 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
12952 (expand_block_compare): Change select_block_compare_mode call.
12953 (expand_strncmp_align_check): Use new functions, fix comment.
12954 (emit_final_str_compare_gpr): New function.
12955 (expand_strn_compare): Refactor and clean up code.
12956 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
12957
12958 2018-06-19 Tony Reix <tony.reix@atos.com>
12959 Damien Bergamini <damien.bergamini@atos.com>
12960 David Edelsohn <dje.gcc@gmail.com>
12961
12962 * collect2.c (static_obj): New variable.
12963 (static_libs): New variable.
12964 (is_in_list): Uncomment declaration.
12965 (main): Track AIX libraries linked statically.
12966 (is_in_list): Uncomment definition.
12967 (scan_prog_file): Don't add AIX shared libraries initializer
12968 to constructor list if linking statically.
12969
12970 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
12971
12972 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
12973 constant.
12974 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
12975
12976 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
12977
12978 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
12979 blocks.
12980
12981 2018-06-19 Martin Liska <mliska@suse.cz>
12982
12983 * config/i386/i386.c (ix86_can_inline_p): Do not use
12984 ipa_fn_summaries::get_create.
12985 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
12986 get.
12987 (devirtualization_time_bonus): Likewise.
12988 (ipcp_propagate_stage): Likewise.
12989 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
12990 (edge_set_predicate): Likewise.
12991 (evaluate_conditions_for_known_args): Likewise.
12992 (evaluate_properties_for_edge): Likewise.
12993 (ipa_call_summary::reset): Tranform to ...
12994 (ipa_call_summary::~ipa_call_summary): ... this.
12995 (ipa_fn_summary::reset): Transform to ...
12996 (ipa_fn_summary::~ipa_fn_summary): ... this.
12997 (ipa_fn_summary_t::remove): Rename to ...
12998 (ipa_fn_summary_t::remove_callees): ... this.
12999 (ipa_fn_summary_t::duplicate): Use placement new
13000 instead of memory copy.
13001 (ipa_call_summary_t::duplicate): Likewise.
13002 (ipa_call_summary_t::remove): Remove.
13003 (dump_ipa_call_summary): Change get_create to get.
13004 (ipa_dump_fn_summary): Dump only when summary exists.
13005 (analyze_function_body): Use symbol_summary::get instead
13006 of get_create.
13007 (compute_fn_summary): Likewise.
13008 (estimate_edge_devirt_benefit): Likewise.
13009 (estimate_edge_size_and_time): Likewise.
13010 (inline_update_callee_summaries): Likewise.
13011 (remap_edge_change_prob): Likewise.
13012 (remap_edge_summaries): Likewise.
13013 (ipa_merge_fn_summary_after_inlining): Likewise.
13014 (write_ipa_call_summary): Likewise.
13015 (ipa_fn_summary_write): Likewise.
13016 (ipa_free_fn_summary): Likewise.
13017 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
13018 (struct ipa_call_summary): Likewise.
13019 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
13020 of get_create.
13021 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
13022 (estimate_size_after_inlining): Likewise.
13023 (estimate_growth): Likewise.
13024 (growth_likely_positive): Likewise.
13025 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
13026 (inline_call): Likewise.
13027 * ipa-inline.c (caller_growth_limits): Likewise.
13028 (can_inline_edge_p): Likewise.
13029 (can_inline_edge_by_limits_p): Likewise.
13030 (compute_uninlined_call_time): Likewise.
13031 (compute_inlined_call_time): Likewise.
13032 (want_inline_small_function_p): Likewise.
13033 (edge_badness): Likewise.
13034 (update_caller_keys): Likewise.
13035 (update_callee_keys): Likewise.
13036 (inline_small_functions): Likewise.
13037 (inline_to_all_callers_1): Likewise.
13038 (dump_overall_stats): Likewise.
13039 (early_inline_small_functions): Likewise.
13040 (early_inliner): Likewise.
13041 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13042 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
13043 * ipa-pure-const.c (malloc_candidate_p): Likewise.
13044 * ipa-split.c (execute_split_functions): Likewise.
13045 * symbol-summary.h: Likewise.
13046 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
13047
13048 2018-06-19 Richard Biener <rguenther@suse.de>
13049
13050 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
13051 (vectorize_loops): ... here. Fix dbgcnt handling.
13052 (try_vectorize_loop): Wrap try_vectorize_loop_1.
13053
13054 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
13055
13056 PR target/86197
13057 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
13058 ieee128 argument takes up only one (vector) register, not two (floating
13059 point) registers.
13060
13061 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
13062
13063 * gimplify.c (gimplify_init_constructor): Really never clear for an
13064 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
13065
13066 2018-06-19 Richard Biener <rguenther@suse.de>
13067
13068 PR tree-optimization/86179
13069 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
13070 after failed recognition.
13071
13072 2018-06-18 Martin Sebor <msebor@redhat.com>
13073
13074 PR middle-end/85602
13075 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
13076 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
13077 Handle integer subtraction.
13078 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
13079 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
13080
13081 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13082
13083 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
13084 param from rtx to rtx_insn *.
13085 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
13086 param.
13087 (frv_ifcvt_modify_insn): Likwise.
13088 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
13089 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
13090 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
13091 as_a <rtx_insn *> cast to local "unprotected_region" once
13092 it's been established that it's not NULL or pc_rtx.
13093 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
13094 param "sethi" from rtx to rtx_insn *.
13095 (nds32_group_float_insns): Likewise for param "insn".
13096 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
13097 param.
13098 (vax_output_int_subtract): Likewise.
13099 * config/vax/vax.c (vax_output_int_add): Likewise for param
13100 "insn".
13101 (vax_output_int_subtract): Likewise.
13102 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
13103 (emit_pattern_after): Likewise for param "after".
13104 (emit_insn_after): Likewise.
13105 (emit_jump_insn_after): Likewise.
13106 (emit_call_insn_after): Likewise.
13107 (emit_debug_insn_after): Likewise.
13108 (emit_pattern_before): Likewise for param "before".
13109 (emit_insn_before): Likewise.
13110 (emit_jump_insn_before): Likewise.
13111 * final.c (get_insn_template): Likewise for param "insn", removing
13112 a cast.
13113 * output.h (get_insn_template): Likewise for 2nd param.
13114 * rtl.h (emit_insn_before): Likewise.
13115 (emit_jump_insn_before): Likewise.
13116 (emit_debug_insn_before_noloc): Likewise.
13117 (emit_insn_after): Likewise.
13118 (emit_jump_insn_after): Likewise.
13119 (emit_call_insn_after): Likewise.
13120 (emit_debug_insn_after): Likewise.
13121 (set_insn_deleted): Likewise for param.
13122
13123 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
13124
13125 PR target/85358
13126 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
13127 floating point modes, so that IFmode is numerically greater than
13128 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
13129 to declare the ordering. This prevents IFmode from being
13130 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
13131 machine. Include rs6000-modes.h to share the fractional values
13132 between genmodes* and the rest of the compiler.
13133 (IFmode): Likewise.
13134 (KFmode): Likewise.
13135 (TFmode): Likewise.
13136 * config/rs6000/rs6000-modes.h: New file.
13137 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
13138 meaning of rs6000_long_double_size so that 126..128 selects an
13139 appropriate 128-bit floating point type.
13140 (rs6000_option_override_internal): Likewise.
13141 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
13142 (TARGET_LONG_DOUBLE_128): Change the meaning of
13143 rs6000_long_double_size so that 126..128 selects an appropriate
13144 128-bit floating point type.
13145 (LONG_DOUBLE_TYPE_SIZE): Update comment.
13146 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
13147 source and destination to match the standard usage.
13148 (truncifkf2): Likewise.
13149 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
13150 ISA 2.07 to use an explicit clobber, instead of passing in a
13151 temporary.
13152 (copysign<mode>3_soft): Likewise.
13153
13154 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13155
13156 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
13157 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
13158 (vect_slp_analyze_instance_dependence): Likewise.
13159 (vect_enhance_data_refs_alignment): Likewise.
13160 (vect_analyze_data_refs_alignment): Likewise.
13161 (vect_slp_analyze_and_verify_instance_alignment
13162 (vect_analyze_data_ref_accesses): Likewise.
13163 (vect_prune_runtime_alias_test_list): Likewise.
13164 (vect_analyze_data_refs): Likewise.
13165 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
13166 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
13167 (vect_analyze_scalar_cycles_1): Likewise.
13168 (vect_get_loop_niters): Likewise.
13169 (vect_analyze_loop_form_1): Likewise.
13170 (vect_update_vf_for_slp): Likewise.
13171 (vect_analyze_loop_operations): Likewise.
13172 (vect_analyze_loop): Likewise.
13173 (vectorizable_induction): Likewise.
13174 (vect_transform_loop): Likewise.
13175 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
13176 * tree-vect-slp.c (vect_analyze_slp): Likewise.
13177 (vect_make_slp_decision): Likewise.
13178 (vect_detect_hybrid_slp): Likewise.
13179 (vect_slp_analyze_operations): Likewise.
13180 (vect_slp_bb): Likewise.
13181 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
13182 (vectorizable_bswap): Likewise.
13183 (vectorizable_call): Likewise.
13184 (vectorizable_simd_clone_call): Likewise.
13185 (vectorizable_conversion): Likewise.
13186 (vectorizable_assignment): Likewise.
13187 (vectorizable_shift): Likewise.
13188 (vectorizable_operation): Likewise.
13189 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
13190
13191 2018-06-18 Martin Sebor <msebor@redhat.com>
13192
13193 PR tree-optimization/81384
13194 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
13195 * builtins.c (expand_builtin_strnlen): New function.
13196 (expand_builtin): Call it.
13197 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
13198 * builtins.def (BUILT_IN_STRNLEN): New.
13199 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
13200 Warn for bounds in excess of maximum object size.
13201 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
13202 single-value ranges. Handle strnlen.
13203 (handle_builtin_strlen): Handle strnlen.
13204 (strlen_check_and_optimize_stmt): Same.
13205 * doc/extend.texi (Other Builtins): Document strnlen.
13206
13207 2018-06-18 Maya Rashish <coypu@sdf.org>
13208
13209 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
13210 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
13211 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
13212
13213 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
13214 here to ...
13215 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
13216
13217 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13218
13219 * tree.c (escaped_string::escape): Replace cast to char * by
13220 const_cast<char *> (unescaped).
13221
13222 2018-06-18 Nick Clifton <nickc@redhat.com>
13223
13224 PR 84195
13225 * tree.c (escaped_string): New class. Converts an unescaped
13226 string into its escaped equivalent.
13227 (warn_deprecated_use): Use the new class to convert the
13228 deprecation message, if present.
13229 (test_escaped_strings): New self test.
13230 (test_c_tests): Add test_escaped_strings.
13231 * doc/extend.texi (deprecated): Add a note that the
13232 deprecation message is affected by the -fmessage-length
13233 option, and that control characters will be escaped.
13234 (#pragma GCC error): Document this pragma.
13235 (#pragma GCC warning): Likewise.
13236 * doc/invoke.texi (-fmessage-length): Document this option's
13237 effect on the #warning and #error preprocessor directives and
13238 the deprecated attribute.
13239
13240 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
13241
13242 * tree.c (decl_value_expr_lookup): Revert latest change.
13243 (decl_value_expr_insert): Likewise.
13244
13245 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
13246
13247 * gimplify.c (nonlocal_vlas): Delete.
13248 (nonlocal_vla_vars): Likewise.
13249 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
13250 referenced VLAs.
13251 (gimplify_body): Do not create and destroy nonlocal_vlas.
13252 * tree-nested.c: Include diagnostic.h.
13253 (use_pointer_in_frame): Tweak.
13254 (lookup_field_for_decl): Add assertion and declare the transformation.
13255 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
13256 internal error when the reference is in a wrong context. Do not
13257 create a debug decl by default.
13258 (note_nonlocal_block_vlas): Delete.
13259 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
13260 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
13261 create a debug decl by default.
13262 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
13263 call is in a wrong context.
13264 (fixup_vla_decls): New function.
13265 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
13266 debug variables were created.
13267 * tree.c (decl_value_expr_lookup): Add checking assertion.
13268 (decl_value_expr_insert): Likewise.
13269
13270 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13271
13272 PR middle-end/82479
13273 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
13274 * tree-scalar-evolution.c (interpret_expr): Likewise.
13275 (expression_expensive_p): Likewise.
13276 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
13277 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
13278 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
13279 (ssa_defined_by_minus_one_stmt_p): New.
13280
13281 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13282
13283 PR middle-end/64946
13284 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
13285 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
13286 * dojump.c (do_jump): Likewise.
13287 * expr.c (expand_expr_real_2): Check operand type's sign.
13288 * fold-const.c (const_unop): Handle ABSU_EXPR.
13289 (fold_abs_const): Likewise.
13290 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
13291 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
13292 (strip_sign_op_1): Likesise.
13293 * match.pd: Add new pattern to generate ABSU_EXPR.
13294 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
13295 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
13296 * tree-eh.c (operation_could_trap_helper_p): Likewise.
13297 * tree-inline.c (estimate_operator_cost): Likewise.
13298 * tree-pretty-print.c (dump_generic_node): Likewise.
13299 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
13300 * tree.def (ABSU_EXPR): New.
13301
13302 2018-06-16 Jakub Jelinek <jakub@redhat.com>
13303
13304 PR middle-end/86095
13305 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
13306 documented as preserved for backward compatibility only.
13307 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
13308
13309 PR rtl-optimization/86108
13310 * bb-reorder.c (create_forwarder_block): Renamed to ...
13311 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
13312 jump from new landing pad to the second part.
13313 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
13314 Adjust callers.
13315
13316 2018-06-15 Jakub Jelinek <jakub@redhat.com>
13317
13318 PR middle-end/85878
13319 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
13320 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
13321 Only call store_expr for halves if the mode is the same.
13322
13323 PR middle-end/86123
13324 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
13325 Fix up comment formatting.
13326
13327 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
13328
13329 * typed-splay-tree.h (typed_splay_tree::remove): New function.
13330 (typed_splay_tree::closure,
13331 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
13332 (typed_splay_tree::typed_splay_tree,
13333 typed_splay_tree::operator =): Declared private.
13334 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
13335 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
13336 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
13337 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
13338 typed_splay_tree::splay_tree_splay,
13339 typed_splay_tree::splay_tree_foreach_helper,
13340 typed_splay_tree::splay_tree_insert,
13341 typed_splay_tree::splay_tree_remove,
13342 typed_splay_tree::splay_tree_lookup,
13343 typed_splay_tree::splay_tree_predecessor,
13344 typed_splay_tree::splay_tree_successor,
13345 typed_splay_tree::splay_tree_min,
13346 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
13347 (typed_splay_tree::root, typed_splay_tree::comp,
13348 typed_splay_tree::delete_key,
13349 typed_splay_tree::delete_value): New data members.
13350 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
13351 typed_splay_tree::remove.
13352
13353 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
13354
13355 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
13356 -mginv and -mno-ginv to the assembler.
13357 * config/mips/mips.opt (-mcrc): New option.
13358 (-mginv): Likewise.
13359 * doc/invoke.text (-mcrc): Document.
13360 (-mginv): Likewise.
13361
13362 2018-06-15 Nick Clifton <nickc@redhat.com>
13363
13364 PR 84195
13365 * tree.c (escaped_string): New class. Converts an unescaped
13366 string into its escaped equivalent.
13367 (warn_deprecated_use): Use the new class to convert the
13368 deprecation message, if present.
13369 (test_escaped_strings): New self test.
13370 (test_c_tests): Add test_escaped_strings.
13371 * doc/extend.texi (deprecated): Add a note that the
13372 deprecation message is affected by the -fmessage-length
13373 option, and that control characters will be escaped.
13374 (#pragma GCC error): Document this pragma.
13375 (#pragma GCC warning): Likewise.
13376 * doc/invoke.texi (-fmessage-length): Document this option's
13377 effect on the #warning and #error preprocessor directives and
13378 the deprecated attribute.
13379
13380 2018-06-15 Richard Biener <rguenther@suse.de>
13381
13382 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
13383 here, also noting vector size used.
13384 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
13385 size used in MSG_OPTIMIZED_LOCATIONS dump.
13386 (pass_slp_vectorize::execute): Adjust.
13387
13388 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
13389
13390 PR target/85968
13391 * config/arc/arc.c (arc_return_address_register): Fix
13392 if-condition.
13393
13394 2018-06-15 Richard Biener <rguenther@suse.de>
13395
13396 PR middle-end/86159
13397 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
13398 leave useless conversion stripping to force_gimple_operand_gsi.
13399 (gimplify_build2): Likewise.
13400 (gimplify_build1): Likewise.
13401
13402 2018-06-15 Richard Biener <rguenther@suse.de>
13403
13404 PR middle-end/86076
13405 * tree-cfg.c (move_stmt_op): unshare invariant addresses
13406 before adjusting their block.
13407
13408 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
13409
13410 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
13411 multilibs for *-*-rtems*.
13412 * config/riscv/t-rtems: New file.
13413
13414 2018-06-14 Jakub Jelinek <jakub@redhat.com>
13415
13416 PR middle-end/86122
13417 * match.pd ((A +- CST1) +- CST2): Punt if last resort
13418 unsigned_type_for returns NULL.
13419
13420 PR target/85945
13421 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
13422 subregs of multi-word pseudos unless the float mode has word size.
13423
13424 2018-06-14 Richard Biener <rguenther@suse.de>
13425
13426 PR middle-end/86139
13427 * tree-vect-generic.c (build_word_mode_vector_type): Remove
13428 duplicate and harmful type_hash_canon.
13429 * tree.c (type_hash_canon): Assert we didn't find ourselves.
13430
13431 2018-06-14 Richard Biener <rguenther@suse.de>
13432
13433 PR ipa/86124
13434 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
13435 NULL cgraph_node.
13436
13437 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
13438
13439 * config/rtems.h (STDINT_LONG32): Define.
13440
13441 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
13442 Prachi Godbole <prachi.godbole@imgtec.com>
13443
13444 * config/mips/mips-cpus.def: Define P6600.
13445 * config/mips/mips-tables.opt: Regenerate.
13446 * config/mips/mips.c (mips_ucbranch_type): New enum.
13447 (mips_rtx_cost_data): Add support for P6600.
13448 (mips_issue_rate): Likewise.
13449 (mips_multipass_dfa_lookahead): Likewise.
13450 (mips_avoid_hazard): Likewise.
13451 (mips_reorg_process_insns): Likewise.
13452 (mips_classify_branch_p6600): New function.
13453 * config/mips/mips.h (TUNE_P6600): New define.
13454 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
13455 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
13456 * config/mips/mips.md: Include p6600.md.
13457 (processor): Add p6600.
13458 * config/mips/p6600.md: New file.
13459 * doc/invoke.texi: Add p6600 to supported architectures.
13460
13461 2018-06-13 Martin Sebor <msebor@redhat.com>
13462
13463 PR tree-optimization/86114
13464 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
13465 of integer types.
13466 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
13467
13468 2018-06-13 Richard Biener <rguenther@suse.de>
13469
13470 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
13471 Properly set vector type of the intermediate stmt.
13472 * tree-vect-stmts.c (vectorizable_operation): The destination
13473 var always has vectype_out type.
13474
13475 2018-06-13 Jeff Law <law@redhat.com>
13476
13477 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
13478 integer 0 for argument to print_rtl_with_bb.
13479 (rl78_reorg): Likewise.
13480
13481 2018-06-13 David Malcolm <dmalcolm@redhat.com>
13482
13483 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
13484 from rtx to rtx_insn *.
13485 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
13486 "label".
13487 (add_sched_insns_for_speculation): Likewise for local "target",
13488 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13489 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
13490 from rtx_insn ** to rtx_code_label **.
13491 (reorg_emit_nops): Likewise.
13492 (c6x_reorg): Likewise for local "call_labels".
13493 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
13494 rtx to rtx_insn *.
13495 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
13496 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
13497 the loops over LABEL_REFS.
13498 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
13499 braf_label.
13500 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13501 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
13502 (split_branches): Strengthen local "olabel" from rtx to
13503 rtx_insn *, adding a safe_as_a cast.
13504 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
13505 to "rtx_insn *".
13506 (add_insn_after): Likewise for first two params.
13507 (add_insn_before): Likewise.
13508 (remove_insn): Likewise for param.
13509 (emit_pattern_before_noloc): Likewise for second and third params.
13510 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
13511 (emit_call_insn_before_noloc): Likewise.
13512 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
13513 to "rtx_insn *".
13514 (emit_barrier_before): Likewise.
13515 (emit_label_before): Strengthen "label" param from "rtx" to
13516 "rtx_code_label *". Strengthen "before" param from "rtx" to
13517 "rtx_insn *".
13518 (emit_insn_after_1): Strengthen "after" param from "rtx" to
13519 "rtx_insn *".
13520 (emit_pattern_after_noloc): Likewise.
13521 (emit_insn_after_noloc): Likewise.
13522 (emit_jump_insn_after_noloc): Likewise.
13523 (emit_call_insn_after_noloc): Likewise.
13524 (emit_debug_insn_after_noloc): Likewise.
13525 (emit_barrier_after): Likewise.
13526 (emit_label_after): Likewise for both params.
13527 (emit_pattern_after_setloc): Likewise for "after" param. Convert
13528 "loc" param from "int" to "location_t".
13529 (emit_insn_after_setloc): Likewise.
13530 (emit_jump_insn_after_setloc): Likewise.
13531 (emit_call_insn_after_setloc): Likewise.
13532 (emit_debug_insn_after_setloc): Likewise.
13533 (emit_pattern_before_setloc): Likewise for "before" param. Convert
13534 "loc" param from "int" to "location_t".
13535 (emit_pattern_before): Convert NULL_RTX to NULL.
13536 (emit_insn_before_setloc): Convert "loc" param from "int" to
13537 "location_t".
13538 (emit_jump_insn_before_setloc): Likewise.
13539 (emit_call_insn_before_setloc): Likewise.
13540 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
13541 rtx_insn *. Convert "loc" param from "int" to "location_t".
13542 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
13543 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
13544 Convert 3rd param from "int" to "location_t".
13545 (emit_barrier_before, emit_barrier_after, next_real_insn):
13546 Strengthen param from rtx to rtx_insn *.
13547 (emit_label_before): Strengthen 1st param from "rtx" to
13548 "rtx_code_label *". Strengthen 2nd param from "rtx" to
13549 "rtx_insn *".
13550 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
13551 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
13552 Strengthen 2nd param from "rtx" to "rtx_insn *".
13553 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
13554 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
13555 Likewise. Convert 3rd param from "int" to "location_t".
13556 (emit_label_after): Strengthen 1st param from "rtx" to
13557 "rtx_code_label *".
13558 (next_real_insn, remove_insn): Strengthen param from "rtx" to
13559 "rtx_insn *".
13560 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
13561 from "rtx" to "rtx_insn *".
13562
13563 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
13564
13565 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
13566 bodies streamed in with -Q.
13567 * dumpfile.c (dump_files): Add lto-stream-out dump file.
13568 * dumpfile.h (tree_dump_index): Add lto_stream_out.
13569 * gimple-streamer-out.c: Include gimple-pretty-print.h
13570 (output_bb): Dump stmts streamed.
13571 * lto-section-out.c: Include print-tree.h
13572 (lto_begin_section): Dump sections created.
13573 (lto_output_decl_index): Dump decl encoded.
13574 * lto-streamer-out.c: Include print-tree.h
13575 (create_output_block): Dump output block created.
13576 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
13577 (output_function): Dump function output.
13578 (output_constructor): Dump constructor streamed.
13579 (write_global_stream): Output indexes encoded.
13580 (produce_asm_for_decls): Dump streams encoded.
13581 * lto-streamer.c (streamer_dump_file): New global var.
13582 * lto-streamer.h (streamer_dump_file): Declare.
13583 * passes.c (ipa_write_summaries): Initialize streamer dump.
13584 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
13585 in.
13586
13587 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
13588
13589 PR target/86048
13590 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
13591 offsets for register save directives. Emit a second batch of save
13592 directives, if need be, when the function accesses prior frames.
13593
13594 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13595
13596 * config/arc/fpu.md (fmasf4): Force operand to register.
13597 (fnmasf4): Likewise.
13598
13599 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13600
13601 * config/arc/arc-protos.h (arc_pad_return): Remove.
13602 * config/arc/arc.c (machine_function): Remove force_short_suffix
13603 and size_reason.
13604 (arc_print_operand): Adjust printing of '&'.
13605 (arc_verify_short): Remove conditional printing of short suffix.
13606 (arc_final_prescan_insn): Remove reference to size_reason.
13607 (pad_return): New function.
13608 (arc_reorg): Call pad_return.
13609 (arc_pad_return): Remove.
13610 (arc_init_machine_status): Remove reference to force_short_suffix.
13611 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
13612 (attr length): When attribute iscompact is true force to 2
13613 regardless; in the case of maybe check if we want to force the
13614 instruction to have 4 bytes length.
13615 (nopv): Change it to generate 4 byte long nop as well.
13616 (blockage): New pattern.
13617 (simple_return): Remove call to arc_pad_return.
13618 (p_return_i): Likewise.
13619
13620 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13621
13622 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
13623
13624 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13625
13626 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
13627 ARC cores.
13628
13629 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13630
13631 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
13632 for ARC700 and ARCv2.
13633
13634 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
13635
13636 PR target/86076
13637 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
13638 operands[2] instead of operands[1].
13639
13640
13641 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13642
13643 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
13644 case, check whether the outer register overlaps an unallocatable
13645 register, not just whether it fits the required class.
13646
13647 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13648
13649 * poly-int.h (can_div_trunc_p): Add new overload in which all values
13650 are poly_ints.
13651 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
13652 (memrefs_conflict_p): Likewise.
13653 (init_alias_analysis): Likewise.
13654 * cfgexpand.c (expand_debug_expr): Likewise.
13655 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
13656 * cse.c (fold_rtx): Likewise.
13657 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
13658 * expr.c (emit_block_move_hints): Likewise.
13659 (clear_storage_hints, push_block, emit_push_insn): Likewise.
13660 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
13661 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
13662 (emit_group_store): Likewise.
13663 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
13664 to read the PRE/POST_MODIFY increment.
13665 * calls.c (store_one_arg): Use strip_offset.
13666 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
13667 poly_int_rtx_p.
13668 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
13669 by a VEC_SELECT.
13670 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
13671 (simplify_binary_operation_1): Extend CONST_INT handling to
13672 poly_int_rtx_p.
13673 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
13674 than a HOST_WIDE_INT.
13675 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
13676 poly_int64.
13677 (adjust_mems, add_stores): Update accodingly.
13678 (vt_canonicalize_addr): Track polynomial offsets.
13679 (emit_note_insn_var_location): Likewise.
13680 (vt_add_function_parameter): Likewise.
13681 (vt_initialize): Likewise.
13682
13683 2018-06-12 Jeff Law <law@redhat.com>
13684
13685 * config.gcc (alpha*-*-freebsd*): Remove.
13686 * config/alpha/freebsd.h: Remove.
13687
13688 2018-06-12 David Malcolm <dmalcolm@redhat.com>
13689
13690 PR other/69968
13691 * spellcheck-tree.c (levenshtein_distance): Rename to...
13692 (get_edit_distance): ...this, and update for underlying renaming.
13693 * spellcheck-tree.h (levenshtein_distance): Rename to...
13694 (get_edit_distance): ...this.
13695 * spellcheck.c (levenshtein_distance): Rename to...
13696 (get_edit_distance): ...this. Convert from Levenshtein distance
13697 to Damerau-Levenshtein distance by supporting transpositions of
13698 adjacent characters. Rename "v1" to "v_next" and "v0" to
13699 "v_one_ago".
13700 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
13701 (selftest::test_edit_distance_unit_test_oneway): ...this, and
13702 update for underlying renaming.
13703 (selftest::levenshtein_distance_unit_test): Rename to...
13704 (selftest::test_get_edit_distance_unit): ...this, and update for
13705 underlying renaming.
13706 (selftest::test_find_closest_string): Add example from PR 69968
13707 where transposition helps
13708 (selftest::test_metric_conditions): Update for renaming.
13709 (selftest::test_metric_conditions): Likewise.
13710 (selftest::spellcheck_c_tests): Likewise.
13711 * spellcheck.h (levenshtein_distance): Rename both overloads to...
13712 (get_edit_distance): ...this.
13713 (best_match::consider): Update for renaming.
13714
13715 2018-06-12 Martin Sebor <msebor@redhat.com>
13716
13717 PR tree-optimization/85259
13718 * builtins.c (compute_objsize): Handle constant offsets.
13719 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
13720 true iff a warning has been issued.
13721 * gimple.h (gimple_nonartificial_location): New function.
13722 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
13723 gimple_nonartificial_location and handle -Wno-system-headers.
13724 (handle_builtin_stxncpy): Same.
13725
13726 2018-06-12 Martin Sebor <msebor@redhat.com>
13727
13728 PR c/85931
13729 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
13730
13731 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
13732
13733 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
13734 BUILTIN_VEC_XST entries for pointer to double and long long.
13735
13736 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
13737
13738 PR target/85990
13739 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13740 Update comments.
13741 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13742 Likewise.
13743
13744 2018-06-12 Martin Liska <mliska@suse.cz>
13745
13746 * doc/options.texi: Document IntegerRange.
13747
13748 2018-06-12 Martin Liska <mliska@suse.cz>
13749
13750 * config/i386/i386.opt: Make MPX-related options as Deprecated.
13751 * opt-functions.awk: Handle Deprecated flag.
13752 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
13753 and report error.
13754 (read_cmdline_option): Report warning for a deprecated option.
13755 * opts.h (struct cl_option): Add new field cl_deprecated.
13756 (CL_ERR_DEPRECATED): New.
13757
13758 2018-06-12 Martin Liska <mliska@suse.cz>
13759
13760 * doc/options.texi: Document Deprecated option flag.
13761
13762 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13763
13764 * config/arc/arc-arch.h (arc_extras): New enum.
13765 (arc_cpu_t):Add field extra.
13766 (arc_cpu_types): Consider the extras.
13767 * config/arc/arc-cpus.def: Add extras info.
13768 * config/arc/arc-opts.h (processor_type): Consider extra field.
13769 * config/arc/arc.c (arc_override_options): Handle extra field.
13770
13771 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13772
13773 * config/arc/arc-arch.h: Update ARC_OPTX macro.
13774 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
13775 field.
13776 * config/arc/arc.c (arc_init): Update pic warning.
13777 (irq_range): Update irq range parsing warnings.
13778 (arc_override_options): Update various warning messages.
13779 (arc_handle_aux_attribute): Likewise.
13780
13781 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
13782
13783 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
13784
13785 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13786
13787 * doc/sourcebuild.texi: Document usage of line number 0 in verify
13788 compiler messages directives.
13789
13790 2018-06-12 Matthew Fortune <mfortune@gmail.com>
13791
13792 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
13793 * config/mips/mips-tables.opt: Regenerate.
13794 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
13795 mips64r6.
13796 * doc/invoke.texi: Document -march=i6500.
13797
13798 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
13799
13800 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
13801 (i6400_gpmul): Add cpu_unit.
13802 (i6400_gpdiv): Likewise.
13803 (i6400_msa_add_d): Update reservations.
13804 (i6400_msa_int_add) Likewise.
13805 (i6400_msa_short_logic3) Likewise.
13806 (i6400_msa_short_logic2) Likewise.
13807 (i6400_msa_short_logic) Likewise.
13808 (i6400_msa_move) Likewise.
13809 (i6400_msa_cmp) Likewise.
13810 (i6400_msa_short_float2) Likewise.
13811 (i6400_msa_div_d) Likewise.
13812 (i6400_msa_long_logic1) Likewise.
13813 (i6400_msa_long_logic2) Likewise.
13814 (i6400_msa_mult) Likewise.
13815 (i6400_msa_long_float2) Likewise.
13816 (i6400_msa_long_float4) Likewise.
13817 (i6400_msa_long_float5) Likewise.
13818 (i6400_msa_long_float8) Likewise.
13819 (i6400_fpu_fadd): Include frint type.
13820 (i6400_fpu_store): New define_insn_reservation.
13821 (i6400_fpu_load): Likewise.
13822 (i6400_fpu_move): Likewise.
13823 (i6400_fpu_fcmp): Likewise.
13824 (i6400_fpu_fmadd): Likewise.
13825 (i6400_int_mult): Include imul3nc type and update reservation.
13826 (i6400_int_div): Include idiv3 type and update reservation.
13827 (i6400_int_load): Update to check type not move_type.
13828 (i6400_int_store): Likewise.
13829 (i6400_int_prefetch): Set zero latency.
13830
13831 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
13832
13833 * gcc.c: Document new %@{...} sequence.
13834 (LINK_COMMAND_SPEC): Use it for the -L switches.
13835 (cpp_unique_options): Use it for the -I switches.
13836 (at_file_argbuf): New global variable.
13837 (in_at_file): Likewise.
13838 (alloc_args): Create at_file_argbuf.
13839 (clear_args): Truncate at_file_argbuf.
13840 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
13841 (open_at_file): New function.
13842 (close_at_file): Likewise.
13843 (create_at_file): Delete.
13844 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
13845 <'o'>: Likewise.
13846 <'@'>: New case.
13847 (validate_switches_from_spec): Deal with %@{...} sequence.
13848 (validate_switches): Likewise.
13849 (driver::finalize): Call clear_args.
13850
13851 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
13852
13853 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
13854
13855 2018-06-11 Martin Sebor <msebor@redhat.com>
13856
13857 * doc/invoke.texi (-Wall): List -Wc++17-compat.
13858 (Wno-class-memaccess): Add @opindex.
13859 (Wno-templates, Wno-multiple-inheritance): Same.
13860 (Wno-virtual-inheritance, Wno-namespaces): Same.
13861 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
13862 (Wno-format-overflow, Wno-format-truncation): Same.
13863 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
13864 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
13865 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
13866 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
13867 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
13868 (Wno-misspelled-isr): Same.
13869
13870 2018-06-11 Martin Sebor <msebor@redhat.com>
13871
13872 * PR tree-optimization/86083
13873 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
13874
13875 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
13876
13877 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
13878
13879 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
13880
13881 PR target/85755
13882 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
13883 on the correct operand.
13884 (*movdi_internal64): Ditto.
13885
13886 2018-06-11 Martin Liska <mliska@suse.cz>
13887
13888 PR tree-optimization/86089
13889 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
13890
13891 2018-06-11 Julia Koval <julia.koval@intel.com>
13892
13893 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
13894 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
13895 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
13896
13897 2018-06-11 Olivier Hainque <hainque@adacore.com>
13898
13899 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
13900 for Ada with strict dwarf2.
13901
13902 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
13903
13904 PR target/85755
13905 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
13906 addresses.
13907
13908 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
13909
13910 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
13911
13912 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
13913
13914 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
13915 TARGET_ELF.
13916
13917 2018-06-08 Martin Liska <mliska@suse.cz>
13918
13919 * tree-cfg.h (debug_function): Fix argument type to match
13920 implementation.
13921
13922 2018-06-08 Martin Liska <mliska@suse.cz>
13923
13924 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
13925 Remove usage of MPX-related (and removed) fields.
13926 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
13927
13928 2018-06-08 David Malcolm <dmalcolm@redhat.com>
13929
13930 * cfg.c (debug): Use TDF_NONE rather than 0.
13931 * cfghooks.c (debug): Likewise.
13932 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
13933 (struct dump_option_value_info): Convert to...
13934 (struct kv_pair): ...this template type.
13935 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
13936 rather than 0.
13937 (optinfo_verbosity_options): Likewise.
13938 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
13939 OPTGROUP_NONE.
13940 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
13941 than int for "optgroup_flags" param.
13942 (dump_generic_expr_loc): Use dump_flags_t rather than int for
13943 "dump_kind" param.
13944 (dump_dec): Likewise.
13945 (dump_finish): Use TDF_NONE rather than 0.
13946 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
13947 rather than int for "optgroup_flags" param. Use TDF_NONE rather
13948 than 0. Update for change to option_ptr.
13949 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
13950 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
13951 0. Update for changes to optinfo_verbosity_options and
13952 optgroup_options.
13953 (opt_info_switch_p): Convert optgroup_flags from int to
13954 optgroup_flags_t.
13955 (dump_basic_block): Use dump_flags_t rather than int
13956 for "dump_kind" param.
13957 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
13958 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
13959 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
13960 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
13961 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
13962 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
13963 TDF_NONE): Convert from macros to...
13964 (enum dump_flag): ...this new enum.
13965 (dump_flags_t): Update to use enum.
13966 (operator|, operator&, operator~, operator|=, operator&=):
13967 Implement for dump_flags_t.
13968 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
13969 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
13970 Convert from macros to...
13971 (enum optgroup_flag): ...this new enum.
13972 (optgroup_flags_t): New typedef.
13973 (operator|, operator|=): Implement for optgroup_flags_t.
13974 (struct dump_file_info): Convert field "alt_flags" to
13975 dump_flags_t. Convert field "optgroup_flags" to
13976 optgroup_flags_t.
13977 (dump_basic_block): Use dump_flags_t rather than int for param.
13978 (dump_generic_expr_loc): Likewise.
13979 (dump_dec): Likewise.
13980 (dump_register): Convert param "optgroup_flags" to
13981 optgroup_flags_t.
13982 (opt_info_enable_passes): Likewise.
13983 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
13984 than 0.
13985 * gimple-pretty-print.c (debug): Likewise.
13986 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
13987 (merged_store_group::apply_stores): Likewise.
13988 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
13989 * gimple.c (verify_gimple_pp): Likewise.
13990 * graphite-poly.c (print_pbb_body): Likewise.
13991 * passes.c (pass_manager::register_one_dump_file): Convert
13992 local "optgroup_flags" to optgroup_flags_t.
13993 * print-tree.c (print_node): Use TDF_NONE rather than 0.
13994 (debug): Likewise.
13995 (debug_body): Likewise.
13996 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
13997 to optgroup_flags_t.
13998 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
13999 than 0.
14000 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
14001 (convert_mult_to_fma): Likewise.
14002 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
14003 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
14004 * tree-vect-data-refs.c (dump_lower_bound): Convert param
14005 "dump_kind" to dump_flags_t.
14006
14007 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14008
14009 * config/rs6000/rs6000.c (min, max): Delete.
14010
14011 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14012
14013 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
14014 -mabi=spe and -mabi=no-spe.
14015
14016 2018-06-08 Martin Liska <mliska@suse.cz>
14017
14018 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
14019 where we expect an existing summary.
14020
14021 2018-06-08 Martin Liska <mliska@suse.cz>
14022
14023 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
14024 * ipa-inline.h (estimate_edge_growth): Likewise.
14025
14026 2018-06-08 Martin Liska <mliska@suse.cz>
14027
14028 * cgraph.c (function_version_hasher::hash): Use
14029 cgraph_node::get_uid ().
14030 (function_version_hasher::equal):
14031 * cgraph.h (cgraph_node::get_uid): New method.
14032 * ipa-inline.c (update_caller_keys): Use
14033 cgraph_node::get_uid ().
14034 (update_callee_keys): Likewise.
14035 * ipa-utils.c (searchc): Likewise.
14036 (ipa_reduced_postorder): Likewise.
14037 * lto-cgraph.c (input_node): Likewise.
14038 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
14039 * symbol-summary.h (symtab_insertion): Likewise.
14040 (symtab_removal): Likewise.
14041 (symtab_duplication): Likewise.
14042 * tree-pretty-print.c (dump_function_header): Likewise.
14043 * tree-sra.c (convert_callers_for_node): Likewise.
14044
14045 2018-06-08 Martin Liska <mliska@suse.cz>
14046
14047 * cgraph.c (symbol_table::create_edge): Always assign a new
14048 unique number.
14049 (symbol_table::free_edge): Do not recycle numbers.
14050 * cgraph.h (cgraph_edge::get): New method.
14051 * symbol-summary.h (symtab_removal): Use it.
14052 (symtab_duplication): Likewise.
14053 (call_summary::hashable_uid): Remove.
14054
14055 2018-06-08 Martin Liska <mliska@suse.cz>
14056
14057 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
14058 (initialize_growth_caches): Remove.
14059 (free_growth_caches): Likewise.
14060 (do_estimate_edge_time): Use edge_growth_cache.
14061 (do_estimate_edge_size): Likewise.
14062 (do_estimate_edge_hints): Likewise.
14063 * ipa-inline.c (reset_edge_caches): Likewise.
14064 (recursive_inlining): Likewise.
14065 (inline_small_functions): Likewise.
14066 * ipa-inline.h (initialize_growth_caches): Remove.
14067 (estimate_edge_size): Likewise.
14068 (estimate_edge_time): Likewise.
14069 (estimate_edge_hints): Likewise.
14070 (reset_edge_growth_cache): Likewise.
14071 * symbol-summary.h (call_summary::remove): New method.
14072
14073 2018-06-08 Martin Liska <mliska@suse.cz>
14074
14075 * ipa-cp.c (class edge_clone_summary): New summary.
14076 (grow_edge_clone_vectors): Remove.
14077 (ipcp_edge_duplication_hook): Remove.
14078 (class edge_clone_summary_t): New call_summary class.
14079 (ipcp_edge_removal_hook): Remove.
14080 (edge_clone_summary_t::duplicate): New function.
14081 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
14082 (create_specialized_node): Likewise.
14083 (ipcp_driver): Initialize edge_clone_summaries and do not
14084 register hooks.
14085
14086 2018-06-08 Martin Liska <mliska@suse.cz>
14087
14088 * symbol-summary.h (get): New function.
14089 (call_summary::m_initialize_when_cloning): New class member.
14090
14091 2018-06-08 Martin Liska <mliska@suse.cz>
14092
14093 * cgraph.c (cgraph_node::remove): Do not recycle uid.
14094 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
14095 (symbol_table::allocate_cgraph_symbol): Do not set uid.
14096 * passes.c (uid_hash_t): Record removed_nodes by their uids.
14097 (remove_cgraph_node_from_order): Use the removed_nodes set.
14098 (do_per_function_toporder): Likwise.
14099 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
14100 instead of summary_uid.
14101 (symtab_removal): Likewise.
14102 (symtab_duplication): Likewise.
14103
14104 2018-06-08 Martin Liska <mliska@suse.cz>
14105
14106 * ipa-cp.c (ipcp_store_bits_results): Use
14107 ipcp_transformation_sum.
14108 (ipcp_store_vr_results): Likewise.
14109 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
14110 to ...
14111 (ipcp_transformation_initialize): ... this.
14112 (ipa_set_node_agg_value_chain):
14113 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
14114 (write_ipcp_transformation_info): Likewise.
14115 (read_ipcp_transformation_info): Likewise.
14116 (ipcp_update_bits): Likewise.
14117 (ipcp_update_vr): Likewise.
14118 (ipcp_transform_function): Likewise.
14119 * ipa-prop.h: Rename ipcp_transformation_summary to
14120 ipcp_transformation.
14121 (class ipcp_transformation_t): New function summary.
14122 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
14123 (ipa_get_agg_replacements_for_node): Likewise.
14124
14125 2018-06-08 Martin Liska <mliska@suse.cz>
14126
14127 * ipa-pure-const.c (struct funct_state_d): Do it class instead
14128 of struct.
14129 (class funct_state_summary_t): New function_summary class.
14130 (has_function_state): Remove.
14131 (get_function_state): Likewise.
14132 (set_function_state): Likewise.
14133 (add_new_function): Likewise.
14134 (funct_state_summary_t::insert): New function.
14135 (duplicate_node_data): Remove.
14136 (remove_node_data): Remove.
14137 (funct_state_summary_t::duplicate): New function.
14138 (register_hooks): Create new funct_state_summaries.
14139 (pure_const_generate_summary): Use it.
14140 (pure_const_write_summary): Likewise.
14141 (pure_const_read_summary): Likewise.
14142 (propagate_pure_const): Likewise.
14143 (propagate_nothrow): Likewise.
14144 (dump_malloc_lattice): Likewise.
14145 (propagate_malloc): Likewise.
14146 (execute): Do not register hooks, just remove summary
14147 instead.
14148 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
14149 constructor.
14150
14151 2018-06-08 Martin Liska <mliska@suse.cz>
14152
14153 * ipa-reference.c (remove_node_data): Remove.
14154 (duplicate_node_data): Likewise.
14155 (class ipa_ref_var_info_summary_t): New class.
14156 (class ipa_ref_opt_summary_t): Likewise.
14157 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
14158 (get_reference_optimization_summary): Use
14159 ipa_ref_opt_sum_summaries.
14160 (set_reference_vars_info): Remove.
14161 (set_reference_optimization_summary): Likewise.
14162 (ipa_init): Create summaries.
14163 (init_function_info): Use function summary.
14164 (ipa_ref_opt_summary_t::duplicate): New function.
14165 (ipa_ref_opt_summary_t::remove): New function.
14166 (get_read_write_all_from_node): Fix GNU coding style.
14167 (propagate): Use function summary.
14168 (write_node_summary_p): Fix GNU coding style.
14169 (stream_out_bitmap): Likewise.
14170 (ipa_reference_read_optimization_summary): Use function summary.
14171 (ipa_reference_c_finalize): Do not release hooks.
14172
14173 2018-06-08 Martin Liska <mliska@suse.cz>
14174
14175 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
14176 (analyze_function_body): Extract multiple calls of get_create.
14177 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14178 * ipa-inline.c (recursive_inlining): Use ::get method.
14179 * ipa-inline.h (estimate_edge_growth): Likewise.
14180
14181 2018-06-08 Martin Liska <mliska@suse.cz>
14182
14183 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
14184 HSA_INVALID.
14185 (hsa_function_summary::hsa_function_summary): Use the new enum
14186 value.
14187 (hsa_gpu_implementation_p): Use hsa_summaries::get.
14188 * hsa-gen.c (hsa_get_host_function): Likewise.
14189 (get_brig_function_name): Likewise.
14190 * ipa-hsa.c (process_hsa_functions): Likewise.
14191 (ipa_hsa_write_summary): Likewise.
14192 * symbol-summary.h (symtab_duplication): Use ::get function/
14193 (get): New function.
14194
14195 2018-06-08 Martin Liska <mliska@suse.cz>
14196
14197 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
14198 of get.
14199 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
14200 (hsa_register_kernel): Likewise.
14201 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
14202 * hsa-gen.c (hsa_get_host_function): Likewise.
14203 (get_brig_function_name): Likewise.
14204 (generate_hsa): Likewise.
14205 (pass_gen_hsail::execute): Likewise.
14206 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
14207 (devirtualization_time_bonus): Likewise.
14208 (ipcp_propagate_stage): Likewise.
14209 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
14210 (edge_set_predicate): Likewise.
14211 (evaluate_conditions_for_known_args): Likewise.
14212 (evaluate_properties_for_edge): Likewise.
14213 (ipa_fn_summary::reset): Likewise.
14214 (ipa_fn_summary_t::duplicate): Likewise.
14215 (dump_ipa_call_summary): Likewise.
14216 (ipa_dump_fn_summary): Likewise.
14217 (analyze_function_body): Likewise.
14218 (compute_fn_summary): Likewise.
14219 (estimate_edge_devirt_benefit): Likewise.
14220 (estimate_edge_size_and_time): Likewise.
14221 (estimate_calls_size_and_time): Likewise.
14222 (estimate_node_size_and_time): Likewise.
14223 (inline_update_callee_summaries): Likewise.
14224 (remap_edge_change_prob): Likewise.
14225 (remap_edge_summaries): Likewise.
14226 (ipa_merge_fn_summary_after_inlining): Likewise.
14227 (ipa_update_overall_fn_summary): Likewise.
14228 (read_ipa_call_summary): Likewise.
14229 (inline_read_section): Likewise.
14230 (write_ipa_call_summary): Likewise.
14231 (ipa_fn_summary_write): Likewise.
14232 (ipa_free_fn_summary): Likewise.
14233 * ipa-hsa.c (process_hsa_functions): Likewise.
14234 (ipa_hsa_write_summary): Likewise.
14235 (ipa_hsa_read_section): Likewise.
14236 * ipa-icf.c (sem_function::merge): Likewise.
14237 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14238 (do_estimate_edge_time): Likewise.
14239 (estimate_size_after_inlining): Likewise.
14240 (estimate_growth): Likewise.
14241 (growth_likely_positive): Likewise.
14242 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
14243 (inline_call): Likewise.
14244 * ipa-inline.c (caller_growth_limits): Likewise.
14245 (can_inline_edge_p): Likewise.
14246 (can_inline_edge_by_limits_p): Likewise.
14247 (compute_uninlined_call_time): Likewise.
14248 (compute_inlined_call_time): Likewise.
14249 (want_inline_small_function_p): Likewise.
14250 (edge_badness): Likewise.
14251 (update_caller_keys): Likewise.
14252 (update_callee_keys): Likewise.
14253 (recursive_inlining): Likewise.
14254 (inline_small_functions): Likewise.
14255 (inline_to_all_callers_1): Likewise.
14256 (dump_overall_stats): Likewise.
14257 (early_inline_small_functions): Likewise.
14258 (early_inliner): Likewise.
14259 * ipa-inline.h (estimate_edge_growth): Likewise.
14260 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
14261 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
14262 * ipa-prop.h (IPA_NODE_REF): Likewise.
14263 (IPA_EDGE_REF): Likewise.
14264 * ipa-pure-const.c (malloc_candidate_p): Likewise.
14265 (propagate_malloc): Likewise.
14266 * ipa-split.c (execute_split_functions): Likewise.
14267 * symbol-summary.h: Rename get to get_create.
14268 (get): Likewise.
14269 (get_create): Likewise.
14270 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
14271
14272 2018-06-08 Martin Liska <mliska@suse.cz>
14273
14274 * symbol-summary.h (release): Move definition out of class
14275 declaration.
14276 (symtab_removal): Likewise.
14277 (symtab_duplication): Likewise.
14278
14279 2018-06-08 Martin Liska <mliska@suse.cz>
14280
14281 * symbol-summary.h (function_summary): Move constructor
14282 implementation out of class declaration.
14283 (release): Likewise.
14284 (symtab_insertion): Likewise.
14285 (symtab_removal): Likewise.
14286 (symtab_duplication): Likewise.
14287 (get): Likewise.
14288
14289 2018-06-08 Martin Liska <mliska@suse.cz>
14290
14291 * Makefile.in: Remove support for MPX (macros, related functions,
14292 fields in cgraph_node, ...).
14293 * builtin-types.def (BT_BND): Likewise.
14294 (BT_FN_BND_CONST_PTR): Likewise.
14295 (BT_FN_CONST_PTR_BND): Likewise.
14296 (BT_FN_VOID_PTR_BND): Likewise.
14297 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
14298 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
14299 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
14300 (expand_builtin_mempcpy_with_bounds): Likewise.
14301 (expand_builtin_memset_with_bounds): Likewise.
14302 (expand_builtin_memset_args): Likewise.
14303 (std_expand_builtin_va_start): Likewise.
14304 (expand_builtin): Likewise.
14305 (expand_builtin_with_bounds): Likewise.
14306 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
14307 (DEF_LIB_BUILTIN_CHKP): Likewise.
14308 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
14309 (DEF_CHKP_BUILTIN): Likewise.
14310 (BUILT_IN_MEMCPY): Likewise.
14311 (BUILT_IN_MEMMOVE): Likewise.
14312 (BUILT_IN_MEMPCPY): Likewise.
14313 (BUILT_IN_MEMSET): Likewise.
14314 (BUILT_IN_STPCPY): Likewise.
14315 (BUILT_IN_STRCAT): Likewise.
14316 (BUILT_IN_STRCHR): Likewise.
14317 (BUILT_IN_STRCPY): Likewise.
14318 (BUILT_IN_STRLEN): Likewise.
14319 (BUILT_IN_MEMCPY_CHK): Likewise.
14320 (BUILT_IN_MEMMOVE_CHK): Likewise.
14321 (BUILT_IN_MEMPCPY_CHK): Likewise.
14322 (BUILT_IN_MEMSET_CHK): Likewise.
14323 (BUILT_IN_STPCPY_CHK): Likewise.
14324 (BUILT_IN_STRCAT_CHK): Likewise.
14325 (BUILT_IN_STRCPY_CHK): Likewise.
14326 * calls.c (store_bounds): Likewise.
14327 (emit_call_1): Likewise.
14328 (special_function_p): Likewise.
14329 (maybe_warn_nonstring_arg): Likewise.
14330 (initialize_argument_information): Likewise.
14331 (finalize_must_preallocate): Likewise.
14332 (compute_argument_addresses): Likewise.
14333 (expand_call): Likewise.
14334 * cfgexpand.c (expand_call_stmt): Likewise.
14335 (expand_return): Likewise.
14336 (expand_gimple_stmt_1): Likewise.
14337 (pass_expand::execute): Likewise.
14338 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
14339 (cgraph_node::remove): Likewise.
14340 (cgraph_node::dump): Likewise.
14341 (cgraph_node::verify_node): Likewise.
14342 * cgraph.h (chkp_function_instrumented_p): Likewise.
14343 (symtab_node::get_alias_target): Likewise.
14344 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
14345 (cgraph_local_p): Likewise.
14346 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
14347 (cgraph_edge::rebuild_references): Likewise.
14348 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
14349 (walk_polymorphic_call_targets): Likewise.
14350 (cgraph_node::expand_thunk): Likewise.
14351 (symbol_table::output_weakrefs): Likewise.
14352 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
14353 (ix86_handle_option): Likewise.
14354 * config/i386/constraints.md: Likewise.
14355 * config/i386/i386-builtin-types.def (BND): Likewise.
14356 (VOID): Likewise.
14357 (PVOID): Likewise.
14358 (ULONG): Likewise.
14359 * config/i386/i386-builtin.def (BDESC_END): Likewise.
14360 (BDESC_FIRST): Likewise.
14361 (BDESC): Likewise.
14362 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
14363 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
14364 * config/i386/i386.c (enum reg_class): Likewise.
14365 (ix86_target_string): Likewise.
14366 (ix86_option_override_internal): Likewise.
14367 (ix86_conditional_register_usage): Likewise.
14368 (ix86_valid_target_attribute_inner_p): Likewise.
14369 (ix86_set_indirect_branch_type): Likewise.
14370 (ix86_set_current_function): Likewise.
14371 (ix86_function_arg_regno_p): Likewise.
14372 (init_cumulative_args): Likewise.
14373 (ix86_function_arg_advance): Likewise.
14374 (ix86_function_arg): Likewise.
14375 (ix86_pass_by_reference): Likewise.
14376 (ix86_function_value_regno_p): Likewise.
14377 (ix86_function_value_1): Likewise.
14378 (ix86_function_value_bounds): Likewise.
14379 (ix86_return_in_memory): Likewise.
14380 (ix86_setup_incoming_vararg_bounds): Likewise.
14381 (ix86_va_start): Likewise.
14382 (indirect_thunk_need_prefix): Likewise.
14383 (print_reg): Likewise.
14384 (ix86_print_operand): Likewise.
14385 (ix86_expand_call): Likewise.
14386 (ix86_output_function_return): Likewise.
14387 (reg_encoded_number): Likewise.
14388 (BDESC_VERIFYS): Likewise.
14389 (ix86_init_mpx_builtins): Likewise.
14390 (ix86_init_builtins): Likewise.
14391 (ix86_emit_cmove): Likewise.
14392 (ix86_emit_move_max): Likewise.
14393 (ix86_expand_builtin): Likewise.
14394 (ix86_builtin_mpx_function): Likewise.
14395 (ix86_get_arg_address_for_bt): Likewise.
14396 (ix86_load_bounds): Likewise.
14397 (ix86_store_bounds): Likewise.
14398 (ix86_load_returned_bounds): Likewise.
14399 (ix86_store_returned_bounds): Likewise.
14400 (ix86_class_likely_spilled_p): Likewise.
14401 (ix86_hard_regno_mode_ok): Likewise.
14402 (x86_order_regs_for_local_alloc): Likewise.
14403 (ix86_mitigate_rop): Likewise.
14404 (ix86_bnd_prefixed_insn_p): Likewise.
14405 (ix86_mpx_bound_mode): Likewise.
14406 (ix86_make_bounds_constant): Likewise.
14407 (ix86_initialize_bounds): Likewise.
14408 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
14409 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
14410 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
14411 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
14412 (TARGET_CHKP_BOUND_MODE): Likewise.
14413 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
14414 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
14415 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
14416 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
14417 * config/i386/i386.h (TARGET_MPX): Likewise.
14418 (TARGET_MPX_P): Likewise.
14419 (VALID_BND_REG_MODE): Likewise.
14420 (FIRST_BND_REG): Likewise.
14421 (LAST_BND_REG): Likewise.
14422 (enum reg_class): Likewise.
14423 (BND_REG_P): Likewise.
14424 (BND_REGNO_P): Likewise.
14425 (BNDmode): Likewise.
14426 (ADJUST_INSN_LENGTH): Likewise.
14427 * config/i386/i386.md: Likewise.
14428 * config/i386/i386.opt: Likewise.
14429 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
14430 (defined): Likewise.
14431 (LINK_MPX): Likewise.
14432 (MPX_SPEC): Likewise.
14433 (LIBMPX_SPEC): Likewise.
14434 (LIBMPXWRAPPERS_SPEC): Likewise.
14435 (CHKP_SPEC): Likewise.
14436 * config/i386/predicates.md: Likewise.
14437 * dbxout.c (dbxout_type): Likewise.
14438 * doc/extend.texi: Likewise.
14439 * doc/invoke.texi: Likewise.
14440 * doc/md.texi: Likewise.
14441 * doc/tm.texi: Likewise.
14442 * doc/tm.texi.in: Likewise.
14443 * dwarf2out.c (is_base_type): Likewise.
14444 (gen_formal_types_die): Likewise.
14445 (gen_subprogram_die): Likewise.
14446 (gen_type_die_with_usage): Likewise.
14447 (gen_decl_die): Likewise.
14448 (dwarf2out_late_global_decl): Likewise.
14449 * expr.c (expand_assignment): Likewise.
14450 (emit_storent_insn): Likewise.
14451 (store_expr_with_bounds): Likewise.
14452 (store_expr): Likewise.
14453 (expand_expr_real_1): Likewise.
14454 * expr.h (store_expr_with_bounds): Likewise.
14455 * function.c (use_register_for_decl): Likewise.
14456 (struct bounds_parm_data): Likewise.
14457 (assign_parms_augmented_arg_list): Likewise.
14458 (assign_parm_find_entry_rtl): Likewise.
14459 (assign_parm_is_stack_parm): Likewise.
14460 (assign_parm_load_bounds): Likewise.
14461 (assign_bounds): Likewise.
14462 (assign_parms): Likewise.
14463 (expand_function_start): Likewise.
14464 * gcc.c (CHKP_SPEC): Likewise.
14465 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
14466 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
14467 (wrestrict_dom_walker::check_call): Likewise.
14468 * gimple.c (gimple_build_call_from_tree): Likewise.
14469 * gimple.h (enum gf_mask): Likewise.
14470 (gimple_call_with_bounds_p): Likewise.
14471 (gimple_call_set_with_bounds): Likewise.
14472 * gimplify.c (gimplify_init_constructor): Likewise.
14473 * ipa-cp.c (initialize_node_lattices): Likewise.
14474 (propagate_constants_across_call): Likewise.
14475 (find_more_scalar_values_for_callers_subset): Likewise.
14476 * ipa-hsa.c (process_hsa_functions): Likewise.
14477 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
14478 * ipa-icf.c (sem_function::merge): Likewise.
14479 * ipa-inline.c (early_inliner): Likewise.
14480 * ipa-pure-const.c (warn_function_noreturn): Likewise.
14481 (warn_function_cold): Likewise.
14482 (propagate_pure_const): Likewise.
14483 * ipa-ref.h (enum GTY): Likewise.
14484 * ipa-split.c (find_retbnd): Likewise.
14485 (consider_split): Likewise.
14486 (split_function): Likewise.
14487 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
14488 * ipa.c (walk_polymorphic_call_targets): Likewise.
14489 (symbol_table::remove_unreachable_nodes): Likewise.
14490 (process_references): Likewise.
14491 (cgraph_build_static_cdtor_1): Likewise.
14492 * lto-cgraph.c (lto_output_node): Likewise.
14493 (output_refs): Likewise.
14494 (compute_ltrans_boundary): Likewise.
14495 (input_overwrite_node): Likewise.
14496 (input_node): Likewise.
14497 (input_cgraph_1): Likewise.
14498 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
14499 * passes.c (pass_manager::execute_early_local_passes): Likewise.
14500 (class pass_chkp_instrumentation_passes): Likewise.
14501 (make_pass_chkp_instrumentation_passes): Likewise.
14502 * passes.def: Likewise.
14503 * rtl.h (struct GTY): Likewise.
14504 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
14505 * stor-layout.c (layout_type): Likewise.
14506 * symtab.c: Likewise.
14507 * target.def: Likewise.
14508 * targhooks.c (default_chkp_bound_type): Likewise.
14509 (default_chkp_bound_mode): Likewise.
14510 (default_builtin_chkp_function): Likewise.
14511 (default_chkp_function_value_bounds): Likewise.
14512 (default_chkp_make_bounds_constant): Likewise.
14513 (default_chkp_initialize_bounds): Likewise.
14514 * targhooks.h (default_chkp_bound_type): Likewise.
14515 (default_chkp_bound_mode): Likewise.
14516 (default_builtin_chkp_function): Likewise.
14517 (default_chkp_function_value_bounds): Likewise.
14518 (default_chkp_make_bounds_constant): Likewise.
14519 (default_chkp_initialize_bounds): Likewise.
14520 * toplev.c (compile_file): Likewise.
14521 (process_options): Likewise.
14522 * tree-core.h (DEF_BUILTIN): Likewise.
14523 (DEF_BUILTIN_CHKP): Likewise.
14524 * tree-inline.c (declare_return_variable): Likewise.
14525 (remap_gimple_stmt): Likewise.
14526 (copy_bb): Likewise.
14527 (initialize_inlined_parameters): Likewise.
14528 (expand_call_inline): Likewise.
14529 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
14530 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
14531 (make_pass_ipa_chkp_produce_thunks): Likewise.
14532 (make_pass_chkp): Likewise.
14533 (make_pass_chkp_opt): Likewise.
14534 (make_pass_chkp_instrumentation_passes): Likewise.
14535 * tree-pretty-print.c (dump_generic_node): Likewise.
14536 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
14537 * tree-ssa-dce.c (propagate_necessity): Likewise.
14538 (eliminate_unnecessary_stmts): Likewise.
14539 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
14540 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
14541 * tree-ssa-sccvn.h: Likewise.
14542 * tree-ssa-strlen.c (get_string_length): Likewise.
14543 (valid_builtin_call): Likewise.
14544 (adjust_last_stmt): Likewise.
14545 (handle_builtin_strchr): Likewise.
14546 (handle_builtin_strcpy): Likewise.
14547 (handle_builtin_stxncpy): Likewise.
14548 (handle_builtin_memcpy): Likewise.
14549 (handle_builtin_strcat): Likewise.
14550 (strlen_check_and_optimize_stmt): Likewise.
14551 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
14552 * tree-streamer-in.c: Likewise.
14553 * tree-streamer.c (record_common_node): Likewise.
14554 * tree.c (tree_code_size): Likewise.
14555 (wide_int_to_tree_1): Likewise.
14556 (type_contains_placeholder_1): Likewise.
14557 (build_common_tree_nodes): Likewise.
14558 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
14559 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
14560 (POINTER_BOUNDS_P): Likewise.
14561 (BOUNDED_TYPE_P): Likewise.
14562 (BOUNDED_P): Likewise.
14563 (CALL_WITH_BOUNDS_P): Likewise.
14564 (pointer_bounds_type_node): Likewise.
14565 * value-prof.c (gimple_ic): Likewise.
14566 * var-tracking.c (vt_add_function_parameters): Likewise.
14567 * varasm.c (make_decl_rtl): Likewise.
14568 (assemble_start_function): Likewise.
14569 (output_constant): Likewise.
14570 (maybe_assemble_visibility): Likewise.
14571 * varpool.c (ctor_for_folding): Likewise.
14572 * chkp-builtins.def: Remove.
14573 * ipa-chkp.c: Remove.
14574 * ipa-chkp.h: Remove.
14575 * rtl-chkp.c: Remove.
14576 * rtl-chkp.h: Remove.
14577 * tree-chkp-opt.c: Remove.
14578 * tree-chkp.c: Remove.
14579 * tree-chkp.h: Remove.
14580
14581 2018-06-07 Carl Love <cel@us.ibm.com>
14582
14583 * config/rs6000/vsx.md (vextract_fp_from_shorth,
14584 vextract_fp_from_shortl): Add BE support.
14585
14586 2018-06-07 Paul Koning <ni1d@arrl.net>
14587
14588 * compare-elim.c (try_merge_compare): Don't merge compare if
14589 address contains a side effect.
14590 (try_eliminate_compare): Likewise.
14591
14592 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
14593
14594 * config.gcc: Support "tremont".
14595 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
14596 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14597 PROCESSOR_TREMONT.
14598 * config/i386/i386.c (m_TREMONT): Define.
14599 (processor_target_table): Add "tremont".
14600 (PTA_TREMONT): Define.
14601 (ix86_lea_outperforms): Add TARGET_TREMONT.
14602 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
14603 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
14604 and M_INTEL_GOLDMONT_PLUS.
14605 (fold_builtin_cpu): Add "tremont".
14606 (ix86_add_stmt_cost): Add TARGET_TREMONT.
14607 (ix86_option_override_internal): Add "tremont".
14608 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
14609 (processor_type): Add PROCESSOR_TREMONT.
14610 * config/i386/x86-tune.def: Add m_TREMONT.
14611 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
14612
14613 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14614
14615 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
14616 symbol defined for msp430i* devices to be lower case.
14617
14618 2018-06-07 Richard Biener <rguenther@suse.de>
14619
14620 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
14621 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
14622 Properly wrap signed arithmetic if overflow wraps.
14623
14624 2018-06-07 Jakub Jelinek <jakub@redhat.com>
14625
14626 PR tree-optimization/69615
14627 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
14628 of a cast from a same precision integral SSA_NAME in a bb dominated
14629 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
14630 cast to utype if rhs2 has already a compatible type.
14631
14632 2018-06-07 Richard Biener <rguenther@suse.de>
14633
14634 PR tree-optimization/85935
14635 * graphite-scop-detection.c (find_params_in_bb): Analyze
14636 condition operands with respect to the correct loop. Assert
14637 the analysis doesn't fail.
14638
14639 2018-06-04 Carl Love <cel@us.ibm.com>
14640
14641 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
14642 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
14643 as it is slightly cheaper.
14644 (first_match_or_eos_index_<mode>):
14645 Calculate index using natural element order.
14646 (first_match_index_<mode>):
14647 Calculate index using natural element order.
14648 (first_match_or_eos_index_<mode>):
14649 Calculate index using natural order.
14650 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
14651 for BE and LE modes.
14652 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
14653 P9V_BUILTIN_VCLZLSBB_V16QI.
14654 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
14655 specific.
14656
14657 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14658
14659 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
14660 indentation and line wrap for many prototypes. Add missing
14661 @smallexample directives around block of prototypes for vec_xl and
14662 vec_xst.
14663
14664 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
14665
14666 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
14667 track if we pass or return IEEE 128-bit floating point.
14668 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
14669 C++ mangling that is compatible with GCC 8.1.
14670 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
14671 (init_cumulative_args): Note if we pass or return IEEE 128-bit
14672 floating point types.
14673 (rs6000_function_arg_advance_1): Likewise.
14674 (rs6000_mangle_type): Optionally generate mangled names that match
14675 what GCC 8.1 generated for IEEE 128-bit floating point types.
14676 (rs6000_globalize_decl_name): If we have an external function that
14677 passes or returns IEEE 128-bit types, generate a weak reference
14678 from the mangled name used in GCC 8.1 to the current mangled
14679 name.
14680 (rs6000_init_builtins): Make __ibm128 use the long double type if
14681 long double is IBM extended double. Make __float128 use the long
14682 double type if long double is IEEE 128-bit.
14683
14684 PR target/85657
14685 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
14686 macro for __ibm128 built-in functions.
14687 (PACK_IF): Add __ibm128 pack/unpack functions.
14688 (UNPACK_IF): Likewise.
14689 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
14690 enable long double built-in functions if long double is IEEE
14691 128-bit floating point.
14692 (rs6000_invalid_builtin): Update long double built-in function
14693 error message.
14694 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
14695 functions, adjust the built-in function to use the long double
14696 built-in function if __ibm128 and long double are the same type.
14697 * doc/extend.texi (PowerPC builtins): Update documention for
14698 __builtin_{,un}pack_longdouble. Add documentation for
14699 __builtin_{,un}pack_ibm128.
14700
14701 2018-06-06 Jim Wilson <jimw@sifive.com>
14702
14703 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
14704 (struct machine_function): New field interrupt_mode.
14705 (riscv_handle_type_attribute): New function. Add forward declaration.
14706 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
14707 (riscv_expand_epilogue): Check interrupt_mode field.
14708 (riscv_set_current_function): Check interrupt attribute args and
14709 set interrupt_mode field.
14710 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
14711 (riscv_sret, riscv_uret): New.
14712 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
14713 new arguments to interrupt attribute.
14714
14715 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
14716
14717 PR target/63177
14718 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
14719 Don't handle -mcpu=power8 if -mpower9-vector is also used.
14720
14721 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14722
14723 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
14724 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
14725 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
14726 several redundant entries.
14727
14728 2018-06-06 David Malcolm <dmalcolm@redhat.com>
14729
14730 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
14731 type from "rtx" to "rtx_insn *".
14732 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
14733 for local "call_insn", removing cast.
14734 (ix86_expand_call): Likewise, introducing a "call_insn" local.
14735
14736 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
14737
14738 PR tree-optimization/86066
14739 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
14740 for BIT_INSERT_EXPR stores.
14741
14742 2018-06-06 Richard Biener <rguenther@suse.de>
14743
14744 PR tree-optimization/86062
14745 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
14746 component refs ontop
14747 of to be offsetted base.
14748
14749 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14750
14751 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
14752 to be static and remove check on interrupt attribute name.
14753
14754 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
14755
14756 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
14757 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
14758
14759 2018-06-05 Steve Ellcey <sellcey@cavium.com>
14760
14761 PR target/79924
14762 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
14763 second argument.
14764 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
14765 Remove second argument, change how error is called.
14766 (aarch64_layout_arg): Remove second argument from
14767 aarch64_err_no_fpadvsimd call.
14768 (aarch64_init_cumulative_args): Ditto.
14769 (aarch64_gimplify_va_arg_expr): Ditto.
14770 * config/aarch64/aarch64.md (mov<mode>): Ditto.
14771
14772 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
14773
14774 * config/i386/i386.md (simple_return_indirect_internal): New expander.
14775 (*simple_return_indirect_internal<mode>): Rename from
14776 simple_return_indirect_internal. Use W mode iterator.
14777 (rstorssp): New expander.
14778 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
14779 (clrssbsy): New expander.
14780 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
14781
14782 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
14783
14784 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
14785 __typeof__.
14786 (cmse_check_pointed_object): Likewise.
14787
14788 2018-06-05 Martin Liska <mliska@suse.cz>
14789
14790 PR gcov-profile/47618
14791 * doc/invoke.texi: Document how -fprofile-dir format
14792 is extended.
14793
14794 2018-06-05 Richard Biener <rguenther@suse.de>
14795
14796 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
14797 removal pretend DOM info isn't available so we do not update
14798 it and only remove edges, not dominated blocks. Actually free
14799 DOM info in case we removed something. Remove unreachable blocks.
14800 (mfb_keep_latches): Work with either DOM info or marked backedges.
14801 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
14802 first. Mark backedges if DOM info isn't available.
14803 (Re-)compute DOM info after cleanup_control_flow_pre.
14804
14805 2018-06-05 Richard Biener <rguenther@suse.de>
14806
14807 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
14808 (locus_discrim_hasher::hash): Adjust.
14809 (locus_discrim_hasher::equal): Likewise.
14810 (next_discriminator_for_locus): Work on line directly.
14811 (same_line_p): Pass in expanded locus1 as well.
14812 (assign_discriminators): Avoid redundant location expansions.
14813
14814 2018-06-05 Richard Biener <rguenther@suse.de>
14815
14816 PR tree-optimization/86046
14817 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
14818 if required after clearing TREE_ADDRESSABLE.
14819
14820 2018-06-05 Richard Biener <rguenther@suse.de>
14821
14822 PR tree-optimization/86047
14823 * tree-ssa-loop.c (for_each_index): Glob handling of all
14824 decls and constants and really handle all of them.
14825
14826 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14827
14828 PR target/81497
14829 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
14830 qualifier_void_pointer and qualifier_const_void_pointer.
14831 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
14832 (arm_init_builtins): Handle the above.
14833 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
14834 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
14835 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
14836 void intrinsics.
14837
14838 2018-06-05 Martin Liska <mliska@suse.cz>
14839
14840 * auto-profile.c (read_autofdo_file): Do not use
14841 gcov_ctr_summary struct.
14842 (afdo_callsite_hot_enough_for_early_inline): Likewise.
14843 * coverage.c (struct counts_entry): Likewise.
14844 (read_counts_file): Read just single summary entry.
14845 (get_coverage_counts): Use gcov_summary struct.
14846 * coverage.h (get_coverage_counts): Likewise.
14847 * gcov-dump.c (dump_working_sets): Likewise.
14848 (tag_summary): Dump just single summary.
14849 * gcov-io.c (gcov_write_summary): Write just histogram
14850 summary.
14851 (gcov_read_summary): Read just single summary.
14852 (compute_working_sets): Use gcov_summary struct.
14853 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
14854 of GCOV_COUNTERS_SUMMABLE.
14855 (GCOV_COUNTERS_SUMMABLE): Remove.
14856 (GCOV_FIRST_VALUE_COUNTER): Replace with
14857 GCOV_COUNTER_V_INTERVAL.
14858 (struct gcov_ctr_summary): Remove.
14859 (struct gcov_summary): Directly use fields of former
14860 gcov_ctr_summary.
14861 (compute_working_sets): Use gcov_summary struct.
14862 * gcov.c (read_count_file): Do not use ctrs fields.
14863 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
14864 struct.
14865 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
14866 struct.
14867 * profile.c: Likewise.
14868 * profile.h: Likewise.
14869
14870 2018-06-05 Martin Liska <mliska@suse.cz>
14871
14872 PR gcov-profile/84846
14873 * gcov.c (output_lines): Print working directory only
14874 in intermediate format.
14875
14876 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
14877
14878 * config/s390/s390-builtin-types.def: Add void function type.
14879 * config/s390/s390-builtins.def: Use the function type for the
14880 tbeginc builtin.
14881
14882 2018-06-04 Jim Wilson <jimw@sifive.com>
14883
14884 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
14885 to int.
14886 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
14887 and maybe_eh_return. Change regno to unsigned int. Use new args to
14888 handle EH_RETURN_DATA_REGNO registers properly.
14889 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
14890 (riscv_expand_epilogue): Update comment. Change argument name and
14891 type. Update code to use new name and type. Pass new args to
14892 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
14893 EXCEPTION_RETURN.
14894 * config/riscv/riscv.md (NORMAL_RETURN): New.
14895 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
14896 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
14897 (eh_return): Call gen_eh_return_internal and emit barrier.
14898 (eh_return_internal): Call riscv_expand_epilogue.
14899
14900 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
14901
14902 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
14903 bit_insertion field and declare can_be_merged_into method.
14904 (merged_store_group::can_be_merged_into): New method.
14905 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
14906 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
14907 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
14908
14909 2018-06-04 Richard Biener <rguenther@suse.de>
14910
14911 PR tree-optimization/85955
14912 * builtins.c (fold_builtin_sincos): Convert pointers to
14913 destination to appropriate type before dereferencing.
14914
14915 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
14916
14917 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
14918
14919 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
14920
14921 * expr.c (expand_expr_real_1): Force the operand into memory if
14922 its TYPE_MODE is BLKmode and if there is no integer mode for
14923 the number of bits being extracted.
14924
14925 2018-06-04 Jakub Jelinek <jakub@redhat.com>
14926
14927 PR target/85832
14928 PR target/86036
14929 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
14930 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
14931
14932 2018-06-04 Richard Biener <rguenther@suse.de>
14933
14934 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
14935 (cleanup_tree_cfg_noloop): ... single caller. Do
14936 start_recording_case_labels later.
14937
14938 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
14939
14940 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
14941 to _IMMINTRIN_H_INCLUDED.
14942 * config/i386/pconfigintrin.h: Ditto.
14943 * config/i386/waitpkgintrin.h: Ditto.
14944 * config/i386/immintrin.h: Add includes for sgxintrin.h,
14945 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
14946 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
14947 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
14948 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
14949 waitpkgintrin.h and cldemoteintrin.h.
14950
14951 2018-06-04 Richard Biener <rguenther@suse.de>
14952
14953 PR tree-optimization/86038
14954 * tracer.c (find_best_successor): Check probability for
14955 being initialized, bail out if not.
14956
14957 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
14958
14959 PR target/86003
14960 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
14961 of bits to ignore when comparing architectures.
14962
14963 2018-06-04 Jakub Jelinek <jakub@redhat.com>
14964
14965 PR tree-optimization/69615
14966 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
14967 maximum or minimum of the type, try to merge it also as if
14968 range1 is + [-, x - 1] or + [x + 1, -].
14969
14970 PR c++/86025
14971 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
14972
14973 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
14974
14975 PR tree-optimization/86034
14976 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
14977 the unsigned bitfield type in a bit insertion sequence if it does not
14978 have a larger precision than the bitfield size.
14979 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
14980
14981 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
14982
14983 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
14984
14985 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
14986
14987 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
14988 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
14989 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
14990 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
14991
14992 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
14993
14994 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
14995 Disable -fdelete-null-pointer-checks for ELF toolchain.
14996
14997 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
14998 Kito Cheng <kito.cheng@gmail.com>
14999
15000 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
15001 (nds32le-*-*, nds32be-*-*): Integrate checking process.
15002 (nds32*-*-*): Add glibc and uclibc conditions.
15003 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
15004 (TARGET_EXCEPT_UNWIND_INFO): Define.
15005 * config/nds32/elf.h: New file.
15006 * config/nds32/linux.h: New file.
15007 * config/nds32/nds32-elf.opt: New file.
15008 * config/nds32/nds32-linux.opt: New file.
15009 * config/nds32/nds32-fp-as-gp.c
15010 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
15011 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
15012 TARGET_LINUX_ABI.
15013 (nds32_asm_file_end): Ditto.
15014 (nds32_print_operand): Ditto.
15015 (nds32_insert_attributes): Ditto.
15016 (nds32_init_libfuncs): New function.
15017 (TARGET_HAVE_TLS): Define.
15018 (TARGET_INIT_LIBFUNCS): Define.
15019 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
15020 spec content.
15021 (TARGET_ELF): Apply different mcmodel setting.
15022 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
15023 been migrated into elf.h and linux.h files.
15024 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
15025 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
15026 (mcmodel): The content has been migrated into nds32-elf.opt and
15027 nds32-linux.opt files.
15028 * config/nds32/t-elf: New file.
15029 * config/nds32/t-linux: New file.
15030
15031 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
15032 Shiva Chen <shiva0217@gmail.com>
15033
15034 * config/nds32/constants.md (unspec_volatile_element): Add
15035 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
15036 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
15037 optimization.
15038 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
15039 (make_pass_nds32_fp_as_gp): Declare.
15040 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
15041 optmization pass.
15042 (nds32_asm_function_end_prologue): Remove unused asm output.
15043 (nds32_asm_function_begin_epilogue): Remove unused asm output.
15044 (nds32_asm_file_start): Output necessary fp_as_gp information.
15045 (nds32_option_override): Adjust register usage.
15046 (nds32_expand_prologue): Consider fp_as_gp situation.
15047 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
15048 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
15049 (epilogue): Ditto.
15050 (return): Ditto.
15051 (simple_return): Ditto.
15052 (omit_fp_begin): Output special directive for fp_as_gp.
15053 (omit_fp_end): Output special directive for fp_as_gp.
15054 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
15055 mforbid-fp-as-gp): New options.
15056
15057 2018-06-01 Mark Wielaard <mark@klomp.org>
15058
15059 * dwarf2out.c (dwarf2out_finish): Remove generation of
15060 DW_AT_loclists_base.
15061
15062 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
15063
15064 * gimple-ssa-store-merging.c: Include gimple-fold.h.
15065 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
15066 (struct merged_store_group): Add bit_insertion field.
15067 (dump_char_array): Use standard hexadecimal format.
15068 (merged_store_group::merged_store_group): Set bit_insertion to false.
15069 (merged_store_group::apply_stores): Use optimal buffer size. Deal
15070 with BIT_INSERT_EXPR stores. Move up code updating the mask and
15071 also print the mask in the dump file.
15072 (pass_store_merging::gate): Minor tweak.
15073 (imm_store_chain_info::coalesce_immediate): Fix wrong association
15074 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
15075 stores with INTEGER_CST stores.
15076 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
15077 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
15078 and use it throughout. Generate bit insertion sequences if need be.
15079 (pass_store_merging::process_store): Remove redundant condition.
15080 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
15081
15082 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
15083
15084 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
15085 the 128-bit floating point types. Fix function comment.
15086
15087 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15088
15089 * config/aarch64/aarch64-simd.md
15090 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
15091 mnemonics.
15092 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
15093 mnemonics.
15094
15095 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15096
15097 PR tree-optimization/85989
15098 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
15099 variable.
15100 (backprop::intersect_uses): Check it when deciding whether this
15101 is a backedge reference.
15102 (backprop::process_block): Add each phi to m_visited_phis
15103 after visiting it, then clear it at the end.
15104
15105 2018-06-01 Richard Biener <rguenther@suse.de>
15106
15107 * tree-vectorizer.h (vect_dr_stmt): New function.
15108 (vect_get_load_cost): Adjust.
15109 (vect_get_store_cost): Likewise.
15110 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
15111 Use vect_dr_stmt instead of DR_SMTT.
15112 (vect_record_base_alignments): Likewise.
15113 (vect_calculate_target_alignment): Likewise.
15114 (vect_compute_data_ref_alignment): Likewise and make static.
15115 (vect_update_misalignment_for_peel): Likewise.
15116 (vect_verify_datarefs_alignment): Likewise.
15117 (vector_alignment_reachable_p): Likewise.
15118 (vect_get_data_access_cost): Likewise. Pass down
15119 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
15120 (vect_get_peeling_costs_all_drs): Likewise.
15121 (vect_peeling_hash_get_lowest_cost): Likewise.
15122 (vect_enhance_data_refs_alignment): Likewise.
15123 (vect_find_same_alignment_drs): Likewise.
15124 (vect_analyze_data_refs_alignment): Likewise.
15125 (vect_analyze_group_access_1): Likewise.
15126 (vect_analyze_group_access): Likewise.
15127 (vect_analyze_data_ref_access): Likewise.
15128 (vect_analyze_data_ref_accesses): Likewise.
15129 (vect_vfa_segment_size): Likewise.
15130 (vect_small_gap_p): Likewise.
15131 (vectorizable_with_step_bound_p): Likewise.
15132 (vect_prune_runtime_alias_test_list): Likewise.
15133 (vect_analyze_data_refs): Likewise.
15134 (vect_supportable_dr_alignment): Likewise.
15135 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
15136 (vect_gen_prolog_loop_niters): Likewise.
15137 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
15138 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
15139 modify DR_STMT.
15140 (vect_recog_mask_conversion_pattern): Likewise.
15141 (vect_try_gather_scatter_pattern): Likewise.
15142 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
15143 to vect_get_store_cost.
15144 (vect_get_store_cost): Get stmt_info instead of DR.
15145 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
15146 (vect_get_load_cost): Get stmt_info instead of DR.
15147
15148 2018-06-01 Richard Biener <rguenther@suse.de>
15149
15150 PR middle-end/86017
15151 * gimple-fold.c (var_decl_component_p): Also allow offsetted
15152 vars wrapped in MEM_REFs.
15153
15154 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15155
15156 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15157 Fix subreg tests so that we only return a choice between
15158 GENERAL_REGS and FP_REGS if the original classes included both.
15159
15160 2018-06-01 Richard Biener <rguenther@suse.de>
15161
15162 PR ipa/85960
15163 * tree-ssa-structalias.c (get_function_part_constraint):
15164 Handle NULL fi->decl.
15165 (find_func_aliases_for_call): Properly handle indirect
15166 fi from direct call.
15167 (find_func_clobbers): Likewise.
15168 (ipa_pta_execute): Likewise.
15169 (create_variable_info_for): For functions that are ifunc_resolver
15170 resolve to a varinfo that contains the result of the resolver call.
15171 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
15172 aliases.
15173
15174 2018-05-31 Michael Collison <michael.collison@arm.com>
15175
15176 * config/aarch64/aarch64.md:
15177 (*fix_to_zero_extenddfdi2): New pattern.
15178 * gcc.target/aarch64/fix_extend1.c: New testcase.
15179
15180 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
15181
15182 PR middle-end/78809
15183 PR middle-end/83026
15184 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
15185 and BUILT_IN_STRNCMP_EQ.
15186 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
15187 BUILT_IN_STRNCMP_EQ.
15188 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
15189 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15190 (gimple_fold_builtin): Likewise.
15191 * tree-ssa-strlen.c (compute_string_length): New function.
15192 (determine_min_obsize): New function.
15193 (handle_builtin_string_cmp): New function to handle calls to
15194 string compare functions.
15195 (strlen_optimize_stmt): Add handling to builtin string compare
15196 calls.
15197 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
15198 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15199 * tree.c (build_common_builtin_nodes): Add new defines of
15200 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
15201
15202 2018-05-31 Jakub Jelinek <jakub@redhat.com>
15203
15204 PR target/85984
15205 * bb-reorder.c (pass_partition_blocks::gate): Return false for
15206 functions with naked attribute.
15207
15208 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
15209
15210 * config/i386/sse.md (avx_vec_concat<mode>):
15211 Substitute concat_tg_mode mode attribute with xtg_mode.
15212 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
15213 (concat_tg_mode): Remove mode attribute.
15214
15215 2018-05-31 Martin Sebor <msebor@redhat.com>
15216
15217 PR c/82063
15218 * calls.c (alloc_max_size): Correct a logic error/typo.
15219 Treat excessive arguments as infinite. Warn for invalid arguments.
15220 * doc/invoke.texi (-Walloc-size-larger-than): Update.
15221
15222 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
15223
15224 PR target/85829
15225 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
15226 and movx for Haswell.
15227
15228 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
15229 Cesar Philippidis <cesar@codesourcery.com>
15230
15231 PR middle-end/85879
15232 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
15233 when emitting error on private/firstprivate reductions.
15234 * omp-low.c (lower_omp_target): Avoid reference-type processing
15235 on pointers for firstprivate clause.
15236
15237 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15238
15239 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
15240 (st1x2): Likewise.
15241 (st1x3): Likewise.
15242 * config/aarch64/aarch64-simd.md
15243 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
15244 (aarch64_ld1_x3_<mode>): Likewise
15245 (aarch64_st1x2<VALLDIF:mode>): Likewise
15246 (aarch64_st1_x2_<mode>): Likewise
15247 (aarch64_st1x3<VALLDIF:mode>): Likewise
15248 (aarch64_st1_x3_<mode>): Likewise
15249 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
15250 (vld1_s8_x3): Likewise.
15251 (vld1_u16_x3): Likewise.
15252 (vld1_s16_x3): Likewise.
15253 (vld1_u32_x3): Likewise.
15254 (vld1_s32_x3): Likewise.
15255 (vld1_u64_x3): Likewise.
15256 (vld1_s64_x3): Likewise.
15257 (vld1_f16_x3): Likewise.
15258 (vld1_f32_x3): Likewise.
15259 (vld1_f64_x3): Likewise.
15260 (vld1_p8_x3): Likewise.
15261 (vld1_p16_x3): Likewise.
15262 (vld1_p64_x3): Likewise.
15263 (vld1q_u8_x3): Likewise.
15264 (vld1q_s8_x3): Likewise.
15265 (vld1q_u16_x3): Likewise.
15266 (vld1q_s16_x3): Likewise.
15267 (vld1q_u32_x3): Likewise.
15268 (vld1q_s32_x3): Likewise.
15269 (vld1q_u64_x3): Likewise.
15270 (vld1q_s64_x3): Likewise.
15271 (vld1q_f16_x3): Likewise.
15272 (vld1q_f32_x3): Likewise.
15273 (vld1q_f64_x3): Likewise.
15274 (vld1q_p8_x3): Likewise.
15275 (vld1q_p16_x3): Likewise.
15276 (vld1q_p64_x3): Likewise.
15277 (vst1_s64_x2): Likewise.
15278 (vst1_u64_x2): Likewise.
15279 (vst1_f64_x2): Likewise.
15280 (vst1_s8_x2): Likewise.
15281 (vst1_p8_x2): Likewise.
15282 (vst1_s16_x2): Likewise.
15283 (vst1_p16_x2): Likewise.
15284 (vst1_s32_x2): Likewise.
15285 (vst1_u8_x2): Likewise.
15286 (vst1_u16_x2): Likewise.
15287 (vst1_u32_x2): Likewise.
15288 (vst1_f16_x2): Likewise.
15289 (vst1_f32_x2): Likewise.
15290 (vst1_p64_x2): Likewise.
15291 (vst1q_s8_x2): Likewise.
15292 (vst1q_p8_x2): Likewise.
15293 (vst1q_s16_x2): Likewise.
15294 (vst1q_p16_x2): Likewise.
15295 (vst1q_s32_x2): Likewise.
15296 (vst1q_s64_x2): Likewise.
15297 (vst1q_u8_x2): Likewise.
15298 (vst1q_u16_x2): Likewise.
15299 (vst1q_u32_x2): Likewise.
15300 (vst1q_u64_x2): Likewise.
15301 (vst1q_f16_x2): Likewise.
15302 (vst1q_f32_x2): Likewise.
15303 (vst1q_f64_x2): Likewise.
15304 (vst1q_p64_x2): Likewise.
15305 (vst1_s64_x3): Likewise.
15306 (vst1_u64_x3): Likewise.
15307 (vst1_f64_x3): Likewise.
15308 (vst1_s8_x3): Likewise.
15309 (vst1_p8_x3): Likewise.
15310 (vst1_s16_x3): Likewise.
15311 (vst1_p16_x3): Likewise.
15312 (vst1_s32_x3): Likewise.
15313 (vst1_u8_x3): Likewise.
15314 (vst1_u16_x3): Likewise.
15315 (vst1_u32_x3): Likewise.
15316 (vst1_f16_x3): Likewise.
15317 (vst1_f32_x3): Likewise.
15318 (vst1_p64_x3): Likewise.
15319 (vst1q_s8_x3): Likewise.
15320 (vst1q_p8_x3): Likewise.
15321 (vst1q_s16_x3): Likewise.
15322 (vst1q_p16_x3): Likewise.
15323 (vst1q_s32_x3): Likewise.
15324 (vst1q_s64_x3): Likewise.
15325 (vst1q_u8_x3): Likewise.
15326 (vst1q_u16_x3): Likewise.
15327 (vst1q_u32_x3): Likewise.
15328 (vst1q_u64_x3): Likewise.
15329 (vst1q_f16_x3): Likewise.
15330 (vst1q_f32_x3): Likewise.
15331 (vst1q_f64_x3): Likewise.
15332 (vst1q_p64_x3): Likewise.
15333
15334 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
15335
15336 * config/msp430/msp430.c (msp430_output_labelref): Prepend
15337 user_label_prefix to name.
15338
15339 * tree-core.h: Update comment about the format of NAME string
15340 passed to handler in attribute_spec.
15341
15342 * config/msp430/msp430.md: Remove erroneous subreg expression from
15343 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
15344 zero_extend{q,h}isi2.
15345
15346 2018-05-30 Borislav Petkov <bp@suse.de>
15347
15348 * doc/extend.texi: Document some architecture specific
15349 constraints and sort entries.
15350
15351 2018-05-30 Martin Sebor <msebor@redhat.com>
15352
15353 PR middle-end/85369
15354 * builtins.c (expand_builtin_stpcpy_1): New function.
15355 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
15356 only if the former succeeds.
15357
15358 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15359
15360 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
15361 in saphira.
15362
15363 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15364
15365 * doc/invoke.texi (-flinker-output): Document
15366
15367 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15368
15369 * passes.c (ipa_write_summaries): Only modify statements if body
15370 is in memory.
15371 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
15372 incrementally linking.
15373 (ipa_passes): Likewise.
15374 * lto-cgraph.c (lto_output_node): When incrementally linking do not
15375 pass down resolution info.
15376 * common.opt (flag_incremental_link): Update info.
15377 * gcc.c (plugin specs): Turn flinker-output=* to
15378 -plugin-opt=-linker-output-known
15379 * toplev.c (compile_file): Also cut compilation when doing incremental
15380 link.
15381 * flag-types. (enum lto_partition_model): Add
15382 LTO_LINKER_OUTPUT_NOLTOREL.
15383 (invoke.texi): Add -flinker-output docs.
15384 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
15385 link same way as WPA; do not stream in dead initializers.
15386
15387 * dwarf2out.c (dwarf2out_die_ref_for_decl,
15388 darf2out_register_external_decl): Support incremental link.
15389
15390 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15391
15392 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
15393
15394 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15395
15396 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
15397 it down to simple_object_copy_lto_debug_sections.
15398 (run_gcc): Determine incremental LTO link time and configure
15399 lto1 into non-wpa mode, disable renaming of debug sections.
15400
15401 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
15402
15403 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
15404 descriptions of various incorrectly documented functions.
15405
15406 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
15407
15408 Revert:
15409 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15410 address check not strict.
15411
15412 2018-05-30 Richard Biener <rguenther@suse.de>
15413
15414 PR tree-optimization/85964
15415 * tracer.c (better_p): Drop initialized count check, we only
15416 call the function with initialized counts now.
15417 (find_best_successor): Do find a best edge if one
15418 has uninitialized count.
15419 (find_best_predecessor): Likewise. Do BB frequency check only
15420 if count is initialized.
15421
15422 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
15423
15424 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
15425 (aarch64_ldrstr_offset_compare): New.
15426 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
15427 load/store orderings.
15428 (aarch64_gen_adjusted_ldpstp): Likewise.
15429
15430 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
15431
15432 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15433 Check for subset of GENERAL_REGS and FP_REGS.
15434 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
15435 r=w alternative.
15436
15437 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
15438
15439 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
15440 and wi::to_poly_offset. Add the current offset and then check
15441 whether the sum fits, rather than using an unchecked addition of
15442 a checked term. Check for a shwi rather than a uhwi.
15443 * expr.c (get_bit_range): Use tree_to_poly_uint64.
15444 (store_constructor): Use poly_int_tree_p.
15445 (expand_expr_real_1): Likewise.
15446 * function.c (assign_temp): Likewise.
15447 * fold-const.c (const_binop): Use poly_int_tree_p and
15448 wi::to_poly_offset.
15449 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
15450 division.
15451 * ipa-icf-gimple.c (func_checker::compare_operand): Use
15452 to_poly_offset for MEM offsets.
15453 * ipa-icf.c (sem_variable::equals): Likewise.
15454 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
15455 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
15456 wi::to_poly_offset for BIT_FIELD_REF offsets.
15457 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
15458 wi::to_poly_offset.
15459 * var-tracking.c (emit_note_insn_var_location): Use
15460 tree_to_poly_uint64.
15461
15462 2018-05-29 Jim Wilson <jimw@sifive.com>
15463
15464 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
15465
15466 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
15467
15468 PR target/85950
15469 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
15470 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
15471 sequence.
15472 (sse4_1_round<mode>2): Use nonimmediate_operand
15473 for operand 1 predicate.
15474
15475 2018-05-29 Martin Sebor <msebor@redhat.com>
15476 Richard Biener <rguenther@suse.de>
15477
15478 PR testsuite/85888
15479 * calls.c (get_size_range): Call determine_value_range instead
15480 of get_value_range..
15481 * tree-vrp.h (determine_value_range): Declared new function.
15482 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
15483
15484 2018-05-29 Richard Biener <rguenther@suse.de>
15485
15486 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
15487 sure to use non-pattern stmts for get_earlier_stmt arguments.
15488 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
15489 called on pattern stmts.
15490 (get_later_stmt): Likewise.
15491
15492 2018-05-29 Martin Liska <mliska@suse.cz>
15493
15494 PR gcov-profile/85759
15495 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
15496 env variables.
15497
15498 2018-05-29 Jakub Jelinek <jakub@redhat.com>
15499
15500 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
15501 VEC_UNPACK_*_EXPR.
15502 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
15503 VEC_PACK_*_EXPR.
15504
15505 PR target/85918
15506 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15507 VEC_PACK_FLOAT_EXPR): New tree codes.
15508 * tree-pretty-print.c (op_code_prio): Handle
15509 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15510 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15511 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15512 * tree-inline.c (estimate_operator_cost): Likewise.
15513 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
15514 * fold-const.c (const_binop): Likewise.
15515 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
15516 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15517 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
15518 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
15519 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15520 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15521 * expr.c (expand_expr_real_2): Likewise.
15522 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
15523 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
15524 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
15525 optabs.
15526 * optabs.c (expand_widen_pattern_expr): For
15527 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
15528 sign from result type rather than operand's type.
15529 (expand_binop_directly): For vec_packu_float_optab and
15530 vec_packs_float_optab allow result type to be different from operand's
15531 type.
15532 * optabs-tree.c (optab_for_tree_code): Handle
15533 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15534 VEC_PACK_FLOAT_EXPR. Formatting fixes.
15535 * tree-vect-generic.c (expand_vector_operations_1): Handle
15536 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15537 VEC_PACK_FLOAT_EXPR.
15538 * tree-vect-stmts.c (supportable_widening_operation): Handle
15539 FIX_TRUNC_EXPR.
15540 (supportable_narrowing_operation): Handle FLOAT_EXPR.
15541 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
15542 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
15543 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
15544 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
15545 mode attributes.
15546 (vec_pack<floatprefix>_float_<mode>): New expander.
15547 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
15548 attributes.
15549 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
15550 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
15551 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
15552 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
15553 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
15554 Document.
15555 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
15556 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
15557 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15558 VEC_PACK_FLOAT_EXPR): Document.
15559
15560 2018-05-29 Richard Biener <rguenther@suse.de>
15561
15562 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
15563 member.
15564 (stmt_vec_info_vec): Make pointer.
15565 (init_stmt_vec_info_vec): Remove.
15566 (free_stmt_vec_info_vec): Likewise.
15567 (set_stmt_vec_info_vec): New function.
15568 (free_stmt_vec_infos): Likewise.
15569 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
15570 (set_vinfo_for_stmt): Likewise.
15571 (get_earlier_stmt): Likewise.
15572 (get_later_stmt): Likewise.
15573 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
15574 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
15575 (vec_info::~vec_info): Free stmt_vec_infos.
15576 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
15577 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
15578 (pass_slp_vectorize::execute): Likewise.
15579 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
15580 (free_stmt_vec_info_vec): Likewise.
15581 (set_stmt_vec_info_vec): New function.
15582 (free_stmt_vec_infos): Likewise.
15583 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
15584 the global stmt_vec_info_vec.
15585 * tree-parloops.c (gather_scalar_reductions): Use
15586 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
15587 vector.
15588
15589 2018-05-29 Richard Biener <rguenther@suse.de>
15590
15591 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
15592
15593 2018-05-29 Martin Liska <mliska@suse.cz>
15594 David Malcolm <dmalcolm@redhat.com>
15595
15596 * vec.c (test_reverse): New.
15597 (vec_c_tests): Add new test.
15598 * vec.h (vl_ptr>::reverse): New function.
15599
15600 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
15601
15602 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
15603
15604 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
15605 and later.
15606
15607 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
15608
15609 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
15610
15611 2018-05-28 Richard Biener <rguenther@suse.de>
15612
15613 PR tree-optimization/85933
15614 * tree-vect-data-refs.c (vect_record_base_alignments): Only
15615 look at stmts marked as vectorizable.
15616
15617 2018-05-28 Richard Biener <rguenther@suse.de>
15618
15619 PR tree-optimization/85934
15620 * tree-vect-generic.c (expand_vector_operations_1): Hoist
15621 vector boolean check before scalar optimization.
15622
15623 2018-05-28 Jakub Jelinek <jakub@redhat.com>
15624
15625 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
15626 for armv5te.
15627
15628 2018-05-28 Mark Wielaard <mark@klomp.org>
15629
15630 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
15631 if it is an expression containing a minus sign.
15632
15633 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
15634
15635 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
15636
15637 2018-05-27 Paul Koning <ni1d@arrl.net>
15638
15639 * config/pdp11/pdp11.md (truncsihi2): Remove.
15640
15641 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
15642 Chung-Ju Wu <jasonwucj@gmail.com>
15643
15644 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
15645 implementation.
15646 (unaligned_store_dw): Ditto.
15647 * config/nds32/nds32-memory-manipulation.c
15648 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
15649 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
15650 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
15651 (emit_setmem_word_loop): Rename to ...
15652 (emit_setmem_doubleword_loop): ... this.
15653 (nds32_gen_dup_4_byte_to_word_value): New function.
15654 (nds32_gen_dup_8_byte_to_double_word_value): New function.
15655 (nds32_expand_setmem_loop): Refine implementation.
15656 (nds32_expand_setmem_loop_v3m): Ditto.
15657 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
15658 pattern.
15659
15660 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15661
15662 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
15663
15664 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15665
15666 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
15667 (nds32_init_machine_status): Initialize machine->attr_naked_p and
15668 machine->attr_no_prologue_p.
15669 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
15670 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
15671 (nds32_expand_epilogue): Consider attr_naked_p.
15672 (nds32_expand_epilogue_v3pop): Likewise.
15673 (nds32_can_use_return_insn): Likewise.
15674 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
15675 attr_no_prologue_p fields.
15676 * config/nds32/nds32.opt (mret-in-naked-func): New option.
15677
15678 2018-05-27 Jakub Jelinek <jakub@redhat.com>
15679
15680 PR target/85918
15681 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
15682 attributes.
15683 * config/i386/sse.md
15684 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
15685 Rename to ...
15686 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
15687 ... this.
15688 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
15689 Rename to ...
15690 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
15691 ... this.
15692 (*<floatsuffix>floatv2div2sf2): Rename to ...
15693 (*float<floatunssuffix>v2div2sf2): ... this.
15694 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
15695 (float<floatunssuffix>v2div2sf2_mask): ... this.
15696 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
15697 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
15698 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
15699 to ...
15700 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
15701 ... this.
15702 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15703 Rename to ...
15704 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15705 ... this.
15706 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15707 Rename to ...
15708 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15709 ... this.
15710 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
15711 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
15712 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
15713 gen_ufix_truncv8dfv8si2.
15714 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
15715 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
15716 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
15717 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
15718 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
15719 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
15720 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
15721 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
15722
15723 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
15724
15725 PR target/85900
15726 PR target/85345
15727 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
15728
15729 2018-05-25 Jim Wilson <jimw@sifive.com>
15730
15731 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
15732 * config/riscv/riscv.c (struct machine_function): Add
15733 interrupt_handler_p and attribute_checked_p fields.
15734 (riscv_attribute_table): Add interrupt.
15735 (riscv_interrupt_type_p): New.
15736 (riscv_save_reg_p): Save extra regs for interrupt handler.
15737 (riscv_use_save_libcall): Return false for interrupt handler.
15738 (riscv_first_stack_step): Add forward declaration.
15739 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
15740 for interrupt handler with large frame. Use it for saved reg list.
15741 (riscv_expand_prologue): Move flag_stack_usage_info support to
15742 eliminate duplication.
15743 (riscv_expand_epilogue): Generate mret for interrupt handler.
15744 (riscv_epilogue_uses): New.
15745 (riscv_can_use_return_insn): Return false for interrupt handler.
15746 (riscv_function_ok_for_sibcall): Likewise.
15747 (riscv_set_current_function): Add interrupt handler support.
15748 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
15749 * config/riscv/riscv.md (UNSPECV_MRET): New.
15750 (GP_REGNUM): New.
15751 (riscv_frflags, riscv_fsflags): Use tab after opcode.
15752 (riscv_mret): New.
15753 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
15754
15755 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
15756
15757 PR tree-optimization/85712
15758 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
15759 this candidate has already been replaced in-situ by a copy.
15760
15761 2018-05-25 Jason Merrill <jason@redhat.com>
15762
15763 PR c++/80485 - inline function non-zero address.
15764 * symtab.c (nonzero_address): Check DECL_COMDAT.
15765
15766 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
15767
15768 PR target/83628
15769 * config/alpha/alpha.md (ashlsi3): New insn pattern.
15770 (*ashlsi_se): Rename from *ashldi_se. Define as sign
15771 extension of SImode operation. Use const123_operand predicate.
15772 (*saddsi_1): Remove.
15773 (*saddl_se_1): Ditto.
15774 (*ssubsi_1): Ditto.
15775 (*ssubl_se_1): Ditto.
15776 * config/alpha/predicates.md (const123_operand): New predicate.
15777 * config/alpha/constraints.md (P): Use IN_RANGE.
15778
15779 2018-05-25 Richard Biener <rguenther@suse.de>
15780
15781 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
15782 defaulted to true.
15783 (ref_maybe_used_by_stmt_p): Likewise.
15784 (stmt_may_clobber_ref_p): Likewise.
15785 (stmt_may_clobber_ref_p_1): Likewise.
15786 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
15787 and pass it along.
15788 (ref_maybe_used_by_stmt_p): Likewise.
15789 (stmt_may_clobber_ref_p): Likewise.
15790 (stmt_may_clobber_ref_p_1): Likewise.
15791 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
15792 the alias oracle to disambiguate DRs with stmts DR analysis
15793 couldn't handle.
15794 (vect_analyze_data_refs): Do not give up on not analyzable
15795 DRs for BB vectorization. Remove code truncating the dataref
15796 vector.
15797
15798 2018-05-25 Jakub Jelinek <jakub@redhat.com>
15799
15800 PR target/85832
15801 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
15802 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
15803 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
15804
15805 2018-05-25 Richard Biener <rguenther@suse.de>
15806
15807 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
15808 function, combining stmt data ref gathering and fatal analysis
15809 parts.
15810 (vect_analyze_data_refs): Remove now redudnant code and simplify.
15811 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
15812 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
15813 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
15814 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
15815
15816 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15817
15818 PR tree-optimization/85720
15819 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
15820 SCC if all partitions are builtins.
15821 (version_loop_by_alias_check): New parameter. Generate cancelable
15822 runtime alias check if all partitions are builtins.
15823 (distribute_loop): Update call to above function.
15824
15825 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15826
15827 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
15828 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
15829 (parm_default_def_partition_arg): Ditto.
15830 (set_parm_default_def_partition): Ditto.
15831 (get_parm_default_def_partitions): Ditto and make it static.
15832 (get_undefined_value_partitions): Ditto and make it static.
15833 (remove_ssa_form): Refactor call to init_var_map here.
15834 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
15835 computation for loop region.
15836 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
15837 (register_default_def): Delete.
15838 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
15839 (parm_default_def_partition_arg): Ditto.
15840 (set_parm_default_def_partition): Ditto.
15841 (get_parm_default_def_partitions): Ditto and make it static.
15842 (get_undefined_value_partitions): Ditto and make it static.
15843 (coalesce_with_default, coalesce_with_default): Update comment.
15844 (create_coalesce_list_for_region): New func factored out from
15845 create_outofssa_var_map.
15846 (populate_coalesce_list_for_outofssa): New func factored out from
15847 create_outofssa_var_map and coalesce_ssa_name.
15848 (create_outofssa_var_map): Delete.
15849 (coalesce_ssa_name): Refactor to support live range computation.
15850 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
15851 (get_parm_default_def_partitions): Delete.
15852 (get_undefined_value_partitions): Ditto.
15853 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
15854 computation for loop region.
15855 (new_tree_live_info, loe_visit_block): Ditto.
15856 (live_worklist, set_var_live_on_entry): Ditto.
15857 (calculate_live_on_exit, verify_live_on_entry): Ditto.
15858 * tree-ssa-live.h (struct _var_map): New fields.
15859 (init_var_map): Change decl.
15860 (region_contains_p): New.
15861
15862 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15863
15864 * tree-ssa-live.h (live_merge_and_clear): Delete.
15865
15866 2018-05-25 Richard Biener <rguenther@suse.de>
15867
15868 PR c++/85912
15869 * tree-dump.c (dequeue_and_dump): Remove access to removed
15870 operand 2 of a SWITCH_EXPR.
15871
15872 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15873
15874 * doc/sourcebuild.texi (vect_double_cond_arith): Include
15875 multiplication and division.
15876 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
15877 (cond_udiv@var{m}, cond_umod@var{m}): Document.
15878 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
15879 (cond_udiv_optab, cond_umod_optab): New optabs.
15880 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
15881 (IFN_COND_RDIV): New internal functions.
15882 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
15883 TRUNC_MOD_EXPR and RDIV_EXPR.
15884 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
15885 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
15886 New unspecs.
15887 (SVE_INT_BINARY): Include mult.
15888 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
15889 (optab, sve_int_op): Handle mult.
15890 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
15891 UNSPEC_COND_DIV.
15892 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
15893 for SVE_INT_BINARY_SD.
15894
15895 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15896
15897 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
15898 (optab, sve_int_op): Handle div and udiv.
15899 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
15900 for SVE_INT_BINARY_SD.
15901 (*<optab><mode>3): New insn for the same.
15902
15903 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15904
15905 * tree-vect-patterns.c: Include predict.h.
15906 (vect_recog_divmod_pattern): Restrict check for division support
15907 to when optimizing for size.
15908
15909 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15910
15911 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
15912 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
15913 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
15914 (gimple_match_op::set_op): Likewise.
15915 (gimple_resimplify4): Declare.
15916 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
15917 (expr::gen_transform): Likewise.
15918 (decision_tree::gen): Generate a simplification routine for 4 operands.
15919 * gimple-match-head.c (gimple_simplify): Add an overload for
15920 4 operands. In the top-level function, handle up to 4 call
15921 arguments and call gimple_resimplify4.
15922 (gimple_resimplify4): New function.
15923 (build_call_internal): Pass a fourth operand.
15924 (maybe_push_to_seq): Likewise.
15925 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
15926 Fold VEC_COND_EXPRs of an operation and a default value into
15927 an IFN_COND_* function if possible.
15928 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
15929 New unspecs.
15930 (SVE_COND_FP_BINARY): Include them.
15931 (optab, sve_fp_op): Handle them.
15932 (SVE_INT_BINARY_REV): New code iterator.
15933 (SVE_COND_FP_BINARY_REV): New int iterator.
15934 (commutative): New int attribute.
15935 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
15936 Declare.
15937 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
15938 function.
15939 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
15940 (*cond_<optab><mode>): New patterns for reversed operands.
15941
15942 2018-05-25 Richard Biener <rguenther@suse.de>
15943
15944 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
15945 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
15946 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
15947 (STMT_VINFO_GROUPED_ACCESS): Adjust.
15948 * tree-vect-data-refs.c (everywhere): Adjust users.
15949 * tree-vect-loop.c (everywhere): Likewise.
15950 * tree-vect-slp.c (everywhere): Likewise.
15951 * tree-vect-stmts.c (everywhere): Likewise.
15952 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
15953
15954 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
15955
15956 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
15957 Rename to...
15958 (gcc_cv_as_section_exclude): ... this.
15959 Try Solaris as #exclude syntax.
15960 * configure: Regenerate.
15961 * config.in: Regenerate.
15962 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
15963 SECTION_EXCLUDE.
15964 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
15965 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
15966
15967 * varasm.c (default_elf_asm_named_section): Don't check if
15968 HAVE_GAS_SECTION_EXCLUDE is defined.
15969
15970 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15971
15972 * doc/md.texi: Update the documentation of the cond_* optabs
15973 to mention the new final operand. Fix GET_MODE_NUNITS call.
15974 Describe the scalar case too.
15975 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
15976 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
15977 instead of 2.
15978 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
15979 (get_conditional_internal_fn): Update comment.
15980 * tree-vect-loop.c (vectorizable_reduction): Pass the original
15981 accumulator value as a final argument to conditional functions.
15982 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
15983 a define_expand and add an "else" operand. Assert for now that
15984 the else operand is equal to operand 2. Use SVE_INT_BINARY and
15985 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
15986 (*cond_<optab><mode>): New patterns.
15987 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
15988 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
15989 (UNSPEC_COND_EOR): Delete.
15990 (optab): Remove associated mappings.
15991 (SVE_INT_BINARY): New code iterator.
15992 (sve_int_op): Remove int attribute and add "minus" to the code
15993 attribute.
15994 (SVE_COND_INT_OP): Delete.
15995 (SVE_COND_FP_OP): Rename to...
15996 (SVE_COND_FP_BINARY): ...this.
15997
15998 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15999
16000 * optabs.c (can_reuse_operands_p): New function.
16001 (maybe_legitimize_operands): Try to reuse the results for
16002 earlier operands.
16003
16004 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16005
16006 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
16007 Add {q} suffix to insn mnemonic.
16008
16009 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
16010
16011 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
16012 (msp430_warn_func_return): New.
16013
16014 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
16015
16016 * fold-const.c (tree_nonzero_bits): New function.
16017 * fold-const.h (tree_nonzero_bits): Likewise.
16018 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
16019 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
16020
16021 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
16022
16023 PR target/85900
16024 PR target/85345
16025 * varasm.c (assemble_alias): Check ifunc_resolver only on
16026 FUNCTION_DECL.
16027
16028 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16029
16030 PR target/85903
16031 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
16032 when memory input operand is handled.
16033
16034 2018-05-24 Luis Machado <luis.machado@linaro.org>
16035
16036 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
16037 global.
16038 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
16039
16040 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16041
16042 * match.pd: Delay FMA folds until after vectorization.
16043
16044 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
16045
16046 PR target/83009
16047 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
16048 address check not strict.
16049
16050 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16051
16052 * gimple-match.h (gimple_match_op): New class.
16053 (mprts_hook): Replace parameters with a gimple_match_op *.
16054 (maybe_build_generic_op): Likewise.
16055 (gimple_simplified_result_is_gimple_val): Replace parameters with
16056 a const gimple_match_op *.
16057 (gimple_simplify): Replace code_helper * and tree * parameters with
16058 a gimple_match_op * parameter.
16059 (gimple_resimplify1): Replace code_helper *, tree and tree *
16060 parameters with a gimple_match_op * parameter.
16061 (gimple_resimplify2): Likewise.
16062 (gimple_resimplify3): Likewise.
16063 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
16064 parameters with a gimple_match_op * parameter.
16065 * gimple-match-head.c (gimple_simplify): Change prototypes of
16066 auto-generated functions to take a gimple_match_op * instead of
16067 separate code_helper * and tree * parameters. Make the same
16068 change in the top-level overload and update calls to the
16069 gimple_resimplify routines. Update calls to the auto-generated
16070 functions and to maybe_push_res_to_seq in the publicly-facing
16071 operation-specific gimple_simplify overloads.
16072 (gimple_match_op::MAX_NUM_OPS): Define.
16073 (gimple_resimplify1): Replace rcode and ops with a single res_op
16074 parameter. Update call to gimple_simplify.
16075 (gimple_resimplify2): Likewise.
16076 (gimple_resimplify3): Likewise.
16077 (mprts_hook): Replace parameters with a gimple_match_op *.
16078 (maybe_build_generic_op): Likewise.
16079 (build_call_internal): Replace type, nargs and ops with
16080 a gimple_match_op *.
16081 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
16082 with a single gimple_match_op *. Update calls to mprts_hook,
16083 build_call_internal and gimple_simplified_result_is_gimple_val.
16084 Factor out code that is common to the tree_code and combined_fn cases.
16085 * genmatch.c (expr::gen_transform): Replace tem_code and
16086 tem_ops with a gimple_match_op called tem_op. Update calls
16087 to the gimple_resimplify functions and maybe_push_res_to_seq.
16088 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
16089 res_ops. Update call to the gimple_resimplify functions.
16090 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
16091 (decision_tree::gen): Make the functions take a gimple_match_op *
16092 called res_op instead of separate res_code and res_ops parameters.
16093 Update call accordingly.
16094 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
16095 and ops with a single res_op parameter. Update calls to
16096 maybe_build_generic_op and maybe_push_res_to_seq.
16097 (fold_stmt_1): Update calls to gimple_simplify and
16098 replace_stmt_with_simplification.
16099 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
16100 and gimple_simplified_result_is_gimple_val.
16101 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
16102 gimple_simplify.
16103 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
16104 with a gimple_match_op *.
16105 (vn_nary_build_or_lookup): Likewise. Update call to
16106 vn_nary_build_or_lookup_1.
16107 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
16108 gimple_match_op *. Update calls to the gimple_resimplify routines
16109 and to gimple_simplified_result_is_gimple_val.
16110 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
16111 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
16112 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
16113 (visit_nary_op): Likewise.
16114 (visit_reference_op_load): Likewise.
16115
16116 2018-05-23 Luis Machado <luis.machado@linaro.org>
16117
16118 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
16119 modifier for printing the step amount.
16120
16121 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
16122
16123 PR target/78849
16124 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
16125 types.
16126
16127 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
16128
16129 * doc/sourcebuild.texi (Endianness): New subsubsection.
16130
16131 2018-05-23 Luis Machado <luis.machado@linaro.org>
16132
16133 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16134 <prefetch_dynamic_strides>: New const bool field.
16135 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16136 prefetch_dynamic_strides.
16137 (exynosm1_prefetch_tune): Likewise.
16138 (thunderxt88_prefetch_tune): Likewise.
16139 (thunderx_prefetch_tune): Likewise.
16140 (thunderx2t99_prefetch_tune): Likewise.
16141 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
16142 false.
16143 (aarch64_override_options_internal): Update to set
16144 PARAM_PREFETCH_DYNAMIC_STRIDES.
16145 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
16146 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
16147 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
16148 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
16149 prefetch-dynamic-strides setting.
16150
16151 2018-05-23 Luis Machado <luis.machado@linaro.org>
16152
16153 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16154 <minimum_stride>: New const int field.
16155 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16156 minimum_stride field defaulting to -1.
16157 (exynosm1_prefetch_tune): Likewise.
16158 (thunderxt88_prefetch_tune): Likewise.
16159 (thunderx_prefetch_tune): Likewise.
16160 (thunderx2t99_prefetch_tune): Likewise.
16161 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
16162 <default_opt_level>: Set to 3.
16163 (aarch64_override_options_internal): Update to set
16164 PARAM_PREFETCH_MINIMUM_STRIDE.
16165 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
16166 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
16167 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
16168 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
16169 stride is constant and is below the minimum stride threshold.
16170
16171 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16172
16173 * config/arm/arm-cpus.in (mode26): Delete.
16174 (armv4): Delete mode26 reference.
16175 * config/arm/arm.c (arm_configure_build_target): Delete use of
16176 isa_bit_mode26.
16177
16178 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16179
16180 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
16181 New insn pattern.
16182 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
16183 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
16184 for non-SSE modes.
16185 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
16186 (floatunsdidf2): Ditto.
16187
16188 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16189
16190 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
16191 (fixuns_trunc<mode>si2_avx512f): Ditto.
16192 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
16193 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
16194 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
16195
16196 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16197
16198 PR rtl-optimization/79985
16199 * df-scan.c (df_insn_refs_collect): Remove special case for
16200 global registers and asm statements.
16201
16202 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16203
16204 * extend.texi (Global Register Variables): Rewrite the bullet list.
16205 Note that the register is available for allocation. Note that access
16206 via inline asm must use constraints. Add note about async-signal
16207 handlers. Remove paragraph about automagic register selection.
16208
16209 2018-05-23 Richard Biener <rguenther@suse.de>
16210
16211 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
16212 of fixed offset from memset VN.
16213
16214 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
16215
16216 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
16217 first_interp field.
16218 (alloc_cand_and_find_basis): Initialize first_interp field.
16219 (slsr_process_mul): Modify first_interp field.
16220 (slsr_process_add): Likewise.
16221 (slsr_process_cast): Modify first_interp field for each new
16222 interpretation.
16223 (slsr_process_copy): Likewise.
16224 (dump_candidate): Dump first_interp field.
16225 (replace_mult_candidate): Process all interpretations, not just
16226 subsequent ones.
16227 (replace_rhs_if_not_dup): Likewise.
16228 (replace_one_candidate): Likewise.
16229
16230 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
16231
16232 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
16233 Add new boolean.
16234 (aarch64_needs_frame_chain): New function.
16235 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
16236
16237 2018-05-23 Sudakshina Das <sudi.das@arm.com>
16238
16239 PR target/84882
16240 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
16241 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
16242 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
16243 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
16244 as true for strict-align.
16245 (aarch64_can_inline_p): Perform checks even when callee has no
16246 attributes to check for strict alignment.
16247 * doc/extend.texi (AArch64 Function Attributes): Document
16248 no-strict-align.
16249 * doc/invoke.texi: (AArch64 Options): Likewise.
16250
16251 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
16252
16253 PR tree-optimization/85853
16254 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
16255 the handling of the root of the node to...
16256 (vect_slp_analyze_node_operations_1): ...this new function,
16257 and run the whole thing with the child nodes' def types
16258 set according to their SLP node's def type.
16259
16260 2018-05-23 Richard Biener <rguenther@suse.de>
16261
16262 PR middle-end/85874
16263 * tree-data-ref.c (create_runtime_alias_checks): Defer
16264 and ignore overflow warnings.
16265
16266 2018-05-23 Yury Gribov <tetra2005@gmail.com>
16267
16268 PR tree-optimization/85822
16269 * tree-vrp.c (is_masked_range_test): Fix handling of negative
16270 constants.
16271
16272 2018-05-23 Richard Biener <rguenther@suse.de>
16273
16274 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
16275 memset constants via native_interpret_expr.
16276
16277 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
16278
16279 PR target/85345
16280 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
16281 attribute.
16282 (cgraph_node::create_alias): Likewise.
16283 (cgraph_node::get_availability): Check ifunc_resolver instead
16284 of looking up ifunc attribute.
16285 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
16286 * varasm.c (do_assemble_alias): Likewise.
16287 (assemble_alias): Likewise.
16288 (default_binds_local_p_3): Likewise.
16289 * cgraph.h (cgraph_node): Add ifunc_resolver.
16290 (cgraph_node::only_called_directly_or_aliased_p): Return false
16291 for IFUNC resolver.
16292 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
16293 attribute.
16294 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
16295 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
16296 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
16297 instead of looking up ifunc attribute.
16298
16299 2018-05-22 Luis Machado <luis.machado@linaro.org>
16300
16301 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
16302
16303 2018-05-22 Martin Sebor <msebor@redhat.com>
16304
16305 PR middle-end/85359
16306 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
16307 only when expasion succeeds.
16308 (expand_builtin_strcmp): Same.
16309 (expand_builtin_strncmp): Same.
16310
16311 2018-05-22 Martin Sebor <msebor@redhat.com>
16312
16313 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
16314
16315 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16316 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16317
16318 * config/aarch64/aarch64-ldpstp.md: Replace uses of
16319 aarch64_mem_pair_operand with memory_operand and delete operand swapping
16320 code.
16321 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16322 Add check for legitimate_address.
16323 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
16324 (aarch64_swap_ldrstr_operands): New.
16325 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
16326 Define prototype.
16327
16328 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16329 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16330
16331 * config/aarch64/aarch64.md: New patterns to generate stp
16332 and ldp.
16333 (store_pair_sw, store_pair_dw): New patterns to generate stp for
16334 single words and double words.
16335 (load_pair_sw, load_pair_dw): Likewise.
16336 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
16337 Delete.
16338 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
16339 Delete.
16340 * config/aarch64/aarch64-ldpstp.md: Modify peephole
16341 for different mode ldpstp and add peephole for merged zero stores.
16342 Likewise for loads.
16343 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16344 Add size check.
16345 (aarch64_gen_store_pair): Rename calls to match new patterns.
16346 (aarch64_gen_load_pair): Rename calls to match new patterns.
16347 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
16348 (load_pair<DREG:mode><DREG2:mode>): ... This.
16349 (store_pair<mode>): Rename to...
16350 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
16351 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
16352 New mode iterators.
16353 (V_INT_EQUIV): Handle SImode.
16354 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
16355 New predicate.
16356
16357 2018-05-22 Martin Sebor <msebor@redhat.com>
16358
16359 PR c/85623
16360 * calls.c (maybe_warn_nonstring_arg): Use string length to set
16361 or ajust the presumed bound on an operation to avoid unnecessary
16362 warnings.
16363
16364 2018-05-22 Martin Sebor <msebor@redhat.com>
16365
16366 PR tree-optimization/85826
16367 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
16368 assuming that a DECL necesarily has a constant size.
16369
16370 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
16371
16372 PR middle-end/85862
16373 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
16374
16375 2018-05-22 Richard Biener <rguenther@suse.de>
16376
16377 PR tree-optimization/85834
16378 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
16379 non-constant and non-zero memset arguments.
16380
16381 2018-05-22 Martin Liska <mliska@suse.cz>
16382
16383 PR ipa/85607
16384 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
16385
16386 2018-05-22 Richard Biener <rguenther@suse.de>
16387
16388 PR tree-optimization/85863
16389 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
16390 comparisons when vectype is specified.
16391 (vectorizable_condition): Do not specify vectype for
16392 vect_is_simple_cond when SLP vectorizing.
16393
16394 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
16395
16396 PR target/85657
16397 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
16398 define __ibm128 as long double.
16399 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
16400 as a distinct type when IEEE 128-bit support is enabled.
16401 (init_float128_ieee): Fix up conversions between IFmode and IEEE
16402 128-bit types to use the correct functions.
16403 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
16404 convert between 128-bit floating point types that have different
16405 modes but the same representation, instead of using gen_lowpart to
16406 makean alias.
16407 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
16408 KFmode.
16409 (IFKF_reg): New attributes to give the register constraints for
16410 IFmode and KFmode.
16411 (extend<mode>tf2_internal): New insns to mark an explicit
16412 conversion between 128-bit floating point types that have a
16413 different mode but share the same representation.
16414
16415 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
16416
16417 PR tree-optimization/85814
16418 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
16419 a null return from get_strinfo when unsharing the next
16420 strinfo in the chain.
16421
16422 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
16423
16424 PR gcc/84923
16425 * varasm.c (weak_finish): Clean up weak_decls.
16426
16427 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16428
16429 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
16430 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
16431 UNSPEC_UADALP values.
16432 * config/aarch64/iterators.md (ABAL): New int iterator.
16433 (ABDL2): Likewise.
16434 (ADALP): Likewise.
16435 (sur): Add mappings for the above.
16436 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
16437 New define_insn.
16438 (aarch64_<sur>abal<mode>_4): Likewise.
16439 (aarch64_<sur>adalp<mode>_3): Likewise.
16440 (<sur>sadv16qi): New define_expand.
16441
16442 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
16443
16444 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
16445 (*movdf_internal): Ditto.
16446 (*rcpsf2_sse): Ditto.
16447 (*rsqrtsf2_sse): Ditto.
16448 (*sqrt<mode>2_sse): Ditto.
16449
16450 2018-05-21 Tamar Christina <tamar.christina@arm.com>
16451
16452 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
16453 eor3q<mode>4.
16454 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
16455 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
16456 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
16457 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
16458 vbcaxq_s64): New.
16459 * config/aarch64/arm_neon.h: Likewise.
16460 * config/aarch64/iterators.md (VQ_I): New.
16461
16462 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
16463
16464 * config.gcc: Add arc/t-multilib-linux to tmake_file for
16465 arc*-*-linux*.
16466 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
16467 MULTILIB_DIRNAMES
16468
16469 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16470
16471 * config/nds32/constraints.md (S): New constraint.
16472 * config/nds32/nds32.md (call_internal): Use constraint S.
16473 (call_value_internal): Likewise.
16474 (sibcall_internal): Likewise.
16475 (sibcall_value_internal): Likewise.
16476
16477 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16478 Chung-Ju Wu <jasonwucj@gmail.com>
16479
16480 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
16481 into consideration.
16482
16483 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16484 Chung-Ju Wu <jasonwucj@gmail.com>
16485
16486 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
16487 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
16488 (nds32_rtx_costs_impl): Simplify.
16489 (nds32_address_cost_impl): Simplify.
16490 (nds32_init_rtx_costs): New function.
16491 (nds32_rtx_costs_speed_prefer): Likewise.
16492 (nds32_rtx_costs_size_prefer): Likewise.
16493 (nds32_address_cost_speed_prefer): Likewise.
16494 (nds32_address_cost_speed_fwprop): Likewise.
16495 (nds32_address_cost_size_prefer): Likewise.
16496 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
16497 * config/nds32/nds32.c (nds32_option_override): Use
16498 nds32_init_rtx_costs function.
16499
16500 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16501
16502 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
16503 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
16504 (TARGET_PIPELINE_N8): Likewise.
16505 (TARGET_PIPELINE_N10): Likewise.
16506 (TARGET_PIPELINE_N13): Likewise.
16507 (TARGET_PIPELINE_GRAYWOLF): Likewise.
16508
16509 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
16510
16511 * config/nds32/nds32-fpu.md: Update copyright year.
16512
16513 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16514
16515 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
16516
16517 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16518
16519 * config/nds32/nds32.c
16520 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
16521 * config/nds32/nds32.opt (minline-asm-r15): New option.
16522
16523 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16524
16525 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
16526 MASK_HW_ABS.
16527 * config/nds32/nds32.md (abssi2): New pattern.
16528
16529 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
16530
16531 * config/i386/i386.md (rex64namesuffix): New mode attribute.
16532 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
16533 Merge insn pattern from sse_cvtsi2ss<round_name> and
16534 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
16535 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
16536 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
16537 using SWI48 mode iterator.
16538 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
16539 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
16540 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
16541 pattern from sse_cvttss2si<round_saeonly_name>
16542 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
16543 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
16544 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
16545 using SWI48 mode iterator.
16546 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
16547 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
16548 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
16549 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
16550 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
16551 using SWI48 mode iterator.
16552 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
16553 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
16554 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
16555 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
16556 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
16557 SWI48 mode iterator.
16558 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
16559 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
16560 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
16561 pattern from sse_cvttsd2si<round_saeonly_name>
16562 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
16563
16564 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16565
16566 * config/nds32/nds32-md-auxiliary.c
16567 (nds32_valid_smw_lwm_base_p): Refine.
16568 (nds32_output_smw_single_word): Refine.
16569 (nds32_output_smw_double_word): New.
16570 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
16571
16572 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16573
16574 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
16575 (nds32_output_stack_pop): Refine.
16576 (nds32_expand_unaligned_load): Refine.
16577 (nds32_expand_unaligned_store): Refine.
16578
16579 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16580 Chung-Ju Wu <jasonwucj@gmail.com>
16581
16582 * config/nds32/constants.md: Add TP_REGNUM constant.
16583 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
16584 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
16585 UNSPEC_ADD32.
16586 * config/nds32/nds32-doubleword.md: Consider flag_pic.
16587 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
16588 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
16589 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
16590 and PIC code generation.
16591 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
16592 code generation.
16593 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
16594 optimization.
16595 * config/nds32/nds32.md: Support TLS and PIC.
16596 * config/nds32/nds32.c: Support TLS and PIC.
16597 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
16598 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
16599 predicate.
16600
16601 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16602
16603 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
16604 mode with E_ prefix.
16605
16606 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16607 Chung-Ju Wu <jasonwucj@gmail.com>
16608
16609 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
16610 * config/nds32/nds32-md-auxiliary.c
16611 (symbolic_reference_mentioned_p): New.
16612 (nds32_legitimize_ict_address): New.
16613 (nds32_expand_ict_move): New.
16614 (nds32_indirect_call_referenced_p): New.
16615 (nds32_symbol_binds_local_p): Delete.
16616 (nds32_long_call_p): Modify.
16617 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
16618 * config/nds32/nds32-protos.h
16619 (symbolic_reference_mentioned_p): Declare.
16620 (nds32_legitimize_ict_address): Declare.
16621 (nds32_expand_ict_move): Declare.
16622 (nds32_indirect_call_referenced_p): Declare.
16623 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
16624 (nds32_relax_group): Use nds32_ict_const_p as condition.
16625 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
16626 (nds32_asm_file_start): Output ict_model directive in asm code.
16627 (nds32_legitimate_address_p): Consider indirect call.
16628 (nds32_print_operand): Consider indirect call.
16629 (nds32_print_operand_address): Consider indirect call.
16630 (nds32_insert_attributes): Handle "indirect_call" attribute.
16631 (TARGET_LEGITIMATE_ADDRESS_P): Define.
16632 (TARGET_LEGITIMATE_CONSTANT_P): Define.
16633 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
16634 (TARGET_DELEGITIMIZE_ADDRESS): Define.
16635 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
16636 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
16637 (TARGET_ICT_MODEL_SMALL): Define.
16638 (TARGET_ICT_MODEL_LARGE): Define.
16639 * config/nds32/nds32.md (movsi): Consider ict model.
16640 (call, call_value): Consider ict model.
16641 (sibcall, sibcall_value): Consider ict model.
16642 * config/nds32/nds32.opt (mict-model): New option.
16643 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
16644 model.
16645
16646 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
16647 Monk Chiang <sh.chiang04@gmail.com>
16648 Jim Wilson <jimw@sifive.com>
16649
16650 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
16651 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
16652 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
16653 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
16654 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
16655 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
16656 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
16657 compute save_libcall_adjustment properly.
16658 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
16659 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
16660 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
16661 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
16662 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
16663 (ABI_SPEC): Handle mabi=ilp32e.
16664 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
16665 (RVE): Add RVE mask.
16666 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
16667 <-march>: Add rv32e as an example.
16668
16669 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
16670
16671 PR c++/82899
16672 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
16673 (intra_create_variable_infos): Handle C++ constructors.
16674
16675 2018-05-18 Martin Liska <mliska@suse.cz>
16676
16677 * passes.def: Remove a redundant pass.
16678
16679 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
16680
16681 PR bootstrap/85838
16682 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
16683
16684 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16685
16686 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
16687 (ARMv4): Update.
16688 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
16689 (ARMv6m): Update.
16690 (armv2, armv2a, armv3, armv3m): Delete architectures.
16691 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
16692 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
16693 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
16694 Delete cpus.
16695 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
16696 (*mulsidi3adddi): Likewise.
16697 (mulsidi3): Likewise.
16698 (*mulsidi3_nov6): Likewise.
16699 (umulsidi3): Likewise.
16700 (umulsidi3_nov6): Likewise.
16701 (umaddsidi4): Likewise.
16702 (*umulsidi3adddi): Likewise.
16703 (smulsi3_highpart): Likewise.
16704 (*smulsi3_highpart_nov6): Likewise.
16705 (umulsi3_highpart): Likewise.
16706 (*umulsi3_highpart_nov6): Likewise.
16707 * config/arm/arm.h (arm_arch3m): Delete.
16708 * config/arm/arm.c (arm_arch3m): Delete.
16709 (arm_option_override_internal): Update armv3-related comment.
16710 (arm_configure_build_target): Delete use of isa_bit_mode32.
16711 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
16712 (arm_rtx_costs_internal): Delete check of arm_arch3m.
16713 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
16714 (mulsa3): Likewise.
16715 (mulusa3): Likewise.
16716 * config/arm/arm-protos.h (arm_arch3m): Delete.
16717 * config/arm/arm-tables.opt: Regenerate.
16718 * config/arm/arm-tune.md: Likewise.
16719 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
16720 deleted architectures.
16721
16722 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16723
16724 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
16725 (armv5t, armv5te): New features.
16726 (ARMv5, ARMv5e): Delete fgroups.
16727 (ARMv5t, ARMv5te): Adjust for above changes.
16728 (ARMv6m): Likewise.
16729 (armv5, armv5e): Delete arches.
16730 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
16731 arm_arch5.
16732 (*call_reg_arm): Likewise.
16733 (*call_value_reg_armv5): Likewise.
16734 (*call_value_reg_arm): Likewise.
16735 (*call_symbol): Likewise.
16736 (*call_value_symbol): Likewise.
16737 (*sibcall_insn): Likewise.
16738 (*sibcall_value_insn): Likewise.
16739 (clzsi2): Likewise.
16740 (prefetch): Likewise.
16741 (define_split and define_peephole2 dependent on arm_arch5):
16742 Likewise.
16743 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
16744 arm_arch5e.
16745 (TARGET_ARM_QBIT): Likewise.
16746 (TARGET_DSP_MULTIPLY): Likewise.
16747 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
16748 (arm_arch5, arm_arch5e): Delete.
16749 (arm_arch5t, arm_arch5te): Declare.
16750 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
16751 (arm_arch5t): Declare.
16752 (arm_option_reconfigure_globals): Update for the above.
16753 (arm_options_perform_arch_sanity_checks): Update comment, replace
16754 use of arm_arch5 with arm_arch5t.
16755 (use_return_insn): Likewise.
16756 (arm_emit_call_insn): Likewise.
16757 (output_return_instruction): Likewise.
16758 (arm_final_prescan_insn): Likewise.
16759 (arm_coproc_builtin_available): Likewise.
16760 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
16761 arm_arch5e with arm_arch5t and arm_arch5te.
16762 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
16763 (arm_arch5t, arm_arch5te): Declare.
16764 * config/arm/arm-tables.opt: Regenerate.
16765 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
16766 * config/arm/t-multilib: Likewise.
16767 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
16768 instead of arm_arch5.
16769 (*call_reg_thumb1): Likewise.
16770 (*call_value_reg_thumb1_v5): Likewise.
16771 (*call_value_reg_thumb1): Likewise.
16772 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
16773 unreachable path.
16774 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
16775
16776 2018-05-18 Martin Liska <mliska@suse.cz>
16777
16778 PR gcov-profile/84846
16779 * doc/gcov.texi: Document -t option of gcov tool.
16780
16781 2018-05-18 Martin Liska <mliska@suse.cz>
16782
16783 PR gcov-profile/84846
16784 * gcov.c (print_usage): Add new -t option.
16785 (process_args): Handle the option.
16786 (generate_results): Use stdout as output when requested by
16787 the option.
16788
16789 2018-05-18 Martin Liska <mliska@suse.cz>
16790
16791 PR gcov-profile/84846
16792 * coverage.c (coverage_init): Write PWD to .gcno file.
16793 * doc/gcov.texi: Document how working directory is printed.
16794 * gcov-dump.c (dump_gcov_file): Print PWD.
16795 * gcov.c (output_intermediate_file): Likewise.
16796 (read_graph_file): Read PWD string.
16797 (output_lines): Print PWD.
16798
16799 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
16800
16801 PR middle-end/85817
16802 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
16803 for retval and return false if all args to phi are zero.
16804
16805 2018-05-18 Richard Biener <rguenther@suse.de>
16806
16807 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
16808 method.
16809 (evrp_dom_walker::before_dom_children): Call it.
16810
16811 2018-05-18 Richard Biener <rguenther@suse.de>
16812
16813 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
16814 results when processing array refs with variable index.
16815
16816 2018-05-18 Toon Moene <toon@moene.org>
16817
16818 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
16819 directly after that of -floop-interchange. Indicate that both
16820 options are enabled by default when specifying -O3.
16821
16822 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16823
16824 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
16825 iterator. Delete separate integer-mode vec_set<mode> expander.
16826 (aarch64_simd_vec_setv2di): Delete.
16827 (vec_setv2di): Delete.
16828 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
16829 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
16830 the "w, r" alternative.
16831
16832 2018-05-18 Martin Liska <mliska@suse.cz>
16833
16834 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
16835 * tree-pass.h (make_pass_lower_switch_O0): New function.
16836 * tree-switch-conversion.c (node_has_low_bound): Remove.
16837 (node_has_high_bound): Likewise.
16838 (node_is_bounded): Likewise.
16839 (class pass_lower_switch): Make it a template type and create
16840 two instances.
16841 (pass_lower_switch::execute): Add template argument.
16842 (make_pass_lower_switch): New function.
16843 (make_pass_lower_switch_O0): New function.
16844 (do_jump_if_equal): Remove.
16845 (emit_case_nodes): Simplify to just handle all 3 cases and leave
16846 all the hard work to tree optimization passes.
16847
16848 2018-05-18 Martin Liska <mliska@suse.cz>
16849
16850 * dbgcnt.c (limit_low): Renamed from limit.
16851 (limit_high): New variable.
16852 (dbg_cnt_is_enabled): Check for upper limit.
16853 (dbg_cnt): Adjust dumping.
16854 (dbg_cnt_set_limit_by_index): Add new argument for high
16855 value.
16856 (dbg_cnt_set_limit_by_name): Likewise.
16857 (dbg_cnt_process_single_pair): Parse new format.
16858 (dbg_cnt_process_opt): Use strtok.
16859 (dbg_cnt_list_all_counters): Remove 'value' and add
16860 'limit_high'.
16861 * doc/invoke.texi: Document changes.
16862
16863 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
16864
16865 * doc/sourcebuild.texi (scalar_all_fma): Document.
16866 * tree.def (FMA_EXPR): Delete.
16867 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
16868 * internal-fn.c (ternary_direct): New macro.
16869 (expand_ternary_optab_fn): Likewise.
16870 (direct_ternary_optab_supported_p): Likewise.
16871 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
16872 * builtins.c (fold_builtin_fma): Delete.
16873 (fold_builtin_3): Don't call it.
16874 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
16875 * expr.c (expand_expr_real_2): Likewise.
16876 * fold-const.c (operand_equal_p): Likewise.
16877 (fold_ternary_loc): Likewise.
16878 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
16879 * gimple.c (DEFTREECODE): Likewise.
16880 * gimplify.c (gimplify_expr): Likewise.
16881 * optabs-tree.c (optab_for_tree_code): Likewise.
16882 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
16883 * tree-eh.c (operation_could_trap_p): Likewise.
16884 (stmt_could_throw_1_p): Likewise.
16885 * tree-inline.c (estimate_operator_cost): Likewise.
16886 * tree-pretty-print.c (dump_generic_node): Likewise.
16887 (op_code_prio): Likewise.
16888 * tree-ssa-loop-im.c (stmt_cost): Likewise.
16889 * tree-ssa-operands.c (get_expr_operands): Likewise.
16890 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
16891 * fold-const-call.h (fold_fma): Delete.
16892 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
16893 CFN_FNMA and CFN_FNMS.
16894 (fold_fma): Delete.
16895 * genmatch.c (combined_fn): New enum.
16896 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
16897 (commutative_op): New function.
16898 (commutate): Use it. Handle more than 2 operands.
16899 (dt_operand::gen_gimple_expr): Use commutative_op.
16900 (parser::parse_expr): Allow :c to be used with non-binary
16901 operators if the commutative operand is known.
16902 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
16903 CFN_FMS, CFN_FNMA and CFN_FNMS.
16904 (backprop::process_assign_use): Remove FMA_EXPR handling.
16905 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
16906 (gen_hsa_fma): New function.
16907 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
16908 IFN_FNMA and IFN_FNMS.
16909 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
16910 * gimple-fold.h (follow_all_ssa_edges): Declare.
16911 * gimple-fold.c (follow_all_ssa_edges): New function.
16912 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
16913 gimple_build interface and use follow_all_ssa_edges to fold the result.
16914 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
16915 instead of checking for optabs directly.
16916 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
16917 rather than FMA_EXPRs.
16918 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
16919 call to IFN_FMA instead of an FMA_EXPR.
16920
16921 2018-05-17 Jim Wilson <jimw@sifive.com>
16922
16923 * expr.c (do_tablejump): When converting index to Pmode, if we have a
16924 sign extended promoted subreg, and the range does not have the sign bit
16925 set, then do a sign extend.
16926
16927 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
16928 test, check for sign extended subreg and/or constant operands, and
16929 do a sign extend in that case.
16930
16931 2018-05-17 Steve Ellcey <sellcey@cavium.com>
16932
16933 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
16934 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
16935 Add untyped.
16936 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
16937 Change logics_shift_reg to logics_shift_imm.
16938 (thunderx2t99_fp_loadpair_basic): Delete.
16939 (thunderx2t99_fp_storepair_basic): Delete.
16940 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
16941 (thunderx2t99_asimd_polynomial): Delete.
16942 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
16943 and neon_fp_mul_d_scalar_q.
16944 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
16945 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
16946 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
16947 (thunderx2t99_asimd_lut): Add missing tbl types.
16948 (thunderx2t99_asimd_ext): Delete.
16949 (thunderx2t99_asimd_load1_1_mult): Delete.
16950 (thunderx2t99_asimd_load1_2_mult): Delete.
16951 (thunderx2t99_asimd_load1_ldp): New.
16952 (thunderx2t99_asimd_load1): New.
16953 (thunderx2t99_asimd_load2): Add missing *load2* types.
16954 (thunderx2t99_asimd_load3): New.
16955 (thunderx2t99_asimd_load4): New.
16956 (thunderx2t99_asimd_store1_1_mult): Delete.
16957 (thunderx2t99_asimd_store1_2_mult): Delete.
16958 (thunderx2t99_asimd_store2_mult): Delete.
16959 (thunderx2t99_asimd_store2_onelane): Delete.
16960 (thunderx2t99_asimd_store_stp): New.
16961 (thunderx2t99_asimd_store1): New.
16962 (thunderx2t99_asimd_store2): New.
16963 (thunderx2t99_asimd_store3): New.
16964 (thunderx2t99_asimd_store4): New.
16965
16966 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
16967
16968 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
16969 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
16970
16971 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
16972 Segher Boessenkool <segher@kernel.crashing.org>
16973
16974 PR target/85698
16975 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
16976 operand.
16977
16978 2018-05-17 Richard Biener <rguenther@suse.de>
16979
16980 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
16981 for pruning loop and prune defs feeding only already visited PHIs.
16982
16983 2018-05-17 Richard Biener <rguenther@suse.de>
16984
16985 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
16986
16987 2018-05-17 Bin Cheng <bin.cheng@arm.com>
16988 Richard Biener <rguenther@suse.de>
16989
16990 PR tree-optimization/85793
16991 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
16992 for VMAT_ELEMENTWISE.
16993
16994 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
16995
16996 * internal-fn.h (lookup_internal_fn): Declare
16997 * internal-fn.c (lookup_internal_fn): New function.
16998 * gimple.c (gimple_build_call_from_tree): Handle calls to
16999 internal functions.
17000 * gimple-pretty-print.c (dump_gimple_call): Print "." before
17001 internal function names.
17002 * tree-pretty-print.c (dump_generic_node): Likewise.
17003 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
17004
17005 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
17006
17007 * gimple-fold.h (gimple_build): Make the function forms take
17008 combined_fn rather than built_in_function.
17009 (gimple_simplify): Likewise.
17010 * gimple-match-head.c (gimple_simplify): Likewise.
17011 * gimple-fold.c (gimple_build): Likewise.
17012 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
17013 rather than gimple_build_call_internal.
17014 (get_initial_defs_for_reduction): Likewise.
17015 (vect_create_epilog_for_reduction): Likewise.
17016 (vectorizable_live_operation): Likewise.
17017
17018 2018-05-17 Martin Liska <mliska@suse.cz>
17019
17020 * gimple-ssa-sprintf.c (format_directive): Do not use
17021 space in between 'G_' and '('.
17022
17023 2018-05-17 Jakub Jelinek <jakub@redhat.com>
17024
17025 PR target/85323
17026 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
17027 even if the mask is not all ones.
17028
17029 PR target/85323
17030 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
17031 vector.
17032 (ix86_gimple_fold_builtin): Likewise.
17033
17034 PR target/85323
17035 * config/i386/i386.c: Include tree-vector-builder.h.
17036 (ix86_vector_shift_count): New function.
17037 (ix86_fold_builtin): Fold shift builtins by scalar count.
17038 (ix86_gimple_fold_builtin): Likewise.
17039
17040 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
17041 _mm512_setzero): New intrinsics.
17042
17043 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
17044 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17045
17046 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
17047 code generation for cases where splatting a value is not useful.
17048 * simplify-rtx.c (simplify_ternary_operation): Simplify
17049 vec_merge across a vec_duplicate and a paradoxical subreg forming
17050 a vector mode to a vec_concat.
17051
17052 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
17053
17054 * config.gcc: Support "goldmont-plus".
17055 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17056 "goldmont-plus".
17057 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17058 PROCESSOR_GOLDMONT_PLUS.
17059 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
17060 (processor_target_table): Add "goldmont-plus".
17061 (PTA_GOLDMONT_PLUS): Define.
17062 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
17063 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
17064 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
17065 (fold_builtin_cpu): Add "goldmont-plus".
17066 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
17067 (ix86_option_override_internal): Add "goldmont-plus".
17068 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
17069 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
17070 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
17071 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
17072
17073 2018-05-17 Richard Biener <rguenther@suse.de>
17074
17075 PR tree-optimization/85757
17076 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
17077 remove defs that only feed that PHI from further processing.
17078
17079 2018-05-16 Jim Wilson <jimw@sifive.com>
17080
17081 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
17082 asterisk to name.
17083 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
17084
17085 2018-05-16 Mark Wielaard <mark@klomp.org>
17086
17087 * dwarf2out.c (count_index_strings): New function.
17088 (output_indirect_strings): Call count_index_strings and generate
17089 header for dwarf_version >= 5.
17090
17091 2018-05-16 Mark Wielaard <mark@klomp.org>
17092
17093 * dwarf2out.c (dwarf_FORM): New function.
17094 (set_indirect_string): Use dwarf_FORM.
17095 (reset_indirect_string): Likewise.
17096 (size_of_die): Likewise.
17097 (value_format): Likewise.
17098 (output_die): Likewise.
17099 (add_skeleton_AT_string): Likewise.
17100 (output_macinfo_op): Likewise.
17101 (index_string): Likewise.
17102 (output_index_string_offset): Likewise.
17103 (output_index_string): Likewise.
17104 (count_index_strings): Likewise.
17105
17106 2018-05-16 Carl Love <cel@us.ibm.com>
17107
17108 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17109 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
17110
17111 2018-05-16 Martin Jambor <mjambor@suse.cz>
17112
17113 * ipa-prop.c (ipa_free_all_edge_args): Remove.
17114 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
17115
17116 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
17117
17118 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
17119 (fnma<mode>4): Likewise.
17120 (fms<mode>4): Likewise.
17121 (fnms<mode>4): Likewise.
17122 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
17123 (aarch64_fnma<mode>4): Likewise.
17124 (aarch64_fms<mode>4): Likewise.
17125 (aarch64_fnms<mode>4): Likewise.
17126 (aarch64_fnmadd<mode>4): Likewise.
17127
17128 2018-05-16 Jason Merrill <jason@redhat.com>
17129
17130 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
17131
17132 2018-05-16 Richard Biener <rguenther@suse.de>
17133
17134 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
17135 (dump_stmt_cost): Declare.
17136 (add_stmt_cost): Dump cost we add.
17137 (add_stmt_costs): New function.
17138 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
17139 No longer exported.
17140 (vect_analyze_stmt): Adjust prototype.
17141 (vectorizable_condition): Likewise.
17142 (vectorizable_live_operation): Likewise.
17143 (vectorizable_reduction): Likewise.
17144 (vectorizable_induction): Likewise.
17145 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
17146 cost vector to pass to vectorizable_ and record afterwards.
17147 (vect_model_reduction_cost): Take cost vector argument and adjust.
17148 (vect_model_induction_cost): Likewise.
17149 (vectorizable_reduction): Likewise.
17150 (vectorizable_induction): Likewise.
17151 (vectorizable_live_operation): Likewise.
17152 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
17153 SLP_TREE_NUMBER_OF_VEC_STMTS.
17154 (vect_analyze_slp_cost_1): Remove.
17155 (vect_analyze_slp_cost): Likewise.
17156 (vect_slp_analyze_node_operations): Take visited args and
17157 a target cost vector. Avoid processing already visited stmt sets.
17158 (vect_slp_analyze_operations): Use a local cost vector to gather
17159 costs and register those of non-discarded instances.
17160 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
17161 (vect_schedule_slp_instance): Remove copying of
17162 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
17163 zero.
17164 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
17165 adding cost. Record cost entry location.
17166 (vect_prologue_cost_for_slp_op): Function to compute cost of
17167 a constant or invariant generated for SLP vect in the prologue,
17168 split out from vect_analyze_slp_cost_1.
17169 (vect_model_simple_cost): Make static. Adjust for SLP costing.
17170 (vect_model_promotion_demotion_cost): Likewise.
17171 (vect_model_store_cost): Likewise, make static.
17172 (vect_model_load_cost): Likewise.
17173 (vectorizable_bswap): Add cost vector arg and adjust.
17174 (vectorizable_call): Likewise.
17175 (vectorizable_simd_clone_call): Likewise.
17176 (vectorizable_conversion): Likewise.
17177 (vectorizable_assignment): Likewise.
17178 (vectorizable_shift): Likewise.
17179 (vectorizable_operation): Likewise.
17180 (vectorizable_store): Likewise.
17181 (vectorizable_load): Likewise.
17182 (vectorizable_condition): Likewise.
17183 (vectorizable_comparison): Likewise.
17184 (can_vectorize_live_stmts): Likewise.
17185 (vect_analyze_stmt): Likewise.
17186 (vect_transform_stmt): Adjust calls to vectorizable_*.
17187 * tree-vectorizer.c: Include gimple-pretty-print.h.
17188 (dump_stmt_cost): New function.
17189
17190 2018-05-16 Richard Biener <rguenther@suse.de>
17191
17192 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
17193 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
17194 * tree-ssa-dse.c: Include tree-ssa-loop.h.
17195 (check_name): New callback.
17196 (dse_classify_store): Track cycles via a visited bitmap of PHI
17197 defs and simplify handling of in-loop and across loop dead stores
17198 and properly fail for loop-variant refs. Handle byte-tracking with
17199 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
17200 limiting the walk.
17201
17202 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
17203
17204 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
17205 (vect_get_mask_type_for_stmt): Likewise.
17206 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
17207 split out from...
17208 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
17209 to determine the statement's vector type and the vector type that
17210 should be used for calculating nunits. Deal with cases in which
17211 the type has to be deferred.
17212 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
17213 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
17214 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
17215 (vect_determine_vf_for_stmt): New functions, split out from...
17216 (vect_determine_vectorization_factor): ...here.
17217 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
17218 (vect_get_mask_type_for_stmt): New functions, split out from
17219 vect_determine_vectorization_factor.
17220
17221 2018-05-16 Richard Biener <rguenther@suse.de>
17222
17223 * tree-cfg.c (verify_gimple_assign_ternary): Properly
17224 verify the [VEC_]COND_EXPR embedded comparison.
17225
17226 2018-05-15 Martin Sebor <msebor@redhat.com>
17227
17228 PR tree-optimization/85753
17229 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
17230 RECORD_TYPE in addition to ARRAY_TYPE.
17231
17232 2018-05-15 Martin Sebor <msebor@redhat.com>
17233
17234 PR middle-end/85643
17235 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
17236
17237 2018-05-15 Richard Biener <rguenther@suse.de>
17238
17239 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
17240 add by_clobber_p one. Change algorithm to collect all defs
17241 representing uses we need to walk and try reducing them to
17242 a single one before failing.
17243 (dse_dom_walker::dse_optimize_stmt): Adjust.
17244
17245 2018-05-13 Mark Wielaard <mark@klomp.org>
17246
17247 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
17248 (size_of_loc_descr): Likewise.
17249 (output_loc_operands): Likewise.
17250 (output_loc_operands_raw): Likewise.
17251 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
17252 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
17253 (hash_loc_operands): Likewise.
17254 (compare_loc_operands): Likewise.
17255
17256 2018-05-14 Mark Wielaard <mark@klomp.org>
17257
17258 * dwarf2out.c (count_index_addrs): New function.
17259 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
17260
17261 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17262
17263 PR tree-optimization/83648
17264 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
17265 return value as malloc candidate.
17266
17267 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17268
17269 PR ipa/85734
17270 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
17271 param as true in call to suggest_attribute.
17272
17273 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
17274
17275 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
17276 -mreadonly-in-sdata.
17277
17278 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17279
17280 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
17281 New pattern.
17282 (aarch64_crypto_aesd_fused): Likewise.
17283
17284 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
17285
17286 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
17287 (movsi_aarch64): Likewise.
17288 (load_pairsi): Likewise.
17289 (load_pairdi): Likewise.
17290 (store_pairsi): Likewise.
17291 (store_pairdi): Likewise.
17292 (load_pairsf): Likewise.
17293 (load_pairdf): Likewise.
17294 (store_pairsf): Likewise.
17295 (store_pairdf): Likewise.
17296 (zero_extend): Likewise.
17297 (trunc): Swap alternatives.
17298 (fcvt_target): Add '?' to prefer w over r.
17299
17300 2018-05-14 Jakub Jelinek <jakub@redhat.com>
17301
17302 PR target/85756
17303 * config/i386/i386.md: Disallow non-commutative arithmetics in
17304 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
17305 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
17306 in the peephole2 before it.
17307
17308 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
17309
17310 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
17311 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
17312 (ix86_handle_option): Handle -mcldemote.
17313 * config.gcc: New header.
17314 * config/i386/cldemoteintrin.h: New file.
17315 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
17316 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17317 -mcldemote.
17318 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17319 OPTION_MASK_ISA_CLDEMOTE.
17320 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
17321 (ix86_valid_target_attribute_inner_p): Ditto.
17322 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
17323 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
17324 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
17325 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
17326 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
17327 (cldemote): New.
17328 * config/i386/i386.opt: Add -mcldemote.
17329 * config/i386/x86intrin.h: New header.
17330 * doc/invoke.texi: Add -mcldemote.
17331
17332 2018-05-14 Richard Biener <rguenther@suse.de>
17333
17334 * doc/match-and-simplify.texi: Adjust :s documentation.
17335
17336 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
17337
17338 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
17339 intended memcpy size.
17340 (REORDER_45): Likewise.
17341
17342 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
17343
17344 * sort.cc: New file.
17345 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
17346 * vec.c (qsort_chk): Use gcc_qsort.
17347 * Makefile.in (OBJS-libcommon): Add sort.o.
17348 (build/sort.o): New target. Use it...
17349 (BUILD_RTL): ... here, and...
17350 (build/gencfn-macros): ... here, and...
17351 (build/genmatch): ... here.
17352
17353 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17354 Chung-Ju Wu <jasonwucj@gmail.com>
17355
17356 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
17357 * config/nds32/nds32-graywolf.md: New file.
17358 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
17359 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
17360 pipeline.
17361 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
17362 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
17363 * config/nds32/nds32.md (pipeline_model): Add graywolf.
17364 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
17365 * config/nds32/pipelines.md: Include n15 settings.
17366
17367 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17368 Chung-Ju Wu <jasonwucj@gmail.com>
17369
17370 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
17371 * config/nds32/nds32-n13.md: New file.
17372 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
17373 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
17374 pipeline.
17375 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
17376 * config/nds32/nds32.md (pipeline_model): Add n13.
17377 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
17378 * config/nds32/pipelines.md: Include n13 settings.
17379
17380 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17381 Chung-Ju Wu <jasonwucj@gmail.com>
17382
17383 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
17384 * config/nds32/nds32-n10.md: New file.
17385 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
17386 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
17387 pipeline.
17388 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
17389 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
17390 * config/nds32/nds32.md (pipeline_model): Add n10.
17391 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
17392 * config/nds32/pipelines.md: Include n10 settings.
17393
17394 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
17395 Kito Cheng <kito.cheng@gmail.com>
17396 Chung-Ju Wu <jasonwucj@gmail.com>
17397
17398 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
17399 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
17400 Add enum values for DSP extension instructions.
17401 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
17402 New constraints.
17403 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
17404 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
17405 New code iterators.
17406 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
17407 * config/nds32/nds32-dspext.md: New file for DSP implementation.
17408 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
17409 * config/nds32/nds32-intrinsic.md: Likewise.
17410 * config/nds32/nds32_intrinsic.h: Likewise.
17411 * config/nds32/nds32-md-auxiliary.c: Likewise.
17412 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
17413 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
17414 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
17415 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
17416 * config/nds32/nds32-protos.h: New declarations for DSP extension.
17417 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
17418 TYPE_DMAC in switch statement.
17419 * config/nds32/nds32.c: New checking and implementation for DSP
17420 extension instructions.
17421 * config/nds32/nds32.h: Likewise.
17422 * config/nds32/nds32.md: Likewise.
17423 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
17424 * config/nds32/predicates.md: Implement new predicates for DSP
17425 extension.
17426
17427 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
17428
17429 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
17430 Reformat alternatives and attributes so it is easier to identify
17431 which constraints/attributes go with which instruction.
17432 (mov<mode>_hardfloat32, FMOVE64): Likewise.
17433 (mov<mode>_softfloat32, FMOVE64): Likewise.
17434 (mov<mode>_hardfloat64, FMOVE64): Likewise.
17435 (mov<mode>_softfloat64, FMOVE64): Likewise.
17436
17437 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
17438
17439 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17440 subsection.
17441 (Basic PowerPC Built-in Functions): The new name of the
17442 subsection previously known as "PowerPC Built-in Functions".
17443 (Basic PowerPC Built-in Functions Available on all Configurations):
17444 New subsubsection.
17445 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
17446 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
17447 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
17448 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
17449
17450 2018-05-11 Martin Jambor <mjambor@suse.cz>
17451
17452 PR ipa/85655
17453 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
17454 single const.
17455
17456 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17457
17458 PR target/85733
17459 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
17460
17461 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
17462
17463 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
17464 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
17465 (ix86_handle_option): Handle -mwaitpkg.
17466 * config.gcc: New header.
17467 * config/i386/cpuid.h (bit_WAITPKG): New bit.
17468 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
17469 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
17470 function type.
17471 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17472 OPTION_MASK_ISA_WAITPKG.
17473 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
17474 (ix86_option_override_internal): Add PTA_WAITPKG.
17475 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
17476 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
17477 IX86_BUILTIN_TPAUSE.
17478 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
17479 __builtin_ia32_umwait and __builtin_ia32_tpause.
17480 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
17481 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
17482 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
17483 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
17484 UNSPECV_TPAUSE): New.
17485 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
17486 * config/i386/i386.opt: Add -mwaitpkg.
17487 * config/i386/waitpkgintrin.h: New file.
17488 * config/i386/x86intrin.h: New header.
17489 * doc/invoke.texi: Add -mwaitpkg.
17490
17491 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17492
17493 PR target/85606
17494 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
17495 equivalent.
17496 (cortex-m0): Use armv6s-m isa.
17497 (cortex-m0plus): Likewise.
17498 (cortex-m1): Likewise.
17499 (cortex-m0.small-multiply): Likewise.
17500 (cortex-m0plus.small-multiply): Likewise.
17501 (cortex-m1.small-multiply): Likewise.
17502
17503 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
17504 Jakub Jelinek <jakub@redhat.com>
17505
17506 PR tree-optimization/85692
17507 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
17508 source permute as well.
17509
17510 2018-05-11 Martin Liska <mliska@suse.cz>
17511
17512 PR sanitizer/85556
17513 * doc/extend.texi: Document LLVM style format for no_sanitize
17514 attribute.
17515
17516 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
17517
17518 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
17519 mode_supports_vsx_dform_quad to mode_supports_dq_form.
17520 (mode_supports_vsx_dform_quad): Likewise.
17521 (mode_supports_vmx_dform): Move these functions to be next to the
17522 other mode_supports functions.
17523 (mode_supports_dq_form): Likewise.
17524 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
17525 mode_supports_dq_form.
17526 (reg_offset_addressing_ok_p): Likewise.
17527 (offsettable_ok_by_alignment): Likewise.
17528 (rs6000_legitimate_offset_address_p): Likewise.
17529 (legitimate_lo_sum_address_p): Likewise.
17530 (rs6000_legitimize_address): Likewise.
17531 (rs6000_legitimize_reload_address): Likewise.
17532 (rs6000_secondary_reload_inner): Likewise.
17533 (rs6000_preferred_reload_class): Likewise.
17534 (rs6000_output_move_128bit): Likewise.
17535
17536 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17537
17538 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
17539 Generate SImode target register for null target.
17540 <case IX86_BUILTIN_XGETBV>: Ditto.
17541 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
17542 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
17543
17544 2018-05-10 Carl Love <cel@us.ibm.com>
17545
17546 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17547 dcbtt and dcbtstt if operands[2] is 0.
17548
17549 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17550
17551 PR target/85693
17552 * config/i386/sse.md (usadv64qi): New expander.
17553
17554 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
17555
17556 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
17557 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
17558 -maltivec=be support.
17559 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
17560 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
17561 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
17562 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
17563 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
17564 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
17565 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
17566 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
17567 altivec_vsumsws): Adjust.
17568 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
17569 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
17570 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
17571 support.
17572 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
17573 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
17574 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
17575 (altivec_lve<VI_char>x): Delete expand.
17576 (*altivec_lve<VI_char>x_internal): Rename to...
17577 (altivec_lve<VI_char>x): ... this.
17578 (altivec_lvxl_<mode>): Delete expand.
17579 (*altivec_lvxl_<mode>_internal): Rename to ...
17580 (altivec_lvxl_<mode>): ... this.
17581 (altivec_stvxl_<mode>): Delete expand.
17582 (*altivec_stvxl_<mode>_internal): Rename to ...
17583 (altivec_stvxl_<mode>): ... this.
17584 (altivec_stve<VI_char>x): Delete expand.
17585 (*altivec_stve<VI_char>x_internal): Rename to ...
17586 (altivec_stve<VI_char>x): ... this.
17587 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
17588 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
17589 reduc_plus_scal_<mode>): Adjust.
17590 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
17591 comment.
17592 (rs6000_cpu_cpp_builtins): Adjust.
17593 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
17594 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
17595 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
17596 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
17597 -maltivec=be support.
17598 (rs6000_split_vec_extract_var): Adjust.
17599 (rs6000_split_v4si_init): Adjust.
17600 (swap_selector_for_mode): Delete.
17601 (altivec_expand_lvx_be, altivec_expand_stvx_be,
17602 altivec_expand_stvex_be): Delete.
17603 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
17604 -maltivec=be support.
17605 (rs6000_gimple_fold_builtin): Ditto.
17606 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
17607 Adjust.
17608 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
17609 (TARGET_DIRECT_MOVE_64BIT): Adjust.
17610 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
17611 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
17612 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
17613 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
17614 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
17615 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
17616 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
17617 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
17618 anonymous split): Adjust.
17619 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
17620 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
17621
17622 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
17623
17624 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
17625 when --with-gxx-include-dir is also specified.
17626 * configure: Regenerate.
17627
17628 2018-05-09 Jim Wilson <jimw@sifive.com>
17629
17630 PR target/84797
17631 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
17632 * config/riscv/t-withmultilib: New.
17633 * config/riscv/withmultilib.h: New.
17634 * doc/install.texi: Document RISC-V --with-multilib-list support.
17635
17636 2018-05-09 Richard Biener <rguenther@suse.de>
17637
17638 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
17639 vector.
17640 (vect_bb_vectorization_profitable_p): Adjust. Compute
17641 actual scalar cost using the cost vector and the add_stmt_cost
17642 machinery.
17643
17644 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17645
17646 PR rtl-optimization/85645
17647 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
17648 in the REG_CFA_REGISTER note for LR, don't leave it empty.
17649
17650 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17651
17652 PR rtl-optimization/85645
17653 * shrink-wrap.c (spread_components): Return a boolean saying if
17654 anything was changed.
17655 (try_shrink_wrapping_separate): Iterate spread_components until
17656 nothing changes anymore.
17657
17658 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17659
17660 PR rtl-optimization/85645
17661 * regrename.c (build_def_use): Also kill the chains that include the
17662 destination of a REG_CFA_REGISTER note.
17663
17664 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17665
17666 PR rtl-optimization/85645
17667 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
17668 insn that has a REG_CFA_REGISTER note.
17669
17670 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
17671
17672 * cfgexpand.c (expand_clobber): New function.
17673 (expand_gimple_stmt_1): Use it.
17674 * tree-vect-stmts.c (vect_clobber_variable): New function,
17675 split out from...
17676 (vectorizable_simd_clone_call): ...here.
17677 (vectorizable_store): Emit a clobber either side of an
17678 IFN_STORE_LANES sequence.
17679 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
17680
17681 2018-05-09 Tom de Vries <tom@codesourcery.com>
17682
17683 PR target/85626
17684 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
17685 (define_insn "trap_if_false"): Add exit after trap.
17686
17687 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
17688
17689 PR rtl-optimization/85638
17690 * bb-reorder.c: Include common/common-target.h.
17691 (create_forwarder_block): New function extracted from...
17692 (fix_up_crossing_landing_pad): ...here. Rename into...
17693 (dw2_fix_up_crossing_landing_pad): ...this.
17694 (sjlj_fix_up_crossing_landing_pad): New function.
17695 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
17696 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
17697 from both partitions and exit the loop after one iteration.
17698
17699 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17700
17701 Revert:
17702 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17703 subsection.
17704 (Basic PowerPC Built-in Functions): The new name of the
17705 subsection previously known as "PowerPC Built-in Functions".
17706 (Basic PowerPC Built-in Functions Available on all Configurations):
17707 New subsubsection.
17708 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17709 subsubsection.
17710 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17711 subsubsection.
17712 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17713 subsubsection.
17714 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17715 subsubsection.
17716
17717 2018-05-08 Jim Wilson <jimw@sifive.com>
17718
17719 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
17720 (LD_EMUL_SUFFIX): New.
17721 (LINK_SPEC): Use it.
17722
17723 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17724
17725 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17726 subsection.
17727 (Basic PowerPC Built-in Functions): The new name of the
17728 subsection previously known as "PowerPC Built-in Functions".
17729 (Basic PowerPC Built-in Functions Available on all Configurations):
17730 New subsubsection.
17731 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17732 subsubsection.
17733 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17734 subsubsection.
17735 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17736 subsubsection.
17737 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17738 subsubsection.
17739
17740 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17741
17742 PR target/85683
17743 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
17744 after cmpelim optimization.
17745
17746 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
17747
17748 * config.gcc: Support "goldmont".
17749 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
17750 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17751 PROCESSOR_GOLDMONT.
17752 * config/i386/i386.c (m_GOLDMONT): Define.
17753 (processor_target_table): Add "goldmont".
17754 (PTA_GOLDMONT): Define.
17755 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
17756 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
17757 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
17758 (fold_builtin_cpu): Add "goldmont".
17759 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
17760 (ix86_option_override_internal): Add "goldmont".
17761 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
17762 (processor_type): Add PROCESSOR_GOLDMONT.
17763 * config/i386/i386.md: Add CPU "glm".
17764 * config/i386/glm.md: New file.
17765 * config/i386/x86-tune.def: Add m_GOLDMONT.
17766 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
17767
17768 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17769
17770 PR target/85572
17771 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
17772 E_V4DImode.
17773 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
17774 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
17775 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
17776
17777 PR target/85317
17778 * config/i386/i386.c (ix86_fold_builtin): Handle
17779 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
17780
17781 PR target/85480
17782 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
17783 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
17784
17785 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
17786
17787 PR target/85658
17788 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
17789 (check_arch): Likewise.
17790 (check_fpu): Return the result rather than printing it.
17791 (end arch): Fix operator precedence.
17792 (end cpu): Likewise.
17793 (END): Print the result from check_fpu.
17794
17795 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17796 Alan Hayward <alan.hayward@arm.com>
17797 David Sherwood <david.sherwood@arm.com>
17798
17799 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
17800 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
17801 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
17802 (*fcmuo<mode>_and): New patterns.
17803
17804 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17805
17806 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
17807 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
17808 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
17809 (cmp_op, sve_imm_con): New code attributes.
17810 (SVE_COND_INT_CMP, imm_con): Delete.
17811 (cmp_op): Remove above unspecs from int attribute.
17812 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
17813 to...
17814 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
17815 comparison-specific unspecs.
17816 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
17817 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
17818 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
17819 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
17820 (*vec_fcm<cmp_op><mode>): Rename to...
17821 (*fcm<cmp_op><mode>): ...this and adjust likewise.
17822 (*vec_fcmuo<mode>): Rename to...
17823 (*fcmuo<mode>): ...this and adjust likewise.
17824 (*pred_fcm<cmp_op><mode>): New pattern.
17825 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
17826 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
17827 functions.
17828 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
17829 and UNORDERED.
17830 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
17831 (aarch64_emit_sve_predicated_cond): New function.
17832 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
17833 (aarch64_emit_unspec_cond_or): Replace with...
17834 (aarch64_emit_sve_or_conds): ...this new function. Use
17835 aarch64_emit_sve_ptrue_op for the individual comparisons and
17836 aarch64_emit_binop to OR them together.
17837 (aarch64_emit_inverted_unspec_cond): Replace with...
17838 (aarch64_emit_sve_inverted_cond): ...this new function. Use
17839 aarch64_emit_sve_ptrue_op for the comparison and
17840 aarch64_emit_unop to invert the result.
17841 (aarch64_expand_sve_vec_cmp_float): Update after the above
17842 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
17843
17844 2018-05-07 Nathan Sidwell <nathan@acm.org>
17845
17846 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
17847 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
17848 (Backwards Compatibility): Likewise.
17849
17850 2018-05-07 Luis Machado <luis.machado@linaro.org>
17851
17852 PR bootstrap/85681
17853 Revert:
17854 2018-05-07 Luis Machado <luis.machado@linaro.org>
17855
17856 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17857 <prefetch_dynamic_strides>: New const bool field.
17858 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17859 prefetch_dynamic_strides.
17860 (exynosm1_prefetch_tune): Likewise.
17861 (thunderxt88_prefetch_tune): Likewise.
17862 (thunderx_prefetch_tune): Likewise.
17863 (thunderx2t99_prefetch_tune): Likewise.
17864 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
17865 to false.
17866 (aarch64_override_options_internal): Update to set
17867 PARAM_PREFETCH_DYNAMIC_STRIDES.
17868 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
17869 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
17870 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
17871 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
17872 prefetch-dynamic-strides setting.
17873
17874 2018-05-07 Luis Machado <luis.machado@linaro.org>
17875
17876 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17877 <minimum_stride>: New const int field.
17878 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17879 minimum_stride field.
17880 (exynosm1_prefetch_tune): Likewise.
17881 (thunderxt88_prefetch_tune): Likewise.
17882 (thunderx_prefetch_tune): Likewise.
17883 (thunderx2t99_prefetch_tune): Likewise.
17884 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
17885 (aarch64_override_options_internal): Update to set
17886 PARAM_PREFETCH_MINIMUM_STRIDE.
17887 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
17888 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
17889 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
17890 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
17891 stride is constant and is below the minimum stride threshold.
17892
17893 2018-05-07 Luis Machado <luis.machado@linaro.org>
17894
17895 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
17896 to 512.
17897
17898 2018-05-07 Luis Machado <luis.machado@linaro.org>
17899
17900 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17901 <prefetch_dynamic_strides>: New const bool field.
17902 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17903 prefetch_dynamic_strides.
17904 (exynosm1_prefetch_tune): Likewise.
17905 (thunderxt88_prefetch_tune): Likewise.
17906 (thunderx_prefetch_tune): Likewise.
17907 (thunderx2t99_prefetch_tune): Likewise.
17908 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
17909 to false.
17910 (aarch64_override_options_internal): Update to set
17911 PARAM_PREFETCH_DYNAMIC_STRIDES.
17912 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
17913 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
17914 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
17915 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
17916 prefetch-dynamic-strides setting.
17917
17918 2018-05-07 Luis Machado <luis.machado@linaro.org>
17919
17920 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17921 <minimum_stride>: New const int field.
17922 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17923 minimum_stride field.
17924 (exynosm1_prefetch_tune): Likewise.
17925 (thunderxt88_prefetch_tune): Likewise.
17926 (thunderx_prefetch_tune): Likewise.
17927 (thunderx2t99_prefetch_tune): Likewise.
17928 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
17929 (aarch64_override_options_internal): Update to set
17930 PARAM_PREFETCH_MINIMUM_STRIDE.
17931 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
17932 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
17933 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
17934 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
17935 stride is constant and is below the minimum stride threshold.
17936
17937 2018-05-06 Jakub Jelinek <jakub@redhat.com>
17938
17939 PR c++/85659
17940 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
17941 the type is addressable. Don't force op into register if it has
17942 BLKmode.
17943
17944 2018-05-05 Roland McGrath <mcgrathr@google.com>
17945
17946 PR other/77609
17947 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
17948 any section for which we don't know a specific type it should have,
17949 regardless of name. Previously this was done only for the exact
17950 names ".init_array", ".fini_array", and ".preinit_array".
17951 (default_elf_asm_named_section): Add comment about
17952 relationship with default_section_type_flags and SECTION_NOTYPE.
17953 (get_section): Don't consider it a type conflict if one side has
17954 SECTION_NOTYPE and the other doesn't, as long as neither has the
17955 SECTION_BSS et al used in the default_section_type_flags logic.
17956
17957 2018-05-05 Tom de Vries <tom@codesourcery.com>
17958
17959 PR target/85653
17960 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
17961 (workaround_barsyncs): New function.
17962 (nvptx_reorg): Use workaround_barsyncs.
17963 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
17964 (define_expand "nvptx_membar_cta"): New define_expand.
17965 (define_insn "*nvptx_membar_cta"): New insn.
17966
17967 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
17968
17969 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
17970 To improve optimization opportunities.
17971 * builtin-types.def: The new needed builtin types for the above.
17972
17973 2018-05-04 Richard Biener <rguenther@suse.de>
17974
17975 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
17976 * gimple-ssa-store-merging.c
17977 (imm_store_chain_info::output_merged_store): Remove redundant create,
17978 release split_store vector contents on failure.
17979 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
17980 scalar stmt vector on cache hit.
17981
17982 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
17983
17984 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
17985 Xilinx FP support.
17986 * config.gcc (powerpc-xilinx-eabi*): Remove.
17987 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
17988 support.
17989 (fusion_addis_mem_combo_load): Ditto.
17990 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
17991 FP support.
17992 (rs6000_cpu_cpp_builtins): Ditto.
17993 * config/rs6000/rs6000-linux.c
17994 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
17995 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
17996 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
17997 support.
17998 (rs6000_setup_reg_addr_masks): Ditto.
17999 (rs6000_init_hard_regno_mode_ok): Ditto.
18000 (rs6000_option_override_internal): Ditto.
18001 (legitimate_lo_sum_address_p): Ditto.
18002 (rs6000_legitimize_address): Ditto.
18003 (rs6000_legitimize_reload_address): Ditto.
18004 (rs6000_legitimate_address_p): Ditto.
18005 (abi_v4_pass_in_fpr): Ditto.
18006 (setup_incoming_varargs): Ditto.
18007 (rs6000_gimplify_va_arg): Ditto.
18008 (rs6000_split_multireg_move): Ditto.
18009 (rs6000_savres_strategy): Ditto.
18010 (rs6000_emit_prologue_components): Ditto.
18011 (rs6000_emit_epilogue_components): Ditto.
18012 (rs6000_emit_prologue): Ditto.
18013 (rs6000_emit_epilogue): Ditto.
18014 (rs6000_elf_file_end): Ditto.
18015 (rs6000_function_value): Ditto.
18016 (rs6000_libcall_value): Ditto.
18017 * config/rs6000/rs6000.h: Ditto.
18018 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
18019 (TARGET_MINMAX): ... this. New.
18020 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
18021 * config/rs6000/rs6000.md: Remove Xilinx FP support.
18022 (*movsi_internal1_single): Delete.
18023 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
18024 mfpu=, mxilinx-fpu): Delete.
18025 * config/rs6000/singlefp.h: Delete.
18026 * config/rs6000/sysv4.h: Remove Xilinx FP support.
18027 * config/rs6000/t-rs6000: Ditto.
18028 * config/rs6000/t-xilinx: Delete.
18029 * config/rs6000/titan.md: Adjust for fp_type removal.
18030 * config/rs6000/vsx.md: Remove Xilinx FP support.
18031 (VStype_simple): Delete.
18032 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
18033 * config/rs6000/xfpu.h: Delete.
18034 * config/rs6000/xfpu.md: Delete.
18035 * config/rs6000/xilinx.h: Delete.
18036 * config/rs6000/xilinx.opt: Delete.
18037 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
18038 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
18039
18040 2018-05-04 Tom de Vries <tom@codesourcery.com>
18041
18042 PR libgomp/85639
18043 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
18044 if ignore == 0.
18045
18046 2018-05-04 Richard Biener <rguenther@suse.de>
18047
18048 PR middle-end/85627
18049 * tree-complex.c (update_complex_assignment): We are always in SSA form.
18050 (expand_complex_div_wide): Likewise.
18051 (expand_complex_operations_1): Likewise.
18052 (expand_complex_libcall): Preserve EH info of the original stmt.
18053 (tree_lower_complex): Handle removed blocks.
18054 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
18055 on complex multiplication and division libcall builtins.
18056
18057 2018-05-04 Richard Biener <rguenther@suse.de>
18058
18059 PR middle-end/85574
18060 * fold-const.c (negate_expr_p): Restrict negation of operand
18061 zero of a division to when we know that can happen without
18062 overflow.
18063 (fold_negate_expr_1): Likewise.
18064
18065 2018-05-04 Jakub Jelinek <jakub@redhat.com>
18066
18067 PR libstdc++/85466
18068 * real.h (real_nextafter): Declare.
18069 * real.c (real_nextafter): New function.
18070 * fold-const-call.c (fold_const_nextafter): New function.
18071 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
18072 CASE_CFN_NEXTTOWARD.
18073 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
18074 even when arg1_mode is different from arg0_mode.
18075
18076 2018-05-03 Nathan Sidwell <nathan@acm.org>
18077
18078 * doc/extend.texi (Deprecated Features): Remove
18079 -ffriend-injection.
18080 (Backwards Compatibility): Likewise.
18081 * doc/invoke.texi (C++ Language Options): Likewise.
18082 (C++ Dialect Options): Likewise.
18083
18084 2018-05-03 Jakub Jelinek <jakub@redhat.com>
18085
18086 PR target/85530
18087 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
18088 _mm512_mask_mullox_epi64): New intrinsics.
18089
18090 2018-05-03 Tom de Vries <tom@codesourcery.com>
18091
18092 PR testsuite/85106
18093 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18094 dump files): Add offload-tree.
18095
18096 2018-05-03 Richard Biener <rguenther@suse.de>
18097
18098 PR tree-optimization/85615
18099 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
18100 to loops not nested in BBs loop father to avoid creating multi-entry
18101 loops.
18102
18103 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18104
18105 PR tree-optimization/70291
18106 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
18107 arguments. Change return type to tree. Emit libcall as a new
18108 statement rather than replacing existing one when inplace_p is true.
18109 (expand_complex_multiplication_components): New function.
18110 (expand_complex_multiplication): Expand floating-point complex
18111 multiplication using the above.
18112 (expand_complex_division): Rename inner_type parameter to type.
18113 Update expand_complex_libcall call-site.
18114 (expand_complex_operations_1): Update expand_complex_multiplication
18115 and expand_complex_division call-sites.
18116
18117 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18118
18119 PR target/85582
18120 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18121 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18122 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
18123 the highest significant bit of the shift count mask is clear. In
18124 check whether and[sq]i3 is needed verify that all significant bits
18125 of the shift count other than the highest are set.
18126
18127 2018-05-02 Tom de Vries <tom@codesourcery.com>
18128
18129 PR libgomp/82428
18130 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
18131 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
18132 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
18133 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
18134 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
18135 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
18136 __builtin_goacc_parlevel_size.
18137
18138 2018-05-02 Richard Biener <rguenther@suse.de>
18139
18140 PR tree-optimization/85597
18141 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
18142 do not use split vect_get_vec_defs call but call vect_get_slp_defs
18143 directly.
18144
18145 2018-05-02 Tom de Vries <tom@codesourcery.com>
18146
18147 PR testsuite/85106
18148 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18149 dump files): Add ltrans-tree.
18150
18151 2018-05-02 Tom de Vries <tom@codesourcery.com>
18152
18153 PR testsuite/85106
18154 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18155 dump files): Add wpa-ipa.
18156
18157 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
18158
18159 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
18160 powerpc*-*-linux*paired* target.
18161 * config/rs6000/750cl.h: Delete.
18162 * config/rs6000/paired.h: Delete.
18163 * config/rs6000/paired.md: Delete.
18164 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
18165 float support.
18166 * config/rs6000/rs6000-builtin.def: Remove paired float support.
18167 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
18168 comment. Remove paired float support.
18169 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
18170 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
18171 VECTOR_PAIRED.
18172 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
18173 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
18174 declarations.
18175 * config/rs6000/rs6000.c: Remove paired float support.
18176 (paired_expand_vector_init, paired_expand_vector_move,
18177 paired_emit_vector_compare, paired_emit_vector_cond_expr,
18178 (paired_expand_lv_builtin, paired_expand_stv_builtin,
18179 paired_expand_builtin, paired_expand_predicate_builtin,
18180 paired_init_builtins): Delete.
18181 * config/rs6000/rs6000.h: Remove paired float support.
18182 * config/rs6000/rs6000.md: Remove paired float support.
18183 (move_from_CR_ov_bit): Delete.
18184 * config/rs6000/rs6000.opt (mpaired): Delete.
18185 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
18186 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
18187
18188 2018-05-02 Richard Biener <rguenther@suse.de>
18189
18190 PR middle-end/85567
18191 * gimplify.c (gimplify_save_expr): When in SSA form allow
18192 SAVE_EXPRs to compute to SSA vars.
18193
18194 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18195
18196 PR target/85582
18197 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18198 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18199 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
18200 clobber operands[2], instead use a new pseudo. Formatting fixes.
18201
18202 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
18203
18204 PR tree-optimization/85586
18205 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
18206 exit early for statements in the same group if the accesses are
18207 not strided.
18208
18209 2018-05-02 Tom de Vries <tom@codesourcery.com>
18210
18211 PR lto/85451
18212 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
18213 error message.
18214
18215 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
18216
18217 PR tree-optimization/85143
18218 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
18219
18220 2018-05-01 Tom de Vries <tom@codesourcery.com>
18221
18222 PR lto/85451
18223 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
18224 not found" error message.
18225
18226 2018-05-01 Tom de Vries <tom@codesourcery.com>
18227
18228 PR other/83786
18229 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
18230 * vec.c (test_ordered_remove_if): New function.
18231 (vec_c_tests): Call test_ordered_remove_if.
18232 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
18233 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
18234 * tree-vect-patterns.c (vect_pattern_recog_1): Use
18235 VEC_ORDERED_REMOVE_IF.
18236
18237 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
18238
18239 PR tree-optimization/82665
18240 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
18241 pointer subtraction where arguments come from a memchr call.
18242
18243 2018-05-01 Jakub Jelinek <jakub@redhat.com>
18244
18245 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
18246 --push-state --as-needed and --pop-state instead of --as-needed and
18247 --no-as-needed if ld supports it.
18248 * configure: Regenerated.
18249
18250 PR web/85578
18251 * doc/install.texi2html: Replace _002d with - and _002a with * in
18252 generated html files using sed.
18253
18254 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18255
18256 PR c++/85523
18257 * gcc-rich-location.c (blank_line_before_p): New function.
18258 (use_new_line): New function.
18259 (gcc_rich_location::add_fixit_insert_formatted): New function.
18260 * gcc-rich-location.h
18261 (gcc_rich_location::add_fixit_insert_formatted): New function.
18262
18263 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18264
18265 * selftest.c (assert_streq): Rename "expected" and "actual" to
18266 "val1" and "val2". Extend NULL-handling to cover both inputs
18267 symmetrically, while still requiring both to be non-NULL for a pass.
18268 * selftest.h (assert_streq): Rename "expected" and "actual" to
18269 "val1" and "val2".
18270 (ASSERT_EQ): Likewise.
18271 (ASSERT_EQ_AT): Likewise.
18272 (ASSERT_KNOWN_EQ): Likewise.
18273 (ASSERT_KNOWN_EQ_AT): Likewise.
18274 (ASSERT_NE): Likewise.
18275 (ASSERT_MAYBE_NE): Likewise.
18276 (ASSERT_MAYBE_NE_AT): Likewise.
18277 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
18278 the assertion to pass.
18279 (ASSERT_STREQ_AT): Likewise.
18280
18281 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18282
18283 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
18284 interaction with -pie.
18285
18286 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18287
18288 * selftest.h: Fix alphabetization of per-source-file selftest
18289 declarations.
18290
18291 2018-04-30 Jason Merrill <jason@redhat.com>
18292
18293 PR c++/61982 - dead stores to destroyed objects.
18294 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
18295 of clobber.
18296
18297 2018-04-30 Jason Merrill <jason@redhat.com>
18298
18299 * tree.c (build_clobber): New.
18300 * tree.h: Declare it.
18301 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
18302
18303 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18304
18305 * diagnostic-show-locus.c (layout::layout): Update for
18306 location_get_source_line returning a char_span.
18307 (struct char_span): Move to input.h.
18308 (struct correction): Update for fields in char_span becoming
18309 private.
18310 (struct source_line): Update for location_get_source_line
18311 returning a char_span.
18312 (layout::print_line): Likewise.
18313 * edit-context.c (edited_file::print_content): Likewise.
18314 (edited_file::print_diff_hunk): Likewise.
18315 (edited_file::print_run_of_changed_lines): Likewise.
18316 (edited_file::get_num_lines): Likewise.
18317 (edited_line::edited_line): Likewise.
18318 * final.c (asm_show_source): Likewise.
18319 * input.c (location_get_source_line): Convert return type
18320 from const char * to char_span, losing the final "line_len"
18321 param.
18322 (dump_location_info): Update for the above.
18323 (get_substring_ranges_for_loc): Likewise. Use a char_span
18324 when handling the literal within the line.
18325 (test_reading_source_line): Update for location_get_source_line
18326 returning a char_span.
18327 * input.h (class char_span): Move here from
18328 diagnostic-show-locus.c, converting from a struct to a class.
18329 Make data members private.
18330 (char_span::operator bool): New.
18331 (char_span::length): New.
18332 (char_span::get_buffer): New.
18333 (char_span::operator[]): New.
18334 (char_span::subspan): Make const.
18335 (char_span::xstrdup): New.
18336 (location_get_source_line): Convert return type from const char *
18337 to char_span, losing the final "line_size" param.
18338
18339 2018-04-30 Jan Hubicka <jh@suse.cz>
18340
18341 * lto-wrapper.c (ltrans_priorities): New static var.
18342 (cmp_priority): New.
18343 (run_gcc): Read priorities and if doing parallel build order
18344 the Makefile by them.
18345
18346 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18347
18348 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
18349
18350 2018-04-30 Richard Biener <rguenther@suse.de>
18351
18352 * tree-cfg.c (verify_address): Remove base argument, add
18353 flag whether to check TREE_ADDRESSABLE and do that.
18354 (verify_expr): Remove.
18355 (verify_types_in_gimple_reference): Add pieces from verify_expr.
18356 (verify_gimple_assign_single): Likewise.
18357 (verify_gimple_switch): Likewise.
18358 (verify_expr_location_1): Dereference tp once. Add (disabled)
18359 piece from verify_expr.
18360 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
18361
18362 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18363
18364 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
18365
18366 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18367
18368 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
18369 (small_data_pattern): Likewise.
18370 (arc_rewrite_small_data): Likewise.
18371 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
18372 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
18373 (get_symbol_alignment): New function.
18374 (legitimate_small_data_address_p): Likewise.
18375 (legitimate_scaled_address): Update, call
18376 legitimate_small_data_address_p.
18377 (output_sdata): New static variable.
18378 (arc_print_operand): Update how we handle small data operands.
18379 (arc_print_operand_address): Likewise.
18380 (arc_legitimate_address_p): Update, use
18381 legitimate_small_data_address_p.
18382 (arc_rewrite_small_data_p): Remove.
18383 (arc_rewrite_small_data_1): Likewise.
18384 (arc_rewrite_small_data): Likewise.
18385 (small_data_pattern): Likewise.
18386 (compact_sda_memory_operand): Update to use
18387 legitimate_small_data_address_p and get_symbol_alignment.
18388 (prepare_move_operands): Don't rewite sdata pattern.
18389 (prepare_extend_operands): Remove.
18390 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
18391 pattern.
18392 (zero_extendqisi2): Likewise.
18393 (zero_extendhisi2): Likewise.
18394 (extendqihi2): Likewise.
18395 (extendqisi2): Likewise.
18396 (extendhisi2): Likewise.
18397 (addsi3): Likewise.
18398 (subsi3): Likewise.
18399 (andsi3): Likewise.
18400 * config/arc/constraints.md (Usd): Change it to memory constraint.
18401
18402 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18403
18404 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
18405 as source of std instructions.
18406 * config/arc/arc.md (movsi_insn): Update pattern predicate to
18407 allow 6-bit constants as source for store instructions.
18408 (movdi_insn): Update instruction pattern to allow 6-bit constants
18409 as source for store instructions.
18410
18411 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18412
18413 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
18414
18415 2018-04-30 Nathan Sidwell <nathan@acm.org>
18416 Sandra Loosemore <sandra@codesourcery.com>
18417
18418 * dumpfile.c (dump_open): Allow '-' for stdout.
18419 * doc/invoke.texi (Developer Options): Document dump filename
18420 determination early. Document stdin/stdout selection.
18421
18422 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
18423
18424 Microblaze Target: PIC data text relative
18425
18426 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
18427 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
18428 Add declaration.
18429 * config/microblaze/microblaze.h (microblaze_constant_address_p):
18430 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
18431 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
18432 New addressing mode for data-text relative position indepenedent code.
18433 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
18434 'ADDRESS_SYMBOLIC_TXT_REL'.
18435 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
18436 (microblaze_legitimate_pic_operand): Exclude function calls from
18437 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
18438 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
18439 addresses cases.
18440 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18441 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18442 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
18443 for 'address + offset'.
18444 (microblaze_expand_prologue): Add new function prologue call for
18445 'r20' assignation.
18446 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
18447 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
18448 table in case of TARGET_PIC_DATA_TEXT_REL.
18449 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
18450 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
18451 Add new macros 'UNSPEC_TEXT',
18452 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
18453 + exclude function calls from 'UNSPEC_PLT' in case of data text
18454 relative mode.
18455 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18456 new target hook for generating address diff vector tables in case of
18457 flag_pic.
18458 * doc/tm.texi : Regenerate.
18459 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
18460 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
18461 of addr diff vector generation.
18462 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18463 target hook definition.
18464 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
18465 Add default function for generate_pic_addr_diff_vec -> flag_pic.
18466 * doc/invoke.texi (Add new pic option): Add new microblaze pic
18467 option for data text relative.
18468
18469 2018-04-30 Richard Biener <rguenther@suse.de>
18470
18471 * tree-chrec.h (evolution_function_is_constant_p): Remove
18472 redundant check.
18473 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
18474
18475 2018-04-30 Richard Biener <rguenther@suse.de>
18476
18477 PR bootstrap/85571
18478 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
18479
18480 2018-04-30 Richard Biener <rguenther@suse.de>
18481
18482 PR tree-optimization/28364
18483 PR tree-optimization/85275
18484 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
18485 copying first exit test.
18486
18487 2018-04-28 Mark Wielaard <mark@klomp.org>
18488
18489 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
18490 dwarf_version >= 5.
18491 (dwarf_AT): Handle DW_AT_addr_base.
18492 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
18493
18494 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
18495
18496 PR target/84431
18497 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
18498 (*ashl<dwi>3_doubleword_mask_1): Ditto.
18499 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
18500 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
18501
18502 2018-04-28 Richard Biener <rguenther@suse.de>
18503
18504 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
18505 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
18506 to reflect use. Only add interesting stmts.
18507
18508 2018-04-27 Martin Jambor <mjambor@suse.cz>
18509
18510 PR ipa/85549
18511 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
18512 the jump function allows for passing through aggregate values.
18513
18514 2018-04-27 David Malcolm <dmalcolm@redhat.com>
18515
18516 * input.h (in_system_header_at): Convert from macro to inline
18517 function.
18518 (from_macro_expansion_at): Likewise.
18519 (from_macro_definition_at): Likewise.
18520
18521 2018-04-27 Jeff Law <law@redhat.com>
18522
18523 * config.gcc: Mark tile* targets as deprecated/obsolete.
18524
18525 2018-04-27 Richard Biener <rguenther@suse.de>
18526
18527 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
18528 fix for ILP32.
18529
18530 2018-04-27 Richard Biener <rguenther@suse.de>
18531
18532 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
18533
18534 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
18535
18536 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
18537 with Yd constraint. Set "preferred_for_speed" attribute from
18538 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
18539 with Yd constraint.
18540 (*movdi_internal): Ditto.
18541 (movti_interunit splitters): Remove
18542 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
18543 (movdi_interunit splitters): Ditto.
18544 * config/i386/constraints.md (Ye): Remove.
18545 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
18546
18547 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18548
18549 PR target/85512
18550 * config/aarch64/constraints.md (Usg): Limit to 31.
18551 (Usj): Limit to 63.
18552
18553 2018-04-27 Jakub Jelinek <jakub@redhat.com>
18554
18555 PR tree-optimization/85529
18556 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
18557 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
18558 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
18559 zero extension or masking of the MSB bit.
18560 (optimize_range_tests): Add FIRST_BB argument, pass it through
18561 to optimize_range_tests_var_bound.
18562 (maybe_optimize_range_tests, reassociate_bb): Adjust
18563 optimize_range_tests callers.
18564
18565 2018-04-26 Richard Biener <rguenther@suse.de>
18566 Jakub Jelinek <jakub@redhat.com>
18567
18568 * cgraph.h (symbol_table): Just declare debug method here.
18569 * symtab.c (symbol_table::debug): Define.
18570
18571 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
18572
18573 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
18574
18575 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
18576
18577 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
18578 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
18579 (*movdi_internal): Substitute Yi and Yj constraint with x
18580 and Ym and Yn constraint with y constraint. Update "isa"
18581 attribute and set "preferred_for_speed" attribute from
18582 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
18583 (*movsi_internal): Ditto.
18584 (*movdf_internal): Ditto.
18585 (*movsf_internal): Ditto.
18586 (*zero_extendsidi2): Ditto.
18587 * config/i386/sse.md (vec_set<mode>_0): Ditto.
18588 (sse2_loadld): Ditto.
18589 (*vec_extract<ssevecmodelower>_0): Ditto.
18590 (*vec_extractv4si_0_zext_sse4): Ditto.
18591 (vec_concatv2di): Ditto.
18592 (*vec_dup<mode>): Ditto.
18593 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
18594 * config/i386/constraints.md (Yi): Remove.
18595 (Yj): Remove.
18596 (Ym): Remove.
18597 (Yn): Remove.
18598
18599 2018-04-26 Nathan Sidwell <nathan@acm.org>
18600
18601 * dumpfile.c (dump_open): New.
18602 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
18603 (dump_finish): Detect stdio/stderr by value not name.
18604
18605 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
18606
18607 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
18608
18609 2018-04-26 Tom de Vries <tom@codesourcery.com>
18610
18611 PR target/84952
18612 * config/nvptx/nvptx.c (verify_neutering_jumps)
18613 (verify_neutering_labels): New function
18614 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
18615
18616 2018-04-26 Tom de Vries <tom@codesourcery.com>
18617
18618 PR target/84025
18619 * config/nvptx/nvptx.c (needs_neutering_p): New function.
18620 (nvptx_single): Use needs_neutering_p to skip over insns that do not
18621 need neutering.
18622
18623 2018-04-26 Richard Biener <rguenther@suse.de>
18624 Tom de Vries <tom@codesourcery.com>
18625
18626 PR lto/85422
18627 * lto-streamer-out.c (output_function): Fixup loops if required to match
18628 discovery done in the reader.
18629
18630 2018-04-26 Richard Biener <rguenther@suse.de>
18631
18632 PR tree-optimization/85116
18633 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
18634 have a loop exit from the single latch predecessor. Remove
18635 case of header with just condition.
18636 (ch_base::copy_headers): Exclude infinite loops from any
18637 processing.
18638 (pass_ch::execute): Record exits.
18639
18640 2018-04-26 Richard Biener <rguenther@suse.de>
18641
18642 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
18643 prologue cost vector and pass it to vect_get_load_cost.
18644 (vect_get_peeling_costs_all_drs): Likewise.
18645 (vect_peeling_hash_get_lowest_cost): Likewise.
18646 (vect_enhance_data_refs_alignment): Likewise.
18647
18648 2018-04-26 Richard Biener <rguenther@suse.de>
18649
18650 PR middle-end/85450
18651 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
18652 checking of integer<->pointer conversions.
18653 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
18654 sign-/zero-extending pointer types.
18655 (expand_omp_for_static_chunk): Likewise.
18656
18657 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
18658 Jean Lee <xiaoyur347@gmail.com>
18659
18660 * config/mips/mips.c (mips_asan_shadow_offset): New function.
18661 (TARGET_ASAN_SHADOW_OFFSET): Define.
18662 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
18663 true for -fsanitize=address.
18664
18665 2018-04-25 Mark Wielaard <mark@klomp.org>
18666
18667 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
18668 shorter ones.
18669
18670 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18671
18672 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
18673 than "alu", remove explicit "memory" and "imm_disp" attributes.
18674 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
18675
18676 PR middle-end/85414
18677 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
18678 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
18679 gen_lowpart_no_emit.
18680
18681 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
18682
18683 PR target/85473
18684 * config/i386/i386.c (ix86_expand_builtin): Change memory
18685 operand to XI, extend p0 to Pmode.
18686 * config/i386/i386.md: Change unspec volatile and operand
18687 1 mode to XI, change operand 0 mode to P.
18688
18689 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18690
18691 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
18692 GET_MODE_MASK before any checking.
18693 (nds32_can_use_bset_p): Likewise.
18694 (nds32_can_use_btgl_p): Likewise.
18695
18696 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18697
18698 * config/nds32/nds32-doubleword.md: New define_split pattern for
18699 illegal register number.
18700
18701 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18702
18703 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
18704
18705 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18706
18707 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
18708
18709 2018-04-25 Richard Biener <rguenther@suse.de>
18710
18711 * lto-streamer.h (LTO_major_version): Bump to 8.
18712
18713 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18714
18715 * BASE-VER: Set to 9.0.0.
18716
18717 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
18718
18719 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
18720 in __abskf2 and __powikf2.
18721
18722 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18723
18724 PR target/85512
18725 * config/aarch64/constraints.md (Usg, Usj): New constraints.
18726 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
18727 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
18728 Use the above on operand 2. Reindent.
18729 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
18730
18731 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18732
18733 PR target/85485
18734 * common/config/i386/i386-common.c (ix86_handle_option): Don't
18735 handle OPT_mcet.
18736 * config/i386/i386.opt (mcet): Removed.
18737 * doc/install.texi: Remove -mcet documentation.
18738 * doc/invoke.texi: Likewise.
18739
18740 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18741
18742 PR target/85485
18743 * doc/install.texi: Remove -mcet from bootstrap-cet.
18744
18745 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18746
18747 PR target/85511
18748 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
18749 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
18750 if TARGET_64BIT.
18751
18752 PR target/85503
18753 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
18754 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
18755 containing a CONST_VECTOR.
18756
18757 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
18758
18759 * doc/install.texi: Update newlib dependency for nvptx.
18760
18761 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18762
18763 PR target/85508
18764 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
18765 instead of INTVAL when shifting x left.
18766
18767 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
18768
18769 PR tree-optimization/85478
18770 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
18771 vect_grouped_store_supported for single element vectors.
18772
18773 2018-04-24 Richard Biener <rguenther@suse.de>
18774
18775 PR target/85491
18776 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
18777 load cost increase to the case of non-constant step.
18778
18779 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18780
18781 PR target/84828
18782 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
18783 destination if any_malformed_asm.
18784
18785 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
18786
18787 PR middle-end/85496
18788 * expr.c (store_field): In the bitfield case, if the value comes from
18789 a function call and is returned in registers by means of a PARALLEL,
18790 do not change the mode of the temporary unless BLKmode and VOIDmode.
18791
18792 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
18793
18794 PR rtl-optimization/85423
18795 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
18796 dependencies to debug insns when the previous insn is non-debug.
18797
18798 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18799
18800 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
18801 enums into a single definition.
18802 (fls): Fix predicates and printing.
18803 (seti): Likewise.
18804
18805 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18806
18807 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
18808 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
18809 and short u6 immediate.
18810 (check_if_valid_sleep_operand): Remove.
18811 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
18812
18813 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18814
18815 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
18816 flag_always_save_lp condition.
18817 * config/nds32/nds32.opt (malways-save-lp): New option.
18818
18819 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18820
18821 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
18822 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
18823 * config/nds32/nds32.h
18824 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
18825 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
18826
18827 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18828
18829 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
18830 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
18831
18832 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18833 Chung-Ju Wu <jasonwucj@gmail.com>
18834
18835 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
18836 Declare.
18837 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
18838 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
18839
18840 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18841
18842 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
18843
18844 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18845
18846 * config/nds32/nds32-protos.h (nds32_data_alignment,
18847 nds32_local_alignment): Declare.
18848 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
18849 nds32_local_alignment): New functions.
18850 (TARGET_CONSTANT_ALIGNMENT): Define.
18851 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
18852
18853 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18854
18855 * config/nds32/nds32.c
18856 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
18857 (TARGET_MODES_TIEABLE_P): Likewise.
18858
18859 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18860
18861 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
18862 level Ofast and Og.
18863
18864 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
18865 Chung-Ju Wu <jasonwucj@gmail.com>
18866
18867 * config/nds32/constants.md (unspec_volatile_element): Add enum values
18868 for unaligned access.
18869 * config/nds32/nds32-intrinsic.c: Implementation of expanding
18870 unaligned access.
18871 * config/nds32/nds32-intrinsic.md: Likewise.
18872 * config/nds32/nds32_intrinsic.h: Likewise.
18873 * config/nds32/nds32.h (nds32_builtins): Likewise.
18874 * config/nds32/nds32.opt (munaligned-access): New option.
18875 * config/nds32/nds32.c (nds32_asm_file_start): Display
18876 flag_unaligned_access status.
18877
18878 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
18879
18880 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
18881 -mno-relax is present.
18882 * config/riscv/linux.h (LINK_SPEC): Ditto.
18883
18884 2018-04-20 Martin Sebor <msebor@redhat.com>
18885
18886 PR c/85365
18887 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
18888 for null pointers.
18889 (gimple_fold_builtin_stxcpy_chk): Same.
18890 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
18891
18892 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
18893
18894 PR target/85456
18895 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
18896 __powikf2 when long double is IEEE 128-bit.
18897
18898 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
18899
18900 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
18901 step to make sure stack always aligned.
18902
18903 2018-04-20 Carl Love <cel@us.ibm.com>
18904
18905 PR target/83402
18906 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
18907 size check for arg0.
18908
18909 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
18910 Tom de Vries <tom@codesourcery.com>
18911
18912 PR target/85445
18913 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
18914 Emit insns for calls too.
18915 (nvptx_find_par): Always look for worker-level predecessor insn.
18916 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
18917 calls.
18918 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
18919 (nvptx_process_pars): Propagate frames for calls.
18920
18921 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
18922
18923 PR target/85469
18924 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
18925 Removed.
18926 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
18927 (ix86_handle_option): Don't handle OPT_mibt.
18928 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
18929 __SHSTK__.
18930 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
18931 has_ibt and ibt.
18932 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
18933 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
18934 (ix86_target_macros): Define __CET__ with flag_cf_protection
18935 for -fcf-protection.
18936 * config/i386/i386.c (isa2_opts): Remove -mibt.
18937 * config/i386/i386.h (TARGET_IBT): Removed.
18938 (TARGET_IBT_P): Likewise.
18939 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
18940 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
18941 * config/i386/i386.opt (mcet): Update help message.
18942 (mshstk): Likewise.
18943 (mibt): Removed.
18944 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
18945 -mcet as an alias for -mshstk.
18946
18947 2018-04-20 Richard Biener <rguenther@suse.de>
18948
18949 PR middle-end/85475
18950 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
18951 complexity by forcing a single use of the multiply operand.
18952
18953 2018-04-20 Martin Jambor <mjambor@suse.cz>
18954
18955 ipa/85449
18956 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
18957 recursion dependency to only apply to non-clones.
18958
18959 2018-04-20 Martin Jambor <mjambor@suse.cz>
18960
18961 ipa/85447
18962 * ipa-cp.c (create_specialized_node): Check that clones of
18963 self-recursive edges exist during IPA-CP.
18964
18965 2018-04-19 Toon Moene <toon@moene.org>
18966
18967 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
18968 by -O3.
18969
18970 2018-04-19 Jakub Jelinek <jakub@redhat.com>
18971
18972 PR tree-optimization/85467
18973 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
18974 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
18975 VECTOR_CST element to type.
18976
18977 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
18978
18979 PR target/85397
18980 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
18981 * config/i386/i386.md (builtin_setjmp_setup): Removed.
18982 (builtin_longjmp): Likewise.
18983 (save_stack_nonlocal): New pattern.
18984 (restore_stack_nonlocal): Likewise.
18985
18986 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
18987
18988 PR target/85404
18989 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
18990 Replace ASM_OUTPUT_LABEL with fprintf.
18991
18992 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
18993
18994 PR target/85417
18995 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
18996 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
18997 * config/i386/i386-c.c (ix86_target_macros_internal): Also
18998 define __IBT__ and __SHSTK__ for -fcf-protection.
18999 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
19000 TARGET_IBT.
19001 (ix86_trampoline_init): Likewise.
19002 (x86_output_mi_thunk): Likewise.
19003 (ix86_notrack_prefixed_insn_p): Likewise.
19004 (ix86_option_override_internal): Don't disallow -fcf-protection.
19005 * config/i386/i386.md (rdssp<mode>): Also enable for
19006 -fcf-protection.
19007 (incssp<mode>): Likewise.
19008 (nop_endbr): Likewise.
19009 * config/i386/i386.opt (mcet): Change help message to built-in
19010 functions only.
19011 (mibt): Likewise.
19012 (mshstk): Likewise.
19013 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
19014 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
19015 enable CET built-in functions.
19016
19017 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
19018
19019 * common/config/i386/i386-common.c
19020 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
19021 OPTION_MASK_ISA_MOVDIRI_UNSET,
19022 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
19023 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
19024 * config.gcc (movdirintrin.h): New header.
19025 * config/i386/cpuid.h (bit_MOVDIRI,
19026 bit_MOVDIR64B): New bits.
19027 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
19028 and -mmvodir64b.
19029 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
19030 (VOID, PVOID, PCVOID)): New function types.
19031 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
19032 __builtin_ia32_directstoreu_u64,
19033 __builtin_ia32_movdir64b): New builtins.
19034 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
19035 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
19036 and -mmovdiri.
19037 (ix86_valid_target_attribute_inner_p): Ditto.
19038 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
19039 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
19040 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
19041 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
19042 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
19043 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
19044 (movdiri<mode>, movdir64b_<mode>): New.
19045 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
19046 * config/i386/immintrin.h: Include movdirintrin.h.
19047 * config/i386/movdirintrin.h: New file.
19048 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
19049
19050 2018-04-19 Richard Biener <rguenther@suse.de>
19051
19052 PR middle-end/85455
19053 * cfg.c (clear_bb_flags): When loop state says we have
19054 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
19055
19056 2018-04-19 Richard Biener <rguenther@suse.de>
19057
19058 PR tree-optimization/84737
19059 * tree-vect-data-refs.c (vect_copy_ref_info): New function
19060 copying restrict info.
19061 (vect_setup_realignment): Use it.
19062 * tree-vectorizer.h (vect_copy_ref_info): Declare.
19063 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
19064 the first DR to all generated stores.
19065 (vectorizable_load): Likewise for loads.
19066
19067 2018-04-19 Jakub Jelinek <jakub@redhat.com>
19068
19069 PR tree-optimization/85446
19070 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
19071 the integral and pointer types to have the same precision.
19072
19073 * doc/install.texi: Document --disable-cet being the default and
19074 --enable-cet=auto.
19075
19076 2018-04-18 Martin Liska <mliska@suse.cz>
19077
19078 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
19079 style.
19080
19081 2018-04-18 Martin Liska <mliska@suse.cz>
19082
19083 Revert
19084 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
19085
19086 PR ipa/83983
19087 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
19088 arguments if they are comparable.
19089
19090 2018-04-18 Martin Liska <mliska@suse.cz>
19091
19092 Revert
19093 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
19094
19095 PR lto/84805
19096 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
19097 incomplete types.
19098
19099 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
19100
19101 PR target/85388
19102 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
19103 ENDBR after calling __morestack.
19104
19105 2018-04-18 David Malcolm <dmalcolm@redhat.com>
19106
19107 PR jit/85384
19108 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
19109 by using gcc_base_ver to generate a gcc_driver_version, and use
19110 it when generating GCC_DRIVER_NAME.
19111 * configure: Regenerate.
19112
19113 2018-04-18 Jakub Jelinek <jakub@redhat.com>
19114
19115 PR target/81084
19116 * config.gcc: Obsolete powerpc*-*-*spe*.
19117
19118 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19119
19120 PR debug/84637
19121 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
19122 (stabstr_D): Change type of unum from unsigned int to
19123 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
19124 type.
19125
19126 2018-04-17 Jim Wilson <jimw@sifive.com>
19127
19128 PR 84856
19129 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
19130 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
19131 Set arg_pointer_offset after using pretend_args_size.
19132
19133 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19134
19135 PR rtl-optimization/85431
19136 * dse.c (record_store): Ignore zero width stores.
19137
19138 PR sanitizer/85230
19139 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
19140 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
19141 __builtin_stack_restore rather than after it.
19142 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
19143 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
19144 argument instead of virtual_dynamic_stack_rtx.
19145
19146 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
19147
19148 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
19149 New prototype.
19150 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
19151 Add note to error message to explain internal mapping of overloaded
19152 built-in function name to non-overloaded built-in function name.
19153 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
19154 function.
19155
19156 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
19157
19158 PR target/85424
19159 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
19160 where the inputs overlap with the output.
19161
19162 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19163
19164 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
19165 (=v, v) alternative and explicit "memory" attribute.
19166 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
19167 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19168 attributes.
19169 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
19170 "sselog1" type instead of "sselog".
19171 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
19172 "sselog". Remove explicit "memory" attribute.
19173 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
19174 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19175 attributes.
19176 (vec_extract_hi_v32hi): Merge all alternatives into one, use
19177 "sselog1" type instead of "sselog". Remove explicit "memory"
19178 attribute.
19179 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
19180 use "sselog1" type instead of "sselog". Remove explicit "memory"
19181 attribute.
19182 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
19183 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19184 attributes.
19185 (vec_extract_hi_v64qi): Merge all alternatives into one, use
19186 "sselog1" type instead of "sselog". Remove explicit "memory"
19187 attribute.
19188 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
19189 use "sselog1" type instead of "sselog". Remove explicit "memory"
19190 attribute.
19191
19192 PR target/85430
19193 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
19194
19195 PR middle-end/85414
19196 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
19197 on a SUBREG.
19198
19199 2018-04-17 Martin Jambor <mjambor@suse.cz>
19200
19201 PR ipa/85421
19202 * ipa-cp.c (create_specialized_node): Call
19203 expand_all_artificial_thunks if necessary.
19204
19205 2018-04-17 Martin Liska <mliska@suse.cz>
19206
19207 PR lto/85405
19208 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
19209 in message, remote space in between '_G' and '('.
19210
19211 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19212
19213 PR target/85281
19214 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
19215 avx512f_vmcmp<mode>3<round_saeonly_name>,
19216 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
19217 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
19218 avx512f_rndscale<mode><round_saeonly_name>,
19219 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
19220 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
19221 Use %<iptr>2 instead of %2 for -masm=intel.
19222 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
19223 avx512f_vcvttss2usi<round_saeonly_name>,
19224 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
19225 -masm=intel.
19226 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
19227 avx512f_vcvttsd2usi<round_saeonly_name>,
19228 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
19229 Use %q1 instead of %1 for -masm=intel.
19230 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
19231 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
19232 of %3 for -masm=intel.
19233 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
19234 -masm=intel.
19235 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
19236 -masm=intel.
19237 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
19238 -masm=intel.
19239 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
19240 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
19241 %g1.
19242 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
19243 -masm=intel.
19244 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
19245 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
19246 %g1 and one with %0 and %1.
19247 (avx512er_vmrcp28<mode><round_saeonly_name>,
19248 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
19249 %1 for -masm=intel.
19250 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
19251 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
19252 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
19253 of %0 and %{%4%} for -masm=intel.
19254 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
19255 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
19256 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
19257 order of %0 and %{%5%}%{z%} for -masm=intel.
19258
19259 2018-04-17 Jan Hubicka <jh@suse.cz>
19260
19261 PR lto/85405
19262 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
19263
19264 2018-04-17 Martin Liska <mliska@suse.cz>
19265
19266 PR ipa/85329
19267 * multiple_target.c (create_dispatcher_calls): Set apostrophes
19268 for target_clone error message. Make default implementation
19269 clone to be a local declaration.
19270 (separate_attrs): Add new argument and check for an empty
19271 string.
19272 (expand_target_clones): Handle it.
19273 (ipa_target_clone): Make redirection just for target_clones
19274 functions.
19275
19276 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
19277 Tom de Vries <tom@codesourcery.com>
19278
19279 PR middle-end/84955
19280 * omp-expand.c (expand_oacc_for): Add dummy false branch for
19281 tiled basic blocks without omp continue statements.
19282
19283 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
19284
19285 PR target/83660
19286 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
19287 vec_extract expression as having side effects to make sure it gets
19288 a cleanup point.
19289
19290 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
19291
19292 PR target/85403
19293 * config/i386/i386.c (get_builtin_code_for_version): Check
19294 error_mark_node.
19295
19296 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
19297
19298 PR target/84331
19299 * config.gcc: Support "skylake".
19300 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
19301 PROCESSOR_SKYLAKE.
19302 * config/i386/i386.c (m_SKYLAKE): Define.
19303 (processor_target_table): Add "skylake".
19304 (ix86_option_override_internal): Add "skylake".
19305 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
19306 PROCESSOR_CANNONLAKE.
19307 (get_builtin_code_for_version): Fix priority for
19308 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
19309 PROCESSOR_SKYLAKE-AVX512.
19310 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
19311 (processor_type): Add PROCESSOR_SKYLAKE.
19312
19313 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
19314 Jason Merrill <jason@redhat.com>
19315
19316 PR c++/85112
19317 * convert.c (convert_to_integer_1): Use direct recursion for
19318 enumeral types and types with a precision less than the number
19319 of bits in their mode.
19320
19321 2018-04-16 Julia Koval <julia.koval@intel.com>
19322
19323 PR target/84413
19324 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
19325 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
19326
19327 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
19328
19329 PR target/85293
19330 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
19331 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
19332 and -mno-direct-move.
19333
19334 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
19335
19336 PR target/83402
19337 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
19338 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
19339 Ensure negative shifts result in {0}.
19340
19341 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
19342
19343 PR rtl-optimization/79916
19344 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
19345 regs (if any) to define how to gnerate SD moves when LRA is in
19346 progress.
19347
19348 2018-04-13 Jakub Jelinek <jakub@redhat.com>
19349
19350 PR rtl-optimization/85393
19351 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
19352 * except.c (expand_dw2_landing_pad_for_region): Make static.
19353 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
19354 a label and unconditional jump to old_bb, rather than
19355 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
19356 basic block.
19357
19358 PR rtl-optimization/85376
19359 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
19360 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
19361 instead of a specific value.
19362
19363 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19364 Bin Cheng <bin.cheng@arm.com>
19365
19366 PR tree-optimization/82965
19367 PR tree-optimization/83991
19368 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
19369 by_profile_only parameter.
19370 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
19371 information if the loop was predicted to iterate too many times.
19372 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
19373
19374 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19375
19376 PR lto/71991
19377 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
19378 always inline.
19379
19380 2018-04-13 Martin Liska <mliska@suse.cz>
19381 Jakub Jelinek <jakub@redhat.com>
19382
19383 PR middle-end/81657
19384 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
19385 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
19386 * builtins.c (expand_builtin_memory_copy_args): Use
19387 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
19388 handle dest_addr == pc_rtx.
19389
19390 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
19391
19392 PR target/85291
19393 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
19394 asked to not generate direct moves.
19395 (fix_trunc<mode>si2_stfiwx): Similar.
19396 (fix_trunc<mode>si2_internal): Similar.
19397
19398 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19399
19400 PR debug/83157
19401 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
19402 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
19403 lookup if dest in some wider mode is known to be const0_rtx and
19404 if so, record permanent equivalence for it to be ZERO_EXTEND of
19405 the narrower mode destination.
19406
19407 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19408
19409 * lto-streamer-out.c (output_function): Revert 259346.
19410 * omp-expand.c (expand_oacc_for): Likewise.
19411
19412 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
19413
19414 PR rtl-optimization/85354
19415 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
19416 * sel-sched.c (sel_global_init): ... here.
19417
19418 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
19419
19420 PR target/85238
19421 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
19422 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
19423 mode for PE-COFF targets.
19424 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
19425 (i386_pe_asm_lto_end): Likewise.
19426 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
19427 (TARGET_ASM_LTO_END): Likewise.
19428 * config/i386/winnt.c (saved_debug_info_level): New static variable.
19429 (i386_pe_asm_lto_start): New function.
19430 (i386_pe_asm_lto_end): Likewise.
19431
19432 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19433 Richard Biener <rguenther@suse.de>
19434
19435 PR middle-end/84955
19436 * lto-streamer-out.c (output_function): Fix CFG loop state before
19437 streaming out.
19438 * omp-expand.c (expand_oacc_for): Handle calls to internal
19439 functions like regular functions.
19440
19441 2018-04-12 Richard Biener <rguenther@suse.de>
19442
19443 PR lto/85371
19444 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
19445 for the early LTO debug to properly generate references to it
19446 during DIE emission. Do not re-use that for the skeleton for
19447 split-dwarf.
19448 (dwarf2out_early_finish): Likewise.
19449
19450 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19451
19452 PR target/85328
19453 * config/i386/sse.md
19454 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
19455 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
19456 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
19457 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
19458 and output is a reg, avoid creating invalid lowpart subreg, but
19459 instead split into a 512-bit move. Don't split if not AVX512VL,
19460 input is xmm16+ reg and output is a mem.
19461 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
19462 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
19463 xmm16+ reg and output is a mem.
19464
19465 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
19466
19467 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
19468 also for flag_dwarf2_cfi_asm.
19469
19470 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19471
19472 PR rtl-optimization/85342
19473 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
19474 a bool scalar var inside of the loop instead. Don't try to update
19475 recog_data.operand after failed apply_change_group.
19476
19477 2018-04-12 Tom de Vries <tom@codesourcery.com>
19478
19479 PR target/85296
19480 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
19481 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
19482 array with flexible array member as array without given dimension.
19483 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
19484 argument for undefined param to true.
19485
19486 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
19487
19488 PR target/85321
19489 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19490 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
19491 from PowerPC section.
19492 * config/rs6000/sysv4.opt (mcall-): Improve help text.
19493 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
19494 help text that is too long.
19495 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
19496 help text that is too long.
19497 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
19498 help text that is too long.
19499
19500 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
19501
19502 * config/alpha/alpha.md (stack_probe_internal): Rename
19503 from "probe_stack". Update all callers.
19504
19505 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19506
19507 PR rtl-optimization/84566
19508 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
19509 sched_macro_fuse_insns.
19510
19511 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19512
19513 PR target/84301
19514 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
19515 (compute_block_dependences): ... from here.
19516
19517 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19518
19519 PR tree-optimization/85331
19520 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
19521 from int to HOST_WIDE_INT.
19522
19523 2018-04-11 Martin Jambor <mjambor@suse.cz>
19524
19525 PR ipa/84149
19526 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
19527 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
19528 not the same as the source val.
19529 (cgraph_edge_brings_value_p): New parameter.
19530 (gather_edges_for_value): Pass destination value to
19531 cgraph_edge_brings_value_p.
19532 (perhaps_add_new_callers): Likewise.
19533 (get_info_about_necessary_edges): Likewise and exclude values brought
19534 only by self-recursive edges.
19535 (create_specialized_node): Redirect only clones of self-calling edges.
19536 (+self_recursive_pass_through_p): New function.
19537 (find_more_scalar_values_for_callers_subset): Use it.
19538 (find_aggregate_values_for_callers_subset): Likewise.
19539 (known_aggs_to_agg_replacement_list): Removed.
19540 (decide_whether_version_node): Re-calculate known constants for all
19541 remaining context clones.
19542
19543 2018-04-11 Richard Biener <rguenther@suse.de>
19544
19545 PR lto/85339
19546 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
19547 from early DWARF output.
19548 (dwarf2out_early_finish): Output line info unconditionally into
19549 early DWARF and add reference to it.
19550
19551 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19552
19553 PR target/85281
19554 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
19555 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
19556 other than V2DFmode using iptr mode attribute.
19557 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
19558
19559 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19560
19561 PR rtl-optimization/84659
19562 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
19563
19564 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19565
19566 PR debug/85302
19567 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
19568 SIZEP is NULL.
19569 (output_loc_list): Pass address of a dummy size variable even in the
19570 locview handling loop.
19571 (index_location_lists): Add comment on why skip_loc_list_entry can't
19572 call size_of_locs.
19573
19574 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
19575
19576 PR target/85261
19577 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
19578 into register.
19579
19580 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
19581
19582 PR target/85321
19583 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19584 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
19585 and -mstring-compare-inline-limit.
19586
19587 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19588
19589 PR target/85287
19590 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
19591 for stack clash protection in a register whenever we need it to be in
19592 a register.
19593
19594 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19595
19596 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
19597 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
19598
19599 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19600
19601 PR target/85321
19602 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
19603 the help text.
19604 (mlong-double-): Ditto.
19605 * config/rs6000/sysv4.opt (msdata=): Ditto.
19606 (mtls-size=): Ditto.
19607
19608 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
19609
19610 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
19611 erroneous entries for
19612 "vector int vec_ldl (int, long int *)", and
19613 "vector unsigned int vec_ldl (int, unsigned long int *)".
19614 Add comments and entries for
19615 "vector bool char vec_ldl (int, bool char *)",
19616 "vector bool short vec_ldl (int, bool short *)",
19617 "vector bool int vec_ldl (int, bool int *)",
19618 "vector bool long long vec_ldl (int, bool long long *)",
19619 "vector pixel vec_ldl (int, pixel *)",
19620 "vector long long vec_ldl (int, long long *)",
19621 "vector unsigned long long vec_ldl (int, unsigned long long *)".
19622 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
19623 type tree bool_long_long_type_node and correct definition of
19624 bool_V2DI_type_node to make reference to this new type tree.
19625 (rs6000_mangle_type): Replace erroneous reference to
19626 bool_long_type_node with bool_long_long_type_node.
19627 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
19628 comments to emphasize sign distinctions for char and int types and
19629 replace RS6000_BTI_bool_long constant with
19630 RS6000_BTI_bool_long_long constant. Also add comment to restrict
19631 use of RS6000_BTI_pixel.
19632 (bool_long_type_node): Remove this macro definition.
19633 (bool_long_long_type_node): New macro definition
19634
19635 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19636
19637 PR rtl-optimization/85300
19638 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
19639 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
19640 simplify_unary_operation fails.
19641
19642 2018-04-10 Martin Liska <mliska@suse.cz>
19643
19644 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
19645 cgraph_edge and ipa_ref.
19646
19647 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19648
19649 PR target/85177
19650 PR target/85255
19651 * config/i386/sse.md
19652 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
19653 computation of the VEC_MERGE selector from mask.
19654 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
19655 Fix decoding of the VEC_MERGE selector into mask.
19656
19657 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19658
19659 PR tree-optimization/85286
19660 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
19661
19662 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19663
19664 * final.c (final_1): Set insn_last_address as well as
19665 insn_current_address.
19666
19667 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
19668
19669 PR target/85173
19670 * explow.c (emit_stack_probe): Call validize_mem on memory location
19671 before passing it to gen_probe_stack. Create address operand and
19672 legitimize it for the probe_stack_address case.
19673
19674 2018-04-09 Jan Hubicka <jh@suse.cz>
19675
19676 PR lto/85078
19677 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
19678 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
19679 * tree.c (free_lang_data_in_type): Fix handling of binfos;
19680 walk basetypes.
19681 (free_lang_data): Rebuild type inheritance graph.
19682
19683 2018-04-09 Martin Sebor <msebor@redhat.com>
19684
19685 * invoke.texi (-finline-small-functions): Mention other optimization
19686 options.
19687 (-findirect-inlining, -fpartial-inlining): Same.
19688 (-finline-functions-called-once): Same.
19689 (-freorder-blocks-and-partition): Same.
19690
19691 2018-04-09 Jan Hubicka <jh@suse.cz>
19692
19693 PR rtl/84058
19694 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
19695 jumps; choose last target that matches the criteria (i.e.
19696 no partition changes for non-crossing jumps).
19697 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
19698 support for redirecting crossing jumps to non-crossing.
19699
19700 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
19701
19702 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
19703 also for naked functions.
19704
19705 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
19706
19707 * config/arc/arc.md (add_shift): New pattern.
19708 (add_shift2): Likewise.
19709 (sub_shift): Likewise.
19710 (sub_shift_cmp0_noout): Likewise.
19711 (compare_si_ashiftsi): Likewise.
19712 (xbfu_cmp0_noout): New combine pattern.
19713 (xbfu_cmp0"): Likewise.
19714 (movsi_set_cc_insn): Place the predicable variant first.
19715 (commutative_binary_cmp0_noout): Remove clobber.
19716 (commutative_binary_cmp0): New pattern.
19717 (noncommutative_binary_cmp0): Likewise.
19718 (noncommutative_binary_cmp0_noout): Likewise.
19719 (noncommutative_binary_comparison_result_used): Removed.
19720 (rsub_cmp0): New pattern.
19721 (rsub_cmp0_noout): Likewise.
19722 (extzvsi): Changed, keep only meaningful variants.
19723 (SQH, SEZ): New iterators.
19724 (SQH_postfix): New mode attribute.
19725 (SEZ_prefix): New code attribute.
19726 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
19727 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
19728 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
19729 of numerical value.
19730 (noncommutative_operator): Check the availability of barrel
19731 shifter option.
19732
19733 2018-04-09 Richard Biener <rguenther@suse.de>
19734
19735 PR tree-optimization/85284
19736 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
19737 Only use the niter constraining form of simple_iv when the exit
19738 is always executed.
19739
19740 2018-04-09 Tom de Vries <tom@codesourcery.com>
19741
19742 PR target/84041
19743 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
19744 (define_expand "*memory_barrier"): New define_expand.
19745 (define_insn "memory_barrier"): New insn.
19746
19747 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19748
19749 PR rtl-optimization/80463
19750 PR rtl-optimization/83972
19751 PR rtl-optimization/83480
19752
19753 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
19754 correct producer for the insn.
19755 (tidy_control_flow): Fixup seqnos in case of debug insns.
19756
19757 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19758
19759 PR rtl-optimization/83913
19760
19761 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
19762 different sched-times when merging exprs.
19763
19764 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19765
19766 PR rtl-optimization/83962
19767
19768 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
19769 tidy_fallthru_edge and tidy_control_flow.
19770
19771 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19772
19773 PR rtl-optimization/83530
19774
19775 * sel-sched.c (force_next_insn): New global variable.
19776 (remove_insn_for_debug): When force_next_insn is true, also leave only
19777 next insn in the ready list.
19778 (sel_sched_region): When the region wasn't scheduled, make another pass
19779 over it with force_next_insn set to 1.
19780
19781 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
19782
19783 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
19784 into tm_file.
19785 * config/nds32/constants.md (unspec_volatile_element): Add enum values
19786 for interrupt control.
19787 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
19788 functions for interrupt control.
19789 * config/nds32/nds32-intrinsic.md: Likewise.
19790 * config/nds32/nds32_intrinsic.h: Likewise.
19791 * config/nds32/nds32.h (nds32_builtins): Likewise.
19792
19793 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19794
19795 * config/nds32/nds32.c (nds32_init_machine_status,
19796 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
19797 strict_aligned_p field.
19798 (nds32_expand_to_rtl_hook): New function.
19799 (TARGET_EXPAND_TO_RTL_HOOK): Define.
19800 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
19801
19802 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19803 Chung-Ju Wu <jasonwucj@gmail.com>
19804
19805 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
19806 * config/nds32/nds32-n7.md: New file.
19807 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
19808 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
19809 pipeline.
19810 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
19811 * config/nds32/nds32.md (pipeline_model): Add n7.
19812 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
19813 * config/nds32/pipelines.md: Include n7 settings.
19814
19815 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19816 Chung-Ju Wu <jasonwucj@gmail.com>
19817
19818 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
19819 * config/nds32/nds32-e8.md: New file.
19820 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
19821 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
19822 pipeline.
19823 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
19824 * config/nds32/nds32.md (pipeline_model): Add e8.
19825 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
19826 * config/nds32/pipelines.md: Include e8 settings.
19827
19828 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19829 Chung-Ju Wu <jasonwucj@gmail.com>
19830
19831 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
19832 * config/nds32/nds32-n8.md: New file.
19833 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
19834 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
19835 pipeline.
19836 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
19837 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
19838 * config/nds32/nds32.md (pipeline_model): Add n8.
19839 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
19840 * config/nds32/pipelines.md: Include n8 settings.
19841
19842 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19843 Chung-Ju Wu <jasonwucj@gmail.com>
19844
19845 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
19846 * config/nds32/nds32-n9-2r1w.md: New file.
19847 * config/nds32/nds32-n9-3r2w.md: New file.
19848 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
19849 nds32_register_ports): New or modify for cpu n9.
19850 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
19851 pipeline.
19852 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
19853 * config/nds32/nds32-utils.c: New file.
19854 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
19855 TARGET_MUL_SLOW): Define.
19856 * config/nds32/nds32.md (pipeline_model): New attribute.
19857 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
19858 New options that support cpu n9.
19859 * config/nds32/pipelines.md: Include n9 settings.
19860 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
19861
19862 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19863
19864 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
19865 information if necessary.
19866 (output_cond_branch_compare_zero): Likewise.
19867 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
19868 (nds32_target_alignment): Refine for alignment.
19869 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
19870 (FUNCTION_BOUNDARY): Modify.
19871 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
19872 align case.
19873 * config/nds32/nds32.opt (malways-align, malign-functions): New.
19874
19875 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
19876
19877 * config/nds32/constants.md (unspec_volatile_element): Add values for
19878 TLB operation and data prefetch.
19879 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
19880 functions for TLB operation and data prefetch.
19881 * config/nds32/nds32-intrinsic.md: Likewise.
19882 * config/nds32/nds32_intrinsic.h: Likewise.
19883 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
19884 (nds32_print_operand): Likewise.
19885 * config/nds32/nds32.h (nds32_builtins): Likewise.
19886
19887 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
19888 Andrew Pinski <pinsika@gcc.gnu.org>
19889
19890 PR middle-end/82976
19891 * match.pd: Use constant_boolean_node of correct type instead of
19892 boolean_true_node or boolean_false_node for simplifying
19893 pointer comparisons to zero.
19894
19895 2018-04-07 Jakub Jelinek <jakub@redhat.com>
19896
19897 PR tree-optimization/80021
19898 * tree.c (verify_type_variant): Make error call in verify_variant_match
19899 translatable and remove final full stop.
19900
19901 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
19902
19903 * config/nds32/constants.md (unspec_volatile_element): Add
19904 UNSPEC_VOLATILE_EH_RETURN.
19905 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
19906 nds32_output_stack_pop): Support dwarf exception handling process.
19907 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
19908 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
19909 exception handling process.
19910 (nds32_compute_stack_frame): Likewise.
19911 (nds32_return_addr_rtx): Likewise.
19912 (nds32_initial_elimination_offset): Likewise.
19913 (nds32_expand_prologue): Likewise.
19914 (nds32_expand_epilogue): Likewise.
19915 (nds32_dynamic_chain_address): New function.
19916 * config/nds32/nds32.h (machine_function): Add fields for dwarf
19917 exception handling.
19918 (DYNAMIC_CHAIN_ADDRESS): Define.
19919 (EH_RETURN_DATA_REGNO): Define.
19920 (EH_RETURN_STACKADJ_RTX): Define.
19921 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
19922 patterns for dwarf exception handling.
19923
19924 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
19925
19926 * config/nds32/nds32.h: Clean up obsolete macros.
19927
19928 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19929
19930 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
19931 Add enum values for particular instructions.
19932 * config/nds32/nds32-intrinsic.c: Implementation of expanding
19933 particular intrinsic functions.
19934 * config/nds32/nds32-intrinsic.md: Likewise.
19935 * config/nds32/nds32_intrinsic.h: Likewise.
19936 * config/nds32/nds32.h (nds32_builtins): Likewise.
19937 * config/nds32/nds32.md (type): Add pbsad and pbsada.
19938 (btst, ave): New patterns for particular instructions.
19939
19940 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19941
19942 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
19943 Add enum values for atomic load/store and memory sync.
19944 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
19945 and memory sync.
19946 * config/nds32/nds32-intrinsic.md: Likewise.
19947 * config/nds32/nds32_intrinsic.h: Likewise.
19948 * config/nds32/nds32.h (nds32_builtins): Likewise.
19949
19950 2018-04-07 Jakub Jelinek <jakub@redhat.com>
19951
19952 PR tree-optimization/85257
19953 * fold-const.c (native_encode_vector): If not all elts could fit
19954 and off is -1, return 0 rather than offset.
19955 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
19956 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
19957 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
19958 adjust buffer in native_interpret_expr call.
19959
19960 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19961
19962 * config/nds32/constants.md (unspec_volatile_element): Add cache
19963 control enum values.
19964 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
19965 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
19966 * config/nds32/nds32.c (nds32_cctl_names): New.
19967 (nds32_print_operand): Handle cache control register names.
19968 * config/nds32/nds32.h (nds32_builtins): New enum values.
19969 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
19970 macros.
19971 * config/nds32/nds32.md (type): Add mmu.
19972 * config/nds32/pipelines.md (simple_insn): Add mmu.
19973
19974 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
19975
19976 * config/nds32/nds32.md (type): Remove call.
19977 * config/nds32/pipelines.md (simple_insn): Likewise.
19978
19979 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19980
19981 * config/nds32/constants.md (unspec_volatile_element): Add
19982 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
19983 UNSPEC_VOLATILE_FMFCFG.
19984 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
19985 description for fmfcfg and fmfcsr.
19986 (bdesc_1arg): Add fmtcsr.
19987 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
19988 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
19989 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
19990 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
19991 unspec_fmfcfg): New patterns.
19992 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
19993 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
19994 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
19995 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
19996 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
19997 __nds32__fmfcfg): Define.
19998
19999 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20000
20001 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
20002 intrinsic register names.
20003 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
20004 intrinsic register enum values and macros.
20005
20006 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20007
20008 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
20009 for load/store addressing form.
20010 (nds32_print_operand_address): Likewise.
20011
20012 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
20013
20014 PR target/85196
20015 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
20016 based on LABEL_REF. Remove useless assertion.
20017 (pic_address_needs_scratch): Fix formatting.
20018 (sparc_legitimize_pic_address): Minor tweaks.
20019 (sparc_delegitimize_address): Adjust assertion accordingly.
20020 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
20021 into symbolic_operand.
20022 (movsi_high_pic_label_ref): Likewise.
20023 (movsi_lo_sum_pic_label_ref): Likewise.
20024 (movdi_pic_label_ref): Likewise.
20025 (movdi_high_pic_label_ref): Likewise.
20026 (movdi_lo_sum_pic_label_ref): Likewise.
20027
20028 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
20029
20030 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
20031 custom LIB_SPEC setup.
20032
20033 2018-04-06 Ruslan Bukin <br@bsdpad.com>
20034 Kito Cheng <kito.cheng@gmail.com>
20035
20036 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
20037 * config/riscv/freebsd.h: New.
20038
20039 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20040
20041 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
20042 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
20043 file.
20044
20045 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20046 Kito Cheng <kito.cheng@gmail.com>
20047
20048 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
20049 nds32_output_call, nds32_symbol_binds_local_p): New functions.
20050 * config/nds32/nds32-protos.h (nds32_output_call,
20051 nds32_output_return): Declare.
20052 * config/nds32/nds32.md: Refine all the call and return patterns.
20053
20054 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20055
20056 PR debug/85252
20057 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
20058 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
20059
20060 PR rtl-optimization/84872
20061 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
20062 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
20063 EDGE_CROSSING edge.
20064
20065 2018-04-06 Tamar Christina <tamar.christina@arm.com>
20066
20067 * expr.c (copy_blkmode_to_reg): Revert 254862.
20068 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
20069
20070 2018-04-06 Richard Biener <rguenther@suse.de>
20071
20072 PR middle-end/85244
20073 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
20074 after seeing a component reference with an adjacent field. Treat
20075 refs to arrays at struct end of external decls similar to
20076 refs to unconstrained commons.
20077
20078 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20079
20080 PR sanitizer/85213
20081 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
20082 look through SAVE_EXPRs with non-side-effects argument. Adjust
20083 recursive calls.
20084 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
20085 save_p here.
20086
20087 2018-04-06 Richard Biener <rguenther@suse.de>
20088
20089 PR middle-end/85180
20090 * alias.c (find_base_term): New wrapper around find_base_term
20091 unwinding CSELIB_VAL_PTR changes.
20092 (find_base_term): Do not restore CSELIB_VAL_PTR during the
20093 recursion.
20094
20095 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
20096
20097 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
20098 instructions.
20099 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
20100 constant definitions.
20101 ("nop"): lr 0,0 -> nopr r0
20102 ("nop_lr0", "nop_lr1"): New insn definitions.
20103
20104 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20105
20106 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
20107 NDS32_V3PUSH_AVAILABLE_P macro.
20108
20109 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
20110 Chung-Ju Wu <jasonwucj@gmail.com>
20111
20112 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
20113 (nds32*-*-*): Add float and fpu_config into supported_defaults.
20114 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
20115 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
20116 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
20117 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
20118 * config/nds32/constraints.md: New constraints and checking for hard
20119 float configuration.
20120 * config/nds32/iterators.md: New mode iterator and attribute for hard
20121 float configuration.
20122 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
20123 patterns.
20124 * config/nds32/nds32-fpu.md: New file.
20125 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
20126 deal with hard float code generation.
20127 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
20128 ARCH_V3S.
20129 (abi_type, float_reg_number): New enum type.
20130 * config/nds32/nds32-predicates.c: New predicates for hard float.
20131 * config/nds32/nds32-protos.h: Declare functions for hard float.
20132 * config/nds32/nds32.c: Implementation for hard float configuration.
20133 * config/nds32/nds32.h: Definitions for hard float configuration.
20134 * config/nds32/nds32.md: Include hard float machine description and
20135 modify patterns for hard float configuration.
20136 * config/nds32/nds32.opt: New options for hard float configuration.
20137 * config/nds32/predicates.md: New predicates for hard float
20138 configuration.
20139
20140 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20141
20142 * common/config/nds32/nds32-common.c
20143 (nds32_option_optimization_table): Enable -mreleax-hint by default.
20144
20145 2018-04-05 Jakub Jelinek <jakub@redhat.com>
20146
20147 PR middle-end/85195
20148 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
20149 CONSTRUCTOR_ELT (ctor, ...)->value.
20150
20151 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
20152
20153 PR target/85193
20154 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
20155
20156 2018-04-05 Tom de Vries <tom@codesourcery.com>
20157
20158 PR target/85204
20159 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
20160 cond jump.
20161
20162 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20163 Kito Cheng <kito.cheng@gmail.com>
20164
20165 * config/nds32/constraints.md (U33): Fine-tune checking condition.
20166 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
20167 * config/nds32/nds32.h (nds32_16bit_address_type): Add
20168 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
20169
20170 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20171 Kito Cheng <kito.cheng@gmail.com>
20172
20173 * config/nds32/constraints.md (Ufe): New memory constraint.
20174 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
20175 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
20176 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
20177 operands.
20178 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
20179 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
20180
20181 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20182
20183 * config/nds32/nds32.md: Use optimize_size in the condition for
20184 alu-shift instructions.
20185
20186 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20187
20188 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
20189
20190 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20191
20192 * config/nds32/nds32.md (negsi2): Refine pattern.
20193
20194 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20195 Chung-Ju Wu <jasonwucj@gmail.com>
20196
20197 * config/nds32/iterators.md (shift_rotate): New code iterator.
20198 (shift): New code attribute.
20199 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
20200 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
20201 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
20202 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
20203 bit-wise operations.
20204 (andsi3, *andsi3): Ditto.
20205 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
20206 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
20207 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
20208 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
20209 nds32_ior_operand, nds32_xor_operand): New predicates.
20210
20211 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20212
20213 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
20214 (addsi3, subsi3): ... this.
20215
20216 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20217
20218 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
20219
20220 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20221
20222 * config/nds32/nds32.md: Adjust indention.
20223
20224 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20225
20226 * config/nds32/nds32.md (feature): New attribute.
20227
20228 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20229
20230 * config/nds32/nds32.md (subtype): New attribute.
20231
20232 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
20233
20234 PR target/85203
20235 * config/arm/arm-builtins.c (arm_expand_builtin): Change
20236 expansion to perform a bitwise AND of the argument followed by a
20237 boolean negation of the result.
20238
20239 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
20240
20241 PR rtl-optimization/84878
20242 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
20243 the basic block. Assert the use reference is not artificial and that
20244 it has an associated insn.
20245
20246 2018-04-04 Michael Matz <matz@suse.de>
20247
20248 * builtins.c (compute_objsize): Pass correct operand
20249 to array_at_struct_end_p.
20250
20251 2018-04-04 Richard Biener <rguenther@suse.de>
20252
20253 PR lto/85176
20254 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
20255 from contexts for DINFO_LEVEL_TERSE and below.
20256
20257 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20258
20259 * config/nds32/nds32-doubleword.md (move_<mode>): Require
20260 resiter_operand condition.
20261 * config/nds32/nds32.md (*move<mode>): Ditto.
20262
20263 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20264 Monk Chiang <sh.chiang04@gmail.com>
20265
20266 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
20267
20268 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20269
20270 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
20271
20272 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20273 Kito Cheng <kito.cheng@gmail.com>
20274
20275 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
20276 nds32_cond_code_str, output_cond_branch,
20277 output_cond_branch_compare_zero, nds32_expand_cbranch,
20278 nds32_expand_cstore, nds32_expand_movcc,
20279 nds32_output_cbranchsi4_equality_zero,
20280 nds32_output_cbranchsi4_equality_reg,
20281 nds32_output_cbranchsi4_equality_reg_or_const_int,
20282 nds32_output_cbranchsi4_greater_less_zero: New functions.
20283 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
20284 nds32_expand_cstore, nds32_expand_movcc,
20285 nds32_output_cbranchsi4_equality_zero,
20286 nds32_output_cbranchsi4_equality_reg,
20287 nds32_output_cbranchsi4_equality_reg_or_const_int,
20288 nds32_output_cbranchsi4_greater_less_zero): Declare.
20289 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
20290 nds32_rimm11s_operand): New predicates.
20291 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
20292 * config/nds32/nds32.md: Rewrite all the branch and conditional move
20293 patterns.
20294
20295 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20296
20297 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
20298 * config/nds32/nds32.md: Ditto.
20299 * config/nds32/pipelines.md: Ditto.
20300
20301 2018-04-04 Richard Biener <rguenther@suse.de>
20302
20303 PR tree-optimization/85168
20304 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
20305 propagating abnormals.
20306
20307 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20308
20309 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
20310
20311 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20312 Kito Cheng <kito.cheng@gmail.com>
20313
20314 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
20315 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
20316 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
20317 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
20318 * config/nds32/nds32.md (sibcall_internal): New.
20319 (sibcall_register): Remove.
20320 (sibcall_immediate): Remove.
20321 (sibcall_value_internal): New.
20322 (sibcall_value_register): Remove.
20323 (sibcall_value_immediate): Remove.
20324 * config/nds32/predicates.md (nds32_general_register_operand): New.
20325 (nds32_call_address_operand): New.
20326
20327 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20328
20329 PR rtl-optimization/85167
20330 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
20331 bb_defs if *split_p, instead preinitialize it to NULL.
20332
20333 PR tree-optimization/85156
20334 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
20335 evaluating the argument multiple times.
20336
20337 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
20338
20339 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
20340 than vector.
20341 (_mm_cvtpd_ps): Likewise.
20342 (_mm_cvttpd_epi32): Likewise.
20343 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
20344 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
20345 vector, pixel, and bool following altivec.h include.
20346
20347 2018-04-03 Martin Sebor <msebor@redhat.com>
20348
20349 * doc/extend.texi (Common Function Attributes): Clarify.
20350 (const attribute): Likewise.
20351 (pure attribute): Likewise.
20352
20353 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20354
20355 PR target/85169
20356 * config/i386/i386.c (ix86_expand_vector_set): Use
20357 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
20358
20359 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
20360
20361 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
20362 instructions when changing rounding bits to preserve precision bits
20363 in the x87 control word.
20364
20365 2018-04-03 Martin Liska <mliska@suse.cz>
20366
20367 PR tree-optimization/82491
20368 * rtl.h (strip_offset_and_add): Replace += suboffset with
20369 poly_uint64 () + suboffset.
20370
20371 2018-03-29 Martin Liska <mliska@suse.cz>
20372 Martin Jambor <mjambor@suse.cz>
20373
20374 PR ipa/84947
20375 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
20376 param_type is not an integral or pointer type.
20377
20378 2018-04-03 Richard Biener <rguenther@suse.de>
20379
20380 * sese.h (recompute_all_dominators): Remove.
20381
20382 2018-04-02 Martin Sebor <msebor@redhat.com>
20383
20384 * doc/invoke.texi (-Wrestrict): Fix typos.
20385
20386 2018-04-02 Jim Wilson <jimw@sifive.com>
20387
20388 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
20389 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
20390 (<optab>di3, <optab>si3_extend): Likewise.
20391 (<optab>si3_mask, <optab>si3_mask_1): New.
20392 (<optab>di3_mask, <optab>di3_mask_1): New.
20393 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
20394 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
20395 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
20396
20397 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
20398
20399 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
20400 example.
20401
20402 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
20403
20404 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
20405 (nds32_canonicalize_comparison): New function.
20406
20407 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20408 Kito Cheng <kito.cheng@gmail.com>
20409 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20410
20411 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
20412 * config/nds32/constants.md (unspec_volatile_element): Add
20413 UNSPEC_VOLATILE_RELAX_GROUP.
20414 * config/nds32/nds32-relax-opt.c: New file.
20415 * config/nds32/nds32-predicates.c
20416 (nds32_symbol_load_store_p): New function.
20417 * config/nds32/nds32-protos.h
20418 (nds32_symbol_load_store_p): Declare function.
20419 (make_pass_nds32_relax_opt): Declare new rtl pass function.
20420 * config/nds32/nds32.c
20421 (nds32_register_pass): New function to register pass.
20422 (nds32_register_passes): New function to register passes.
20423 * config/nds32/nds32.md (relax_group): New pattern.
20424 * config/nds32/nds32.opt (mrelax-hint): New option.
20425 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
20426
20427 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
20428
20429 * config/nds32/t-nds32: Modify files dependency.
20430
20431 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20432
20433 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
20434 (PROFILE_HOOK): Define its implementation.
20435
20436 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20437
20438 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
20439 type and 32-bit size.
20440
20441 2018-04-01 Jakub Jelinek <jakub@redhat.com>
20442
20443 PR middle-end/85090
20444 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
20445 (V_128_256): New mode iterator.
20446 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
20447 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
20448 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
20449 of V.
20450 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
20451 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
20452
20453 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
20454
20455 PR target/83315
20456 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
20457 NaN inputs correctly.
20458
20459 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
20460
20461 PR target/80546
20462 * config/rs6000/vsx.md (??r): New mode attribute.
20463 (*vsx_mov<mode>_64bit): Use it.
20464 (*vsx_mov<mode>_32bit): Likewise.
20465
20466 2018-03-30 Martin Sebor <msebor@redhat.com>
20467
20468 PR tree-optimization/84818
20469 * builtins.c (check_access): Use warning_n.
20470
20471 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
20472
20473 PR target/83822
20474 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
20475 condition.
20476 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
20477 condition.
20478
20479 2018-03-30 Julia Koval <julia.koval@intel.com>
20480
20481 PR target/84413
20482 * x86-tune.def (movx, partial_reg_dependency): Enable for
20483 m_SKYLAKE_AVX512.
20484
20485 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
20486
20487 PR inline-asm/84985
20488 * lra-constraints.c (process_alt_operands): Move setting
20489 this_alternative_matches below.
20490
20491 2018-03-29 Martin Liska <mliska@suse.cz>
20492
20493 PR lto/84995.
20494 * doc/invoke.texi: Document how LTO works with debug info.
20495 Describe auto-load support of binutils. Mention 'x86-64'
20496 as valid option value of -march option.
20497
20498 2018-03-29 Jakub Jelinek <jakub@redhat.com>
20499
20500 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
20501
20502 PR c/85094
20503 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
20504 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
20505 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
20506 checking.
20507
20508 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20509
20510 PR target/84912
20511 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
20512 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
20513 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
20514 for RS6000_BTM_POWERPC64.
20515 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
20516 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
20517 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
20518 definition.
20519 (DIVDE): Use it.
20520 (DIVDEU): Likewise.
20521
20522 2018-03-28 Carl Love <cel@us.ibm.com>
20523
20524 Revert
20525 2017-09-27 Carl Love <cel@us.ibm.com>
20526
20527 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
20528 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
20529 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
20530 fctiw instruction.
20531
20532 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
20533
20534 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
20535 instead of __vector bool.
20536 (_mm_max_pu8): Likewise.
20537 (_mm_min_pi16): Likewise.
20538
20539 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20540
20541 PR target/84912
20542 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
20543 (DIVWEUO): Likewise.
20544 (DIVDEO): Likewise.
20545 (DIVDEUO): Likewise.
20546 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
20547 DIVWEUO and DIVDEUO.
20548 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
20549 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
20550 (div_extend): Likewise.
20551 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
20552 builtin function.
20553 (__builtin_divweuo): Likewise.
20554 (__builtin_divdeo): Likewise.
20555 (__builtin_divdeuo): Likewise.
20556
20557 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20558
20559 PR target/85095
20560 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
20561 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
20562
20563 PR tree-optimization/82004
20564 * gimple-match-head.c (optimize_pow_to_exp): New function.
20565 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
20566 Don't fold to exp if optimize_pow_to_exp is false.
20567
20568 2018-03-28 Martin Liska <mliska@suse.cz>
20569
20570 PR other/84819
20571 * calls.c (initialize_argument_information): Fix trailing space.
20572 * common.opt: Fix typo and provide better explanation for
20573 -fsanitize-coverage option.
20574 * config/i386/i386.opt: Fix typo.
20575
20576 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20577 Martin Liska <mliska@suse.cz>
20578
20579 PR sanitizer/85081
20580 * gimplify.c (asan_poison_variable): Don't do the check for
20581 gimplify_omp_ctxp here.
20582 (gimplify_decl_expr): Do it here.
20583 (gimplify_target_expr): Likewise.
20584
20585 2018-03-28 Martin Liska <mliska@suse.cz>
20586
20587 PR target/84988
20588 * config/i386/i386.c (ix86_function_arg_advance): Do not call
20589 chkp_type_bounds_count if MPX is not enabled.
20590
20591 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
20592
20593 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
20594
20595 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
20596
20597 PR target/84914
20598 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
20599 function to create the function decl for complex long double
20600 multiply and divide for -mabi=ieeelongdouble.
20601 (init_float128_ieee): Call it.
20602
20603 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
20604
20605 PR target/85044
20606 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
20607 -fcf-protection=branch -mibt.
20608 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
20609
20610 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20611
20612 PR target/81863
20613 * config/arm/arm.c (arm_valid_symbolic_address): Handle
20614 arm_word_relocations.
20615
20616 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
20617
20618 PR target/85056
20619 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
20620 extern array declarations.
20621
20622 2018-03-27 Richard Biener <rguenther@suse.de>
20623
20624 PR middle-end/84067
20625 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
20626 explicit single_use checks.
20627
20628 2018-03-27 Richard Biener <rguenther@suse.de>
20629
20630 PR tree-optimization/85082
20631 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
20632 Valueize the VUSE.
20633
20634 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20635
20636 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
20637 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
20638 Turn on fasynchronous-unwind-tables and funwind-tables.
20639
20640 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
20641
20642 PR target/85073
20643 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
20644 (*bmi_blsr_<mode>_ccz): Ditto.
20645
20646 2018-03-26 Tom de Vries <tom@codesourcery.com>
20647
20648 PR tree-optimization/85063
20649 * omp-general.c (offloading_function_p): New function. Factor out
20650 of ...
20651 * omp-offload.c (pass_omp_target_link::gate): ... here.
20652 * omp-general.h (offloading_function_p): Declare.
20653 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
20654 with attribute omp declare target for offloading functions.
20655
20656 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
20657
20658 PR tree-optimization/84005
20659 * tree-data-ref.h (get_base_for_alignment): Declare.
20660 * tree-data-ref.c (get_base_for_alignment_1): New function.
20661 (get_base_for_alignment): Likewise.
20662 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
20663 get_base_for_alignment to find a suitable base object, instead
20664 of always using drb->base_address.
20665
20666 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20667
20668 PR inline-asm/85022
20669 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
20670 known size by default.
20671
20672 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
20673
20674 PR inline-asm/85030
20675 * lra-constraints.c (process_alt_operands): Don't match BLKmode
20676 and non BLKmode operands.
20677
20678 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20679
20680 PR target/85026
20681 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
20682 Clean up attributes.
20683
20684 2018-03-23 Richard Biener <rguenther@suse.de>
20685
20686 PR debug/85020
20687 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
20688 we are going to emit early debug for LTO.
20689
20690 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20691
20692 PR inline-asm/85034
20693 * function.c (match_asm_constraints_1): Don't optimize if input
20694 doesn't satisfy general_operand predicate for output's mode.
20695
20696 PR inline-asm/85022
20697 * alias.c (write_dependence_p): Don't require for x_canonicalized
20698 non-VOIDmode if x has VOIDmode.
20699
20700 PR sanitizer/85029
20701 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
20702 just don't try to optimize it rather than assert it never happens.
20703
20704 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20705
20706 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
20707 macro expansions for definition of ST_INTERNAL_<mode> and
20708 LD_INTERNAL_<mode> builtins.
20709 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
20710 Remove prototype.
20711 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
20712 function.
20713 (altivec_expand_st_builtin): Likewise.
20714 (altivec_expand_builtin): Remove calls to deleted functions.
20715 (rs6000_address_for_altivec): Delete this function.
20716 * config/rs6000/vector.md: Remove expands for
20717 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
20718
20719 2018-03-22 Sudakshina Das <sudi.das@arm.com>
20720
20721 PR target/84826
20722 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
20723 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
20724 re-computing once computed.
20725 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
20726 (arm_init_machine_status): Initialize
20727 machine->static_chain_stack_bytes.
20728
20729 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20730
20731 PR target/84760
20732 * doc/extend.texi: Add four new prototypes for vec_ld.
20733 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
20734 definitions for more logical presentation.
20735 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
20736 entries for V1TI variants of __builtin_altivec_ld builtin.
20737 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
20738 handling of V1TI variant of LVX icode pattern.
20739 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
20740 (rs6000_gimple_fold_builtin): Likewise.
20741 (altivec_init_builtins): Add code to define
20742 __builtin_altivec_lvx_v1ti function.
20743
20744 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20745
20746 PR inline-asm/84941
20747 * function.c (match_asm_constraints_1): Don't do the optimization
20748 if input isn't a REG, SUBREG, MEM or constant.
20749
20750 2018-03-22 Tom de Vries <tom@codesourcery.com>
20751
20752 PR tree-optimization/84956
20753 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
20754 bb_has_abnormal_pred.
20755
20756 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20757
20758 PR sanitizer/85018
20759 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
20760 DECL_INITIAL (decl) to decl at the end.
20761 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
20762 adjust the comment.
20763
20764 2018-03-21 Joseph Myers <joseph@codesourcery.com>
20765
20766 * doc/extend.texi (__builtin_tgmath): Document when complex
20767 integer types are treated as _Complex _Float64.
20768
20769 2018-03-21 Tom de Vries <tom@codesourcery.com>
20770
20771 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
20772
20773 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20774
20775 PR tree-optimization/84960
20776 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
20777 if it is ENTRY block, move them into single succ of ENTRY in that case.
20778
20779 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
20780
20781 PR tree-optimization/84811
20782 * poly-int.h (poly_span_traits): Remove the T3 parameter and
20783 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
20784 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
20785 (known_subrange_p): Update accordingly. Cast each value involved
20786 in the size comparison, rather than casting the result of the
20787 subtraction.
20788
20789 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20790
20791 PR tree-optimization/84982
20792 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
20793 by flipping the least significant bit rather than all bits from
20794 bitpos to bitpos + bitsize - 1.
20795
20796 2018-03-21 Nathan Sidwell <nathan@acm.org>
20797
20798 * doc/extend.texi (Deprecated Features): Remove mention of
20799 long-deleted deprecations.
20800
20801 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
20802
20803 PR jit/84288
20804 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
20805 * configure: Regenerate.
20806
20807 2018-03-21 Tom de Vries <tom@codesourcery.com>
20808
20809 PR tree-optimization/83126
20810 * tree-parloops.c (num_phis): New function.
20811 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
20812
20813 2018-03-21 Nathan Sidwell <nathan@acm.org>
20814
20815 * doc/extend.texi (Deprecated Features): Update deprecated flags,
20816 mention anon-struct/union members and trailing attributes.
20817
20818 2018-03-21 Bin Cheng <bin.cheng@arm.com>
20819
20820 PR tree-optimization/84969
20821 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
20822 builtin memset partitions if they set different rhs values.
20823
20824 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20825
20826 PR rtl-optimization/84989
20827 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
20828 VEC_DUPLICATE with scalar result mode.
20829
20830 2018-03-21 Martin Liska <mliska@suse.cz>
20831
20832 PR ipa/84963
20833 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
20834 not intended return statement.
20835
20836 2018-03-21 Martin Liska <mliska@suse.cz>
20837
20838 PR target/84988
20839 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
20840 (chkp_find_bound_slots_1): Limit number of iterations.
20841
20842 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
20843
20844 PR target/84838
20845 * Minor grammar fixes for x86 options.
20846
20847 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20848
20849 PR debug/84875
20850 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
20851 holding REG_CFA_RESTORE notes, instead turn them into a USE.
20852
20853 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
20854
20855 PR target/83789
20856 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
20857 (altivec_lvx_<mode>_1op): Likewise.
20858 (altivec_stvx_<mode>_2op): Likewise.
20859 (altivec_stvx_<mode>_1op): Likewise.
20860 (altivec_lvx_<VM2:mode>): New define_expand.
20861 (altivec_stvx_<VM2:mode>): Likewise.
20862 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
20863 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20864 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
20865 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20866 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
20867 (rs6000_gen_lvx): Likewise.
20868 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
20869 (altivec_expand_stv_builtin): Likewise.
20870 (altivec_expand_builtin): Likewise.
20871 * config/rs6000/vector.md: Likewise.
20872
20873 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20874
20875 PR target/82518
20876 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
20877 BYTES_BIG_ENDIAN.
20878
20879 2018-03-20 Richard Biener <rguenther@suse.de>
20880
20881 PR target/84986
20882 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
20883 sign-conversions as zero, fall back to standard scalar_stmt
20884 cost for the rest.
20885
20886 2018-03-20 Martin Liska <mliska@suse.cz>
20887
20888 PR ipa/84825
20889 * predict.c (rebuild_frequencies): Handle case when we have
20890 PROFILE_ABSENT, but flag_guess_branch_prob is false.
20891
20892 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20893
20894 PR target/84990
20895 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
20896 flag_section_anchors.
20897 * varasm.c (use_blocks_for_decl_p): Remove hack for
20898 dw2_force_const_mem.
20899
20900 PR target/84845
20901 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
20902 to ...
20903 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
20904 be created, use lowpart_subreg of operands[0] rather than operands[0]
20905 itself.
20906 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
20907 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
20908 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
20909 and n constraint instead of aarch64_shift_imm_di and Usd.
20910 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
20911 (*aarch64_<optab>_reg_minus<mode>3): ... this.
20912
20913 2018-03-20 Sudakshina Das <sudi.das@arm.com>
20914
20915 PR target/82989
20916 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
20917 to favor GPR over NEON registers.
20918 (<shift>di3_neon): Likewise.
20919
20920 2018-03-20 Tom de Vries <tom@codesourcery.com>
20921
20922 PR target/84952
20923 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
20924 (nvptx_process_pars): Emit bar.sync asap and alap.
20925
20926 2018-03-20 Tom de Vries <tom@codesourcery.com>
20927
20928 PR target/84954
20929 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
20930 seen_label if seen_label is already set.
20931
20932 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20933
20934 PR target/84945
20935 * config/i386/i386.c (fold_builtin_cpu): For features above 31
20936 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
20937 Use 1U instead of 1. Formatting fixes.
20938
20939 PR c/84953
20940 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
20941 instead of TREE_TYPE (s1) for the return value.
20942
20943 2018-03-19 Jakub Jelinek <jakub@redhat.com>
20944
20945 PR tree-optimization/84946
20946 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
20947 bitsize + bitsize in poly_uint64 rather than poly_int64.
20948
20949 PR sanitizer/78651
20950 * dwarf2asm.c: Include fold-const.c.
20951 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
20952 of decl rather than decl itself.
20953
20954 PR rtl-optimization/84643
20955 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
20956
20957 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
20958
20959 PR sanitizer/78651
20960 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
20961 calling assemble_variable.
20962
20963 2018-03-19 Sudakshina Das <sudi.das@arm.com>
20964
20965 PR target/81647
20966 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
20967 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
20968
20969 2018-03-19 Jim Wilson <jimw@sifive.com>
20970
20971 PR bootstrap/84856
20972 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
20973 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
20974 (riscv_first_stack_step): Likewise.
20975 (riscv_option_override): Use STACK_BOUNDARY instead of
20976 MIN_STACK_BOUNDARY.
20977 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
20978 MIN_STACK_BOUNDARY.
20979 (BIGGEST_ALIGNMENT): Set to 128.
20980 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
20981 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
20982 STACK_BOUNDARY.
20983
20984 2018-03-19 Richard Biener <rguenther@suse.de>
20985
20986 PR tree-optimization/84933
20987 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
20988 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
20989
20990 2018-03-19 Richard Biener <rguenther@suse.de>
20991
20992 PR tree-optimization/84859
20993 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
20994 (cond_if_else_store_replacement): Perform sinking operation on
20995 single-store BBs regardless of MAX_STORES_TO_SINK setting.
20996 Generalize what a BB with a single eligible store is.
20997
20998 2018-03-19 Richard Biener <rguenther@suse.de>
20999
21000 PR tree-optimization/84929
21001 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
21002 chrec_is_positive against non-chrec arg.
21003
21004 2018-03-19 Tamar Christina <tamar.christina@arm.com>
21005
21006 PR target/84711
21007 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
21008
21009 2018-03-18 Martin Liska <mliska@suse.cz>
21010
21011 PR rtl-optimization/84635
21012 * regrename.c (build_def_use): Use matches_mode only when
21013 matches >= 0.
21014
21015 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
21016
21017 PR tree-optimization/84913
21018 * tree-vect-loop.c (vectorizable_reduction): Don't try to
21019 vectorize chains of COND_EXPRs.
21020
21021 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21022
21023 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
21024
21025 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21026
21027 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
21028
21029 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21030
21031 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
21032
21033 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21034 Kito Cheng <kito.cheng@gmail.com>
21035
21036 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
21037 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
21038 (nds32_adjust_reg_alloc_order): New function.
21039 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
21040
21041 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
21042
21043 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
21044 nds32_print_operand, nds32_print_operand_address): Use
21045 HOST_WIDE_INT_PRINT_DEC instead.
21046
21047 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21048
21049 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
21050
21051 2018-03-17 Jakub Jelinek <jakub@redhat.com>
21052
21053 PR target/84902
21054 * config/i386/i386.c (initial_ix86_tune_features,
21055 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
21056 unsigned long long.
21057 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
21058 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
21059 rather than 1u << ix86_tune. Formatting fix.
21060 (ix86_option_override_internal): Change ix86_arch_mask from
21061 unsigned int to unsigned HOST_WIDE_INT, initialize to
21062 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
21063 (ix86_function_specific_restore): Likewise.
21064
21065 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21066
21067 PR target/84899
21068 * postreload.c (reload_combine_recognize_pattern): Perform
21069 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
21070 truncate_int_for_mode the result for the destination's mode.
21071
21072 PR c/84909
21073 * hsa-gen.c (mem_type_for_type): Fix comment typo.
21074 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
21075 Likewise.
21076 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21077 Likewise.
21078
21079 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
21080
21081 PR target/84876
21082 * lra-assigns.c (lra_split_hard_reg_for): Don't use
21083 regno_allocno_class_array and sorted_pseudos.
21084 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
21085 insns where regno is used.
21086
21087 2018-03-16 Martin Liska <mliska@suse.cz>
21088
21089 PR ipa/84833
21090 * multiple_target.c (create_dispatcher_calls): Redirect
21091 reference in the symbol table.
21092
21093 2018-03-16 Martin Liska <mliska@suse.cz>
21094
21095 PR ipa/84722
21096 * multiple_target.c (create_dispatcher_calls): Redirect also
21097 an alias.
21098
21099 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21100
21101 PR c++/79937
21102 PR c++/82410
21103 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
21104 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
21105 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
21106
21107 2018-03-16 Julia Koval <julia.koval@intel.com>
21108
21109 * doc/invoke.texi (Skylake Server): Add CLWB.
21110 Cannonlake): Remove CLWB.
21111
21112 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21113
21114 PR tree-optimization/84841
21115 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
21116 1 << 3.
21117 (FLOAT_ONE_CONST_TYPE): Define.
21118 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
21119 (sort_by_operand_rank): Put entries with higher constant_type last
21120 rather than first to match comments.
21121
21122 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
21123
21124 * config/nios2/nios2.md (movsi_internal): Fix thinko in
21125 split predicate.
21126
21127 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21128
21129 PR c++/79085
21130 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
21131 check and use address of target always.
21132
21133 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
21134
21135 PR target/84574
21136 * config/i386/i386.c (indirect_thunk_needed): Update comments.
21137 (indirect_thunk_bnd_needed): Likewise.
21138 (indirect_thunks_used): Likewise.
21139 (indirect_thunks_bnd_used): Likewise.
21140 (indirect_return_needed): New.
21141 (indirect_return_bnd_needed): Likewise.
21142 (output_indirect_thunk_function): Add a bool argument for
21143 function return.
21144 (output_indirect_thunk_function): Don't generate alias for
21145 function return thunk.
21146 (ix86_code_end): Call output_indirect_thunk_function to generate
21147 function return thunks.
21148 (ix86_output_function_return): Set indirect_return_bnd_needed
21149 and indirect_return_needed instead of indirect_thunk_bnd_needed
21150 and indirect_thunk_needed.
21151
21152 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
21153
21154 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
21155 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
21156 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
21157
21158 2018-03-15 David Malcolm <dmalcolm@redhat.com>
21159 Paul Hua <paul.hua.gm@gmail.com>
21160
21161 PR c/84852
21162 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
21163
21164 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
21165
21166 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
21167 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
21168 resp. SFmode cases.
21169
21170 2018-03-15 Tamar Christina <tamar.christina@arm.com>
21171
21172 PR target/84711
21173 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
21174 instead of GET_MODE_SIZE when comparing Units.
21175
21176 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
21177
21178 PR target/68256
21179 * varasm.c (hash_section): Return an unchangeble hash value
21180 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
21181 Return !aarch64_can_use_per_function_literal_pools_p ().
21182
21183 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21184
21185 PR target/84860
21186 * optabs.c (emit_conditional_move): Pass address of cmode's copy
21187 rather than address of cmode as last argument to prepare_cmp_insn.
21188
21189 2018-03-15 Julia Koval <julia.koval@intel.com>
21190
21191 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
21192 F_AVX512VNNI, F_AVX512BITALG): New.
21193
21194 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
21195
21196 PR target/83451
21197 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
21198 insn for floating-point loads and stores.
21199
21200 2018-03-14 Carl Love <cel@us.ibm.com>
21201
21202 * config/rs6000/rs6000-c.c: Add macro definitions for
21203 ALTIVEC_BUILTIN_VEC_PERMXOR.
21204 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
21205 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
21206 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
21207 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
21208 UNSPEC_VPERMXOR.
21209 * config/doc/extend.texi: Add prototypes for vec_permxor.
21210
21211 2018-03-14 David Malcolm <dmalcolm@redhat.com>
21212
21213 PR c/84852
21214 * diagnostic-show-locus.c (class layout_point): Convert m_line
21215 from int to linenum_type.
21216 (line_span::comparator): Use linenum "compare" function when
21217 comparing line numbers.
21218 (test_line_span): New function.
21219 (layout_range::contains_point): Convert param "row" from int to
21220 linenum_type.
21221 (layout_range::intersects_line_p): Likewise.
21222 (layout::will_show_line_p): Likewise.
21223 (layout::print_source_line): Likewise.
21224 (layout::should_print_annotation_line_p): Likewise.
21225 (layout::print_annotation_line): Likewise.
21226 (layout::print_leading_fixits): Likewise.
21227 (layout::annotation_line_showed_range_p): Likewise.
21228 (struct line_corrections): Likewise for field m_row.
21229 (line_corrections::line_corrections): Likewise for param "row".
21230 (layout::print_trailing_fixits): Likewise.
21231 (layout::get_state_at_point): Likewise.
21232 (layout::get_x_bound_for_row): Likewise.
21233 (layout::print_line): Likewise.
21234 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
21235 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
21236 * input.c (selftest::test_linenum_comparisons): New function.
21237 (selftest::input_c_tests): Call it.
21238 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
21239 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
21240 * selftest.h (ASSERT_GT): New macro.
21241 (ASSERT_GT_AT): New macro.
21242 (ASSERT_LT): New macro.
21243 (ASSERT_LT_AT): New macro.
21244
21245 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
21246
21247 PR rtl-optimization/84780
21248 * combine.c (distribute_links): Don't make a link based on pc_rtx.
21249
21250 2018-03-14 Martin Liska <mliska@suse.cz>
21251
21252 * tree.c (record_node_allocation_statistics): Use
21253 get_stats_node_kind.
21254 (get_stats_node_kind): New function extracted from
21255 record_node_allocation_statistics.
21256 (free_node): Use get_stats_node_kind.
21257
21258 2018-03-14 Richard Biener <rguenther@suse.de>
21259
21260 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
21261 that the value-set of ANTIC_IN doesn't grow.
21262
21263 Revert
21264 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
21265 member.
21266 (BB_VISITED_WITH_VISITED_SUCCS): New define.
21267 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
21268
21269 2018-03-14 Julia Koval <julia.koval@intel.com>
21270
21271 * config.gcc (icelake-client, icelake-server): New.
21272 (icelake): Remove.
21273 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
21274 (initial_ix86_arch_features): Ditto.
21275 (PTA_SKYLAKE): Add SGX.
21276 (PTA_ICELAKE): Remove.
21277 (PTA_ICELAKE_CLIENT): New.
21278 (PTA_ICELAKE_SERVER): New.
21279 (ix86_option_override_internal): Split up icelake on icelake client and
21280 icelake server.
21281 (get_builtin_code_for_version): Ditto.
21282 (fold_builtin_cpu): Ditto.
21283 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
21284 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
21285 * config/i386/i386.h (processor_type): Ditto.
21286 * doc/invoke.texi: Ditto.
21287
21288 2018-03-14 Jakub Jelinek <jakub@redhat.com>
21289
21290 PR sanitizer/83392
21291 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
21292 INTEGER_CST offset, add it together with bitpos / 8 and
21293 sign extend based on POINTER_SIZE.
21294
21295 PR target/84844
21296 Revert
21297 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
21298
21299 PR target/78090
21300 * config/i386/constraints.md (Yc): New register constraint.
21301 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
21302 Use Yc constraint for alternative 2 of operand 0. Remove
21303 preferred_for_speed attribute.
21304
21305 2018-03-14 Richard Biener <rguenther@suse.de>
21306
21307 PR tree-optimization/84830
21308 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
21309 with the old one to avoid oscillations.
21310
21311 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
21312
21313 PR target/83712
21314 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
21315 pseudos.
21316 (assign_by_spills): Return a flag of reload assignment failure.
21317 Do not process the reload assignment failures. Do not spill other
21318 reload pseudos if they has the same reg class. Update n if
21319 necessary.
21320 (lra_assign): Add a return arg. Set up from the result of
21321 assign_by_spills call.
21322 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21323 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21324 usage_insns if it is not NULL.
21325 (spill_hard_reg_in_range): New function.
21326 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21327 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21328 function prototypes.
21329 (lra_assign): Change prototype.
21330 * lra.c (lra): Add code to deal with fails by splitting hard reg
21331 live ranges.
21332
21333 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
21334
21335 * config/riscv/riscv.opt (mrelax): New option.
21336 * config/riscv/riscv.c (riscv_file_start): Emit ".option
21337 "norelax" when riscv_mrelax is disabled.
21338 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
21339
21340 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
21341
21342 PR target/84743
21343 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
21344 reassociation for int modes.
21345
21346 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21347
21348 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
21349 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
21350 for big-endian.
21351 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
21352 * config/aarch64/aarch64-sve.md
21353 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
21354 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
21355 (*extend<mode><Vwide>2): Rename to...
21356 (aarch64_sve_extend<mode><Vwide>2): ...this.
21357 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
21358 renaming the old pattern to...
21359 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
21360 unsigned packs.
21361 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
21362 define_expand, renaming the old pattern to...
21363 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
21364 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
21365 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
21366 account when deciding which SVE instruction the optab should use.
21367 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
21368
21369 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21370
21371 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
21372 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
21373 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
21374 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
21375 (tlsdesc_small_<mode>): Turn a define_expand and use
21376 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
21377 (tlsdesc_small_advsimd_<mode>): ...this.
21378 (tlsdesc_small_sve_<mode>): New pattern.
21379
21380 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21381
21382 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
21383 (UNSPEC_UMUL_HIGHPART): New constants.
21384 (MUL_HIGHPART): New int iteraor.
21385 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
21386 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
21387 define_expand.
21388 (*<su>mul<mode>3_highpart): New define_insn.
21389
21390 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
21391
21392 PR lto/84805
21393 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
21394 incomplete types.
21395
21396 2018-03-13 Martin Liska <mliska@suse.cz>
21397
21398 PR ipa/84658.
21399 * (sem_item_optimizer::sem_item_optimizer): Initialize new
21400 vector.
21401 (sem_item_optimizer::~sem_item_optimizer): Release it.
21402 (sem_item_optimizer::merge_classes): Register variable aliases.
21403 (sem_item_optimizer::fixup_pt_set): New function.
21404 (sem_item_optimizer::fixup_points_to_sets): Likewise.
21405 * ipa-icf.h: Declare new variables and functions.
21406
21407 2018-03-13 Jakub Jelinek <jakub@redhat.com>
21408
21409 PR middle-end/84834
21410 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
21411 integer_pow2p@2 and test integer_pow2p in condition.
21412 (A < 0 ? C : 0): Similarly for @1.
21413
21414 PR middle-end/84831
21415 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
21416 characters starting at p contain '\0' character, don't look beyond
21417 that.
21418
21419 PR target/84827
21420 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
21421 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
21422
21423 PR target/84828
21424 * reg-stack.c (change_stack): Change update_end var from int to
21425 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
21426 also call set_block_for_insn on the newly added insns and rescan.
21427
21428 PR target/84786
21429 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
21430 on the last operand.
21431
21432 PR c++/84704
21433 * tree.c (stabilize_reference_1): Return save_expr (e) for
21434 STATEMENT_LIST even if it doesn't have side-effects.
21435
21436 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
21437
21438 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
21439
21440 2018-03-12 Renlin Li <renlin.li@arm.com>
21441
21442 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
21443 aarch64_output_scalar_simd_mov_immediate.
21444
21445 2018-03-12 Martin Sebor <msebor@redhat.com>
21446
21447 PR tree-optimization/83456
21448 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
21449 for perfectly overlapping calls to memcpy.
21450 (gimple_fold_builtin_memory_chk): Same.
21451 (gimple_fold_builtin_strcpy): Handle no-warning.
21452 (gimple_fold_builtin_stxcpy_chk): Same.
21453 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
21454
21455 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21456
21457 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
21458 parameter. Use it for SFmode.
21459 (rs6000_function_arg_advance_1): Adjust.
21460 (rs6000_function_arg): Adjust.
21461 (rs6000_gimplify_va_arg): Pass false for that new parameter.
21462
21463 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21464
21465 PR rtl-optimization/84169
21466 PR rtl-optimization/84780
21467 * combine.c (can_combine_p): Check for a 2-insn combination whether
21468 the destination register is used between the two insns, too.
21469
21470 2018-03-12 Richard Biener <rguenther@suse.de>
21471
21472 PR tree-optimization/84803
21473 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
21474 for refs DR analysis didn't process.
21475
21476 2018-03-12 Richard Biener <rguenther@suse.de>
21477
21478 PR tree-optimization/84777
21479 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
21480 force-vectorize loops ignore whether we are optimizing for size.
21481
21482 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
21483
21484 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
21485 (TARGET_MD_ASM_ADJUST): Define.
21486
21487 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
21488 Kito Cheng <kito.cheng@gmail.com>
21489 Chung-Ju Wu <jasonwucj@gmail.com>
21490
21491 * config/nds32/nds32.c (nds32_compute_stack_frame,
21492 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
21493 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
21494 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
21495 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
21496 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
21497 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
21498 * config/nds32/nds32.md (prologue, epilogue): Use macro
21499 NDS32_V3PUSH_AVAILABLE_P to do checking.
21500
21501 2018-03-11 Jakub Jelinek <jakub@redhat.com>
21502
21503 PR debug/58150
21504 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
21505 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
21506 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
21507 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
21508 addition of most attributes on !orig_type_die or the attribute not
21509 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
21510
21511 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21512 Chung-Ju Wu <jasonwucj@gmail.com>
21513
21514 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
21515 __NDS32_VH__ macro.
21516 * config/nds32/nds32.opt (mvh): New option.
21517
21518 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21519 Chung-Ju Wu <jasonwucj@gmail.com>
21520
21521 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
21522 function.
21523 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
21524 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
21525 definition.
21526
21527 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21528 Chung-Ju Wu <jasonwucj@gmail.com>
21529
21530 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
21531 function.
21532 * config/nds32/nds32-multiple.md (strlensi): New pattern.
21533 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
21534
21535 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
21536 Kito Cheng <kito.cheng@gmail.com>
21537 Chung-Ju Wu <jasonwucj@gmail.com>
21538
21539 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
21540 UNSPEC_FFMISM and UNSPEC_FLMISM.
21541 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
21542 for ffb, ffmism and flmism.
21543 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
21544 (unspec_ffmism): Ditto.
21545 (unspec_flmism): Ditto.
21546 (nds32_expand_builtin_impl): Check if string extension is available.
21547 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
21548 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
21549
21550 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
21551
21552 Reverting patch:
21553 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
21554
21555 PR target/83712
21556 * lra-assigns.c (assign_by_spills): Return a flag of reload
21557 assignment failure. Do not process the reload assignment
21558 failures. Do not spill other reload pseudos if they has the same
21559 reg class.
21560 (lra_assign): Add a return arg. Set up from the result of
21561 assign_by_spills call.
21562 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21563 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21564 usage_insns if it is not NULL.
21565 (spill_hard_reg_in_range): New function.
21566 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21567 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21568 function prototypes.
21569 (lra_assign): Change prototype.
21570 * lra.c (lra): Add code to deal with fails by splitting hard reg
21571 live ranges.
21572
21573 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
21574
21575 PR target/84807
21576 * config/i386/i386.opt: Replace Enforcment with Enforcement.
21577
21578 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
21579
21580 PR debug/84620
21581 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
21582 (dw_val_node): Add val_symbolic_view.
21583 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
21584 (symview_upper_bound): New.
21585 (new_line_info_table): Initialize symviews_since_reset.
21586 (dwarf2out_source_line): Count symviews_since_reset and set
21587 symview_upper_bound.
21588 (dw_val_equal_p): Handle symview.
21589 (add_AT_symview): New.
21590 (print_dw_val): Handle symview.
21591 (attr_checksum, attr_checksum_ordered): Likewise.
21592 (same_dw_val_p, size_of_die): Likewise.
21593 (value_format, output_die): Likewise.
21594 (add_high_low_attributes): Use add_AT_symview for entry_view.
21595 (dwarf2out_finish): Reset symview_upper_bound, clear
21596 zero_view_p.
21597
21598 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
21599
21600 PR target/83969
21601 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
21602 Add strict argument and use it.
21603 (rs6000_split_multireg_move): Update for new strict argument.
21604 (mem_operand_gpr): Disallow all non-offsettable addresses.
21605 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
21606
21607 2018-03-09 Jakub Jelinek <jakub@redhat.com>
21608
21609 PR target/84772
21610 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
21611 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
21612 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
21613
21614 PR c++/84767
21615 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
21616 decl, use remap_type if we want to use the type.
21617
21618 2018-03-09 Martin Sebor <msebor@redhat.com>
21619
21620 PR tree-optimization/84526
21621 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21622 Remove dead code.
21623 (builtin_access::generic_overlap): Be prepared to handle non-array
21624 base objects.
21625
21626 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
21627
21628 PR rtl-optimization/84682
21629 * lra-constraints.c (process_address_1): Check is_address flag
21630 for address constraints.
21631 (process_alt_operands): Likewise.
21632 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
21633 preprocess_constraints.
21634 * recog.h (preprocess_constraints): Add oploc parameter.
21635 Adjust callers.
21636 * recog.c (preprocess_constraints): Test address_operand for
21637 CT_ADDRESS constraints.
21638
21639 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
21640
21641 PR target/83712
21642 * lra-assigns.c (assign_by_spills): Return a flag of reload
21643 assignment failure. Do not process the reload assignment
21644 failures. Do not spill other reload pseudos if they has the same
21645 reg class.
21646 (lra_assign): Add a return arg. Set up from the result of
21647 assign_by_spills call.
21648 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21649 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21650 usage_insns if it is not NULL.
21651 (spill_hard_reg_in_range): New function.
21652 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21653 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21654 function prototypes.
21655 (lra_assign): Change prototype.
21656 * lra.c (lra): Add code to deal with fails by splitting hard reg
21657 live ranges.
21658
21659 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21660
21661 PR target/83193
21662 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
21663 Accept complain bool parameter. Only emit errors if it is true.
21664 (arm_parse_cpu_option_name): Likewise.
21665 (arm_target_thumb_only): Adjust callers of the above.
21666 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
21667 prototype to take a default true bool parameter.
21668 (arm_parse_arch_option_name): Likewise.
21669
21670 2018-03-09 David Malcolm <dmalcolm@redhat.com>
21671 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
21672
21673 PR jit/64089
21674 PR jit/84288
21675 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
21676 * configure: Regenerate.
21677 * configure.ac ("linker --version-script option"): New.
21678 ("linker soname option"): New.
21679
21680 2018-03-09 Richard Biener <rguenther@suse.de>
21681
21682 PR tree-optimization/84775
21683 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
21684 immediate uses of predicate stmts and mark them modified.
21685
21686 Revert
21687 PR tree-optimization/84178
21688 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21689 to caller.
21690 (version_loop_for_if_conversion): Delay update_ssa call.
21691 (tree_if_conversion): Delay update_ssa until after predicate
21692 insertion.
21693
21694 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
21695
21696 PR target/84763
21697 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
21698 when the function accesses prior frames.
21699
21700 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21701
21702 PR debug/84456
21703 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
21704 gen_llsym, otherwise call maybe_gen_llsym.
21705
21706 PR inline-asm/84742
21707 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
21708 has ',' character inside of it.
21709
21710 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21711
21712 PR target/84748
21713 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
21714 as clobbering CC_REGNUM.
21715
21716 2018-03-08 Richard Biener <rguenther@suse.de>
21717
21718 PR middle-end/84552
21719 * tree-scalar-evolution.c: Include tree-into-ssa.h.
21720 (follow_copies_to_constant): Do not follow SSA names registered
21721 for update.
21722
21723 2018-03-08 Richard Biener <rguenther@suse.de>
21724
21725 PR tree-optimization/84178
21726 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21727 to caller.
21728 (version_loop_for_if_conversion): Delay update_ssa call.
21729 (tree_if_conversion): Delay update_ssa until after predicate
21730 insertion.
21731
21732 2018-03-08 David Malcolm <dmalcolm@redhat.com>
21733
21734 PR tree-optimization/84178
21735 * tree-if-conv.c (release_bb_predicate): Remove the
21736 the assertion that the stmts have NULL use_ops.
21737 Discard the statements, asserting that they haven't
21738 yet been added to a BB.
21739
21740 2018-03-08 Richard Biener <rguenther@suse.de>
21741
21742 PR tree-optimization/84746
21743 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
21744 (phi_translate): Pass in destination ANTIC_OUT set.
21745 (phi_translate_1): Likewise. For a simplified result lookup
21746 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
21747 (phi_translate_set): Adjust.
21748 (do_pre_regular_insertion): Likewise.
21749 (do_pre_partial_partial_insertion): Likewise.
21750
21751 2018-03-08 Martin Liska <mliska@suse.cz>
21752
21753 PR gcov-profile/84735
21754 * doc/gcov.texi: Document usage of profile files.
21755 * gcov-io.h: Document changes in the format.
21756
21757 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
21758
21759 PR debug/84404
21760 PR debug/84408
21761 * dwarf2out.c (struct dw_line_info_table): Update comments for
21762 view == -1.
21763 (FORCE_RESET_NEXT_VIEW): New.
21764 (FORCE_RESETTING_VIEW_P): New.
21765 (RESETTING_VIEW_P): Check for -1 too.
21766 (ZERO_VIEW_P): Likewise.
21767 (new_line_info_table): Force-reset next view.
21768 (dwarf2out_begin_function): Likewise.
21769 (dwarf2out_source_line): Simplify zero_view_p initialization.
21770 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
21771 view directly. Omit view when omitting .loc at line 0.
21772
21773 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21774
21775 PR tree-optimization/84740
21776 * tree-switch-conversion.c (process_switch): Call build_constructors
21777 only if info.phi_count is non-zero.
21778
21779 PR tree-optimization/84739
21780 * tree-tailcall.c (find_tail_calls): Check call arguments against
21781 DECL_ARGUMENTS (current_function_decl) rather than
21782 DECL_ARGUMENTS (func) when checking for tail recursion.
21783
21784 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21785
21786 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
21787 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
21788 Volker Reichelt's entry and add entries for people that perform
21789 GCC fuzzy testing and report numerous bugs.
21790
21791 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
21792
21793 PR target/82411
21794 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
21795 readonly data in sdata, if that is disabled.
21796 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
21797 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
21798 -mreadonly-in-sdata option.
21799
21800 2018-03-07 Martin Sebor <msebor@redhat.com>
21801
21802 PR tree-optimization/84468
21803 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
21804 basic block when looking for nul assignment.
21805
21806 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
21807
21808 PR target/84277
21809 * except.h (output_function_exception_table): Adjust prototype.
21810 * except.c (output_function_exception_table): Remove FNNAME parameter
21811 and add SECTION parameter. Ouput one part of the table at a time.
21812 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
21813 the first part of the exception table and emit unwind directives.
21814 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
21815 (i386_pe_seh_cold_init): Likewise.
21816 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
21817 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
21818 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
21819 (ix86_output_call_insn): Emit a nop in one more case for SEH.
21820 * config/i386/winnt.c: Include except.h.
21821 (struct seh_frame_state): Add reg_offset, after_prologue and
21822 in_cold_section fields.
21823 (i386_pe_seh_end_prologue): Set seh->after_prologue.
21824 (i386_pe_seh_cold_init): New function.
21825 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
21826 to seh->in_cold_section.
21827 (seh_emit_push): Record the offset of the push.
21828 (seh_emit_save): Record the offet of the save.
21829 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
21830 Test seh->after_prologue to disregard the epilogue.
21831 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
21832 (i386_pe_end_cold_function): New function.
21833
21834 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21835
21836 PR fortran/84565
21837 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
21838 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
21839
21840 PR c++/84704
21841 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
21842 on tmp_var.
21843 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
21844 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
21845
21846 PR middle-end/84723
21847 * multiple_target.c: Include tree-inline.h and intl.h.
21848 (expand_target_clones): Diagnose and fail if node->definition and
21849 !tree_versionable_function_p (node->decl).
21850
21851 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
21852
21853 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
21854 sprint_ul.
21855 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
21856 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
21857 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
21858
21859 2018-03-06 Jakub Jelinek <jakub@redhat.com>
21860
21861 PR target/84710
21862 * combine.c (try_combine): Use reg_or_subregno instead of handling
21863 just paradoxical SUBREGs and REGs.
21864
21865 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
21866
21867 * config/arc/arc.c (arc_finalize_pic): Remove function.
21868 (arc_must_save_register): We use single base PIC register, remove
21869 checks to save/restore the PIC register.
21870 (arc_expand_prologue): Likewise.
21871 * config/arc/arc-protos.h (arc_set_default_type_attributes):
21872 Remove.
21873 (arc_verify_short): Likewise.
21874 (arc_attr_type): Likewise.
21875 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
21876 (walk_stores): Likewise.
21877 (arc_address_cost): Make it static.
21878 (arc_verify_short): Likewise.
21879 (branch_dest): Likewise.
21880 (arc_attr_type): Likewise.
21881 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
21882 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
21883 (arc_final_prescan_insn): Remove inserting the nops due to
21884 hardware hazards. It is done in reorg step.
21885 (insn_length_variant_t): Remove.
21886 (insn_length_parameters_t): Likewise.
21887 (arc_insn_length_parameters): Likewise.
21888 (arc_get_insn_variants): Likewise.
21889 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
21890
21891 2018-03-06 Jakub Jelinek <jakub@redhat.com>
21892
21893 PR inline-asm/84683
21894 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
21895 assertion failure.
21896
21897 PR tree-optimization/84687
21898 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
21899 on new_node->decl.
21900 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
21901
21902 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
21903
21904 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
21905 Rename to ppc_speculation_barrier.
21906 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
21907 __builtin_ppc_speculation_barrier.
21908
21909 2018-03-05 Jakub Jelinek <jakub@redhat.com>
21910
21911 PR target/84700
21912 * combine.c (combine_simplify_rtx): Don't try to simplify if
21913 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
21914 are equal to x.
21915
21916 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
21917
21918 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
21919 to 32 bytes when compiling for POWER9.
21920
21921 2018-03-05 Jakub Jelinek <jakub@redhat.com>
21922
21923 PR target/84564
21924 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
21925 regparm >= 3 with no arg reg available also for calls with
21926 flag_force_indirect_call. Pass decl to ix86_function_regparm.
21927
21928 PR target/84524
21929 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
21930 orig,vex.
21931 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
21932
21933 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
21934
21935 PR target/84264
21936 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
21937
21938 2018-03-05 Richard Biener <rguenther@suse.de>
21939
21940 PR tree-optimization/84486
21941 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
21942 When inserting a __builtin_assume_aligned call set the LHS
21943 SSA name alignment info accordingly.
21944
21945 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
21946
21947 PR tree-optimization/84114
21948 * config/aarch64/aarch64.c (aarch64_reassociation_width)
21949 Avoid reassociation of FLOAT_MODE addition.
21950
21951 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
21952
21953 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
21954 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
21955 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
21956 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
21957 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
21958 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
21959 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
21960 and -mwbnoinvd.
21961 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
21962 __builtin_ia32_wbinvd): New builtins.
21963 (SPECIAL_ARGS2): New.
21964 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
21965 (SPECIAL_ARGS2): New.
21966 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
21967 (ix86_valid_target_attribute_inner_p): Ditto.
21968 (ix86_init_mmx_sse_builtins): Add special_args2.
21969 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
21970 TARGET_WBNOINVD_P): New.
21971 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
21972 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
21973 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
21974 * config/i386/immintrin.h (_wbinvd): New intrinsic.
21975 * config/i386/pconfigintrin.h: New file.
21976 * config/i386/wbnoinvdintrin.h: Ditto.
21977 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
21978 wbnoinvdintrin.h.
21979 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
21980
21981 2018-03-05 Richard Biener <rguenther@suse.de>
21982
21983 PR tree-optimization/84670
21984 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
21985 member.
21986 (BB_VISITED_WITH_VISITED_SUCCS): New define.
21987 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
21988 (compute_antic_aux): Only assert the number of values in ANTIC_IN
21989 doesn't grow if all successors (recursively) were visited at least
21990 once.
21991
21992 2018-03-05 Richard Biener <rguenther@suse.de>
21993
21994 PR tree-optimization/84650
21995 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
21996 if executed in the loop pipeline.
21997
21998 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
21999
22000 * doc/configfiles.texi (Configuration Files): Move info about
22001 conditionalizing $target-protos.h to...
22002 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
22003 differs from $target-protos.h.
22004
22005 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
22006 Chung-Ju Wu <jasonwucj@gmail.com>
22007
22008 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
22009 * config/nds32/nds32-multiple.md (setmemsi): Define.
22010 * config/nds32/nds32-memory-manipulation.c
22011 (nds32_gen_dup_4_byte_to_word_value): New.
22012 (emit_setmem_word_loop): New.
22013 (emit_setmem_byte_loop): New.
22014 (nds32_expand_setmem_loop): New.
22015 (nds32_expand_setmem_loop_v3m): New.
22016 (nds32_expand_setmem_unroll): New.
22017 (nds32_expand_setmem): New.
22018
22019 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22020 Chung-Ju Wu <jasonwucj@gmail.com>
22021
22022 * config/nds32/nds32-memory-manipulation.c
22023 (nds32_emit_load_store): New.
22024 (nds32_emit_post_inc_load_store): New.
22025 (nds32_emit_mem_move): New.
22026 (nds32_emit_mem_move_block): New.
22027 (nds32_expand_movmemsi_loop_unknown_size): New.
22028 (nds32_expand_movmemsi_loop_known_size): New.
22029 (nds32_expand_movmemsi_loop): New.
22030 (nds32_expand_movmemsi_unroll): New.
22031 (nds32_expand_movmemqi): Rename ...
22032 (nds32_expand_movmemsi): ... to this.
22033 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
22034 (movmemsi): ... to this.
22035 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
22036 (nds32_expand_movmemsi): ... to this.
22037
22038 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22039 Monk Chiang <sh.chiang04@gmail.com>
22040 Chung-Ju Wu <jasonwucj@gmail.com>
22041
22042 * config/nds32/nds32-protos.h
22043 (nds32_expand_load_multiple): New arguments.
22044 (nds32_expand_store_multiple): Ditto.
22045 (nds32_valid_multiple_load_store): Rename ...
22046 (nds32_valid_multiple_load_store_p): ... to this.
22047 * config/nds32/nds32-memory-manipulation.c
22048 (nds32_expand_load_multiple): Refine implementation.
22049 (nds32_expand_store_multiple): Ditto.
22050 * config/nds32/nds32-multiple.md
22051 (load_multiple): Update nds32_expand_load_multiple interface.
22052 (store_multiple): Update nds32_expand_store_multiple interface.
22053 * config/nds32/nds32-predicates.c
22054 (nds32_valid_multiple_load_store): Rename ...
22055 (nds32_valid_multiple_load_store_p): ... to this and refine
22056 implementation.
22057 * config/nds32/predicates.md
22058 (nds32_load_multiple_and_update_address_operation): New predicate.
22059 (nds32_store_multiple_and_update_address_operation): New predicate.
22060
22061 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22062 Chung-Ju Wu <jasonwucj@gmail.com>
22063
22064 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
22065 (combo): New attribute.
22066 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
22067
22068 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
22069
22070 * config/nds32/nds32.opt: Change -mcmodel= default value.
22071
22072 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
22073 Monk Chiang <sh.chiang04@gmail.com>
22074 Chung-Ju Wu <jasonwucj@gmail.com>
22075
22076 * config/nds32/constants.md (unspec_element): New enum.
22077 * config/nds32/constraints.md (Umw): New constraint.
22078 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
22079 * config/nds32/nds32-intrinsic.md: Likewise.
22080 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
22081 (nds32_valid_smw_lwm_base_p): New.
22082 (nds32_output_smw_single_word): New.
22083 (nds32_output_lmw_single_word): New.
22084 (nds32_expand_unaligned_load): New.
22085 (nds32_expand_unaligned_store): New.
22086 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
22087 (nds32_output_smw_single_word): Declare.
22088 (nds32_output_lmw_single_word): Declare.
22089 (nds32_expand_unaligned_load): Declare.
22090 (nds32_expand_unaligned_store): Declare.
22091 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
22092 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
22093 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
22094 NDS32_BUILTIN_UASTORE_DW.
22095 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
22096 predicate.
22097
22098 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
22099 Kito Cheng <kito.cheng@gmail.com>
22100 Chung-Ju Wu <jasonwucj@gmail.com>
22101
22102 * config/nds32/nds32-intrinsic.c
22103 (nds32_expand_builtin_null_ftype_reg): Delete.
22104 (nds32_expand_builtin_reg_ftype_imm): Ditto.
22105 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
22106 (nds32_read_argument): New.
22107 (nds32_legitimize_target): Ditto.
22108 (nds32_legitimize_argument): Ditto.
22109 (nds32_check_constant_argument): Ditto.
22110 (nds32_expand_unop_builtin): Ditto.
22111 (nds32_expand_unopimm_builtin): Ditto.
22112 (nds32_expand_binop_builtin): Ditto.
22113 (nds32_builtin_decl_impl): Ditto.
22114 (builtin_description): Ditto.
22115 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
22116 (nds32_init_builtins_impl): Ditto.
22117 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
22118 (nds32_builtin_decl): New.
22119 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
22120 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
22121
22122 2018-03-02 Jeff Law <law@redhat.com>
22123
22124 * reorg.c (stop_search_p): Handle DEBUG_INSN.
22125 (redundant_insn, fill_simple_delay_slots): Likewise.
22126 (fill_slots_from_thread): Likewise.
22127 * resource.c (mark_referenced_resources): Likewise.
22128 (mark_set_resources, find_dead_or_set_registers): Likewise.
22129
22130 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22131
22132 * substring-locations.h (format_warning_va): Formatting fix for
22133 ATTRIBUTE_GCC_DIAG.
22134 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
22135 argument.
22136 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
22137 * substring-locations.c: Include intl.h.
22138 (format_warning_va): Turned into small wrapper around
22139 format_warning_n_va, renamed to ...
22140 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
22141 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
22142 use ngettext.
22143 (format_warning_at_substring_n): New function.
22144 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
22145 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
22146 format_warning_at_substring with just a shorter name instead of
22147 const function pointer.
22148 (fmtwarn_n): New function.
22149 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
22150 appropriate, get rid of all the fmtstr temporaries, move conditionals
22151 with G_() wrapped string literals directly into fmtwarn arguments,
22152 cast dir.len to (int), formatting fixes.
22153
22154 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
22155
22156 * doc/invoke.texi: Remove "Cilk Plus" references.
22157
22158 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22159 Richard Biener <rguenther@suse.de>
22160
22161 PR ipa/84628
22162 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
22163 for error or warning attributes if CALL_FROM_THUNK_P is set.
22164 Formatting fixes.
22165
22166 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22167
22168 PR target/56540
22169 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
22170 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
22171
22172 PR target/56540
22173 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
22174 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
22175
22176 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
22177 instead of -1U in last predictors element's probability member.
22178
22179 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
22180
22181 PR ipa/83983
22182 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
22183 arguments if they are comparable.
22184
22185 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22186
22187 PR tree-optimization/84634
22188 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
22189 masks and masked_loop_p with a single loop_masks, making sure it's
22190 null for bb vectorization.
22191
22192 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22193
22194 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
22195 (vect_analyze_data_ref_access): Use loop->safe_len rather than
22196 loop->force_vectorize to check whether there is no alias.
22197
22198 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22199
22200 PR target/84614
22201 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
22202 prototypes.
22203 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
22204 comments.
22205 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
22206 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
22207 instead of a loop around prev_real_insn.
22208 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
22209 prev_real_insn.
22210
22211 PR inline-asm/84625
22212 * config/i386/i386.c (ix86_print_operand): Use conditional
22213 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
22214 zero vector.
22215
22216 2018-03-02 Richard Biener <rguenther@suse.de>
22217
22218 PR tree-optimization/84427
22219 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
22220 (bitmap_set_subtract_values): Rewrite to handle multiple
22221 exprs per value.
22222 (clean): Likewise.
22223 (prune_clobbered_mems): Likewise.
22224 (phi_translate): Take edge instead of pred/phiblock.
22225 (phi_translate_1): Likewise.
22226 (phi_translate_set): Likewise. Insert all translated
22227 exprs for a value into the set, keeping possibly multiple
22228 expressions per value.
22229 (compute_antic_aux): Adjust for phi_translate changes.
22230 When intersecting union the expressions and prune those
22231 not in the final value set, keeping possibly multiple
22232 expressions per value. Do not use value-insertion
22233 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
22234 all expressions. Add verification that the value-sets
22235 only shrink during iteration.
22236 (compute_partial_antic_aux): Adjust for the phi_translate changes.
22237 (do_pre_regular_insertion): Likewise.
22238 (do_pre_partial_partial_insertion): Likewise.
22239
22240 2018-03-02 Richard Biener <rguenther@suse.de>
22241
22242 PR target/82005
22243 * config/darwin.c (saved_debug_info_level): New static global.
22244 (darwin_asm_lto_start): Disable debug info generation for LTO out.
22245 (darwin_asm_lto_end): Restore debug info generation settings.
22246
22247 2018-03-01 Martin Liska <mliska@suse.cz>
22248
22249 PR sanitizer/82484
22250 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
22251 volatile arguments.
22252
22253 2018-03-01 Richard Biener <rguenther@suse.de>
22254
22255 PR debug/84645
22256 * dwarf2out.c (gen_variable_die): Properly handle late VLA
22257 type annotation with LTO when debug was disabled at compile-time.
22258
22259 2018-03-01 Matthew Fortune <mfortune@gmail.com>
22260
22261 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
22262 XINT with INTVAL.
22263 (mips_final_postscan_insn): Likewise.
22264
22265 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
22266
22267 PR rtl-optimization/84528
22268 * alias.c (init_alias_target): Add commentary.
22269 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
22270 a unique base value if the frame pointer is not eliminated
22271 to the stack pointer.
22272
22273 2018-03-01 Tom de Vries <tom@codesourcery.com>
22274
22275 PR rtl-optimization/83327
22276 * lra-int.h (hard_regs_spilled_into): Declare.
22277 * lra.c (hard_regs_spilled_into): Define.
22278 (init_reg_info): Init hard_regs_spilled_into.
22279 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
22280 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
22281 (process_bb_lives): Handle hard_regs_spilled_into.
22282 (lra_create_live_ranges_1): Before doing liveness propagation, clear
22283 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
22284
22285 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
22286
22287 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
22288 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
22289 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
22290 * config/rs6000/aix72.h: New file.
22291
22292 2018-02-28 Jakub Jelinek <jakub@redhat.com>
22293
22294 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
22295 instead of warning_at with conditional singular and plural messages
22296 where possible.
22297
22298 PR target/52991
22299 * stor-layout.c (update_alignment_for_field): For
22300 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
22301 && !DECL_PACKED (field), do the alignment update, just use
22302 only desired_align instead of MAX (type_align, desired_align)
22303 as the alignment.
22304 (place_field): Don't do known_align < desired_align handling
22305 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
22306 is non-NULL, instead do it after rli->prev_field handling and
22307 only if not within a bitfield word. For DECL_PACKED (field)
22308 use type_align of BITS_PER_UNIT.
22309
22310 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
22311
22312 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
22313 superfluous parentheses and trailing spaces.
22314
22315 2018-02-28 Richard Biener <rguenther@suse.de>
22316
22317 PR tree-optimization/84584
22318 * graphite-scop-detection.c (scop_detection::add_scop): Discard
22319 SCoPs with fake exit edge.
22320
22321 2018-02-28 Martin Liska <mliska@suse.cz>
22322
22323 PR testsuite/84597
22324 * timevar.c (timer::print): Fix format to properly print 100%
22325 values.
22326
22327 2018-02-28 Richard Biener <rguenther@suse.de>
22328
22329 PR middle-end/84607
22330 * genmatch.c (capture_info::walk_match): Do not mark
22331 captured expressions without operands as expr_p given
22332 they act more like predicates and should be subject to
22333 "lost tail" side-effect preserving.
22334
22335 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
22336
22337 PR rtl-optimization/81611
22338 * auto-inc-dec.c (attempt_change): Move dead note from
22339 mem_insn if it's the next use of regno
22340 (find_address): Take address use of reg holding
22341 non-incremented value. Add parm to limit search to the named
22342 reg only.
22343 (merge_in_block): Attempt to use a mem insn that is the next
22344 use of the original regno.
22345
22346 2018-02-27 Martin Sebor <msebor@redhat.com>
22347
22348 PR c++/83871
22349 * doc/invoke.texi (-Wmissing-attributes): New option.
22350 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
22351
22352 2018-02-27 Martin Sebor <msebor@redhat.com>
22353
22354 PR translation/84207
22355 * diagnostic-core.h (warning_n, error_n, inform_n): Change
22356 n argument to unsigned HOST_WIDE_INT.
22357 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
22358 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
22359 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
22360 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
22361
22362 2018-02-27 Richard Biener <rguenther@suse.de>
22363
22364 PR tree-optimization/84512
22365 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
22366 Do not use the estimate returned from record_stmt_cost for
22367 the scalar iteration cost but sum properly using add_stmt_cost.
22368
22369 2018-02-27 Richard Biener <rguenther@suse.de>
22370
22371 PR tree-optimization/84466
22372 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
22373 Adjust last change to less strictly validate use operands.
22374
22375 2018-02-27 Martin Liska <mliska@suse.cz>
22376
22377 PR gcov-profile/84548
22378 * gcov.c (process_file): Allow partial overlap and consider it
22379 also as group functions.
22380 (output_lines): Properly calculate range of lines for a group.
22381
22382 2018-02-27 Martin Liska <mliska@suse.cz>
22383
22384 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
22385 'ggc' suffixes. Change first column width.
22386 (timer::print): Fix formatting of the column.
22387
22388 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
22389
22390 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
22391 preserve inline entry blocks for the sake of debug inline
22392 entry point markers alone.
22393 (remove_unused_locals): Suggest in comments a better place to
22394 force the preservation of inline entry blocks that are
22395 otherwise unused, but do not preserve them.
22396
22397 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22398
22399 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
22400
22401 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22402
22403 PR target/84039
22404 * config/i386/constraints.md (Bs): Replace
22405 ix86_indirect_branch_register with
22406 TARGET_INDIRECT_BRANCH_REGISTER.
22407 (Bw): Likewise.
22408 * config/i386/i386.md (indirect_jump): Likewise.
22409 (tablejump): Likewise.
22410 (*sibcall_memory): Likewise.
22411 (*sibcall_value_memory): Likewise.
22412 Peepholes of indirect call and jump via memory: Likewise.
22413 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
22414 (*sibcall_value_GOT_32): Likewise.
22415 * config/i386/predicates.md (indirect_branch_operand): Likewise.
22416 (GOT_memory_operand): Likewise.
22417 (call_insn_operand): Likewise.
22418 (sibcall_insn_operand): Likewise.
22419 (GOT32_symbol_operand): Likewise.
22420 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
22421
22422 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22423
22424 PR rtl-optimization/83496
22425 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
22426 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
22427 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
22428 redundant insn, if any.
22429 (relax_delay_slots): Likewise.
22430 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
22431
22432 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
22433
22434 PR tree-optimization/83965
22435 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
22436 that grouped statements are part of a reduction chain. Return
22437 true if the statement is not marked as a reduction itself but
22438 is part of a group.
22439 (vect_recog_dot_prod_pattern): Don't check whether the statement
22440 is part of a group here.
22441 (vect_recog_sad_pattern): Likewise.
22442 (vect_recog_widen_sum_pattern): Likewise.
22443
22444 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22445
22446 PR debug/84545
22447 * final.c (rest_of_clean_state): Also look for calls inside sequences.
22448
22449 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22450
22451 PR target/84530
22452 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
22453 the bool argument.
22454 (ix86_output_indirect_function_return): New prototype.
22455 (ix86_split_simple_return_pop_internal): Likewise.
22456 * config/i386/i386.c (indirect_return_via_cx): New.
22457 (indirect_return_via_cx_bnd): Likewise.
22458 (indirect_thunk_name): Handle return va CX_REG.
22459 (output_indirect_thunk_function): Create alias for
22460 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
22461 (ix86_output_indirect_jmp): Remove the bool argument.
22462 (ix86_output_indirect_function_return): New function.
22463 (ix86_split_simple_return_pop_internal): Likewise.
22464 * config/i386/i386.md (*indirect_jump): Don't pass false
22465 to ix86_output_indirect_jmp.
22466 (*tablejump_1): Likewise.
22467 (simple_return_pop_internal): Change it to define_insn_and_split.
22468 Call ix86_split_simple_return_pop_internal to split it for
22469 -mfunction-return=.
22470 (simple_return_indirect_internal): Call
22471 ix86_output_indirect_function_return instead of
22472 ix86_output_indirect_jmp.
22473
22474 2018-02-26 Jakub Jelinek <jakub@redhat.com>
22475
22476 PR bootstrap/84405
22477 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
22478 memset and value initialization afterwards.
22479
22480 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
22481
22482 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
22483
22484 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
22485
22486 PR target/84521
22487 * common/config/aarch64/aarch64-common.c
22488 (aarch_option_optimization_table[]): Switch
22489 off fomit-frame-pointer
22490
22491 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22492 Chung-Ju Wu <jasonwucj@gmail.com>
22493
22494 * config/nds32/nds32-multiple.md (load_multiple): Disallow
22495 volatile memory.
22496 (store_multiple): Ditto.
22497
22498 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22499
22500 * config.gcc: Add --with-cpu support for nds32 target.
22501 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
22502 * config/nds32/nds32.opt: Add -mcpu= option.
22503
22504 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
22505
22506 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
22507 isel=yes): Warn for these deprecated options.
22508
22509 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
22510
22511 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
22512 ISA_2_5_MASKS_EMBEDDED.
22513
22514 2018-02-23 Jakub Jelinek <jakub@redhat.com>
22515
22516 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
22517 p->max as pointers rather than using iterative_hash_expr.
22518
22519 2018-02-23 Carl Love <cel@us.ibm.com>
22520
22521 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
22522 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
22523 BU_P8V_OVERLOAD_2.
22524 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
22525 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
22526 P8V_BUILTIN_VEC_VUNSIGNED2.
22527
22528 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
22529
22530 PR target/81572
22531 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
22532 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
22533 LRA_UNKNOWN_ALT.
22534 * lra-constraints.c (curr_insn_transform): Set up
22535 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
22536 LRA_UNKNOWN_ALT.
22537 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
22538 * lra-eliminations.c (spill_pseudos): Ditto.
22539 (process_insn_for_elimination): Ditto.
22540 * lra-lives.c (reg_early_clobber_p): Use the new macros.
22541 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
22542 LRA_NON_CLOBBERED_ALT.
22543
22544 2018-02-22 Martin Sebor <msebor@redhat.com>
22545
22546 PR tree-optimization/84480
22547 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
22548 to maybe_diag_stxncpy_trunc. Call it.
22549 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
22550 from gimple_fold_builtin_strcpy. Print inlining stack.
22551 (handle_builtin_stxncpy): Print inlining stack.
22552 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
22553
22554 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
22555
22556 PR target/84176
22557 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
22558 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
22559 and -fcheck-pointer-bounds are used together.
22560 (indirect_thunk_prefix): New enum.
22561 (indirect_thunk_need_prefix): New function.
22562 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
22563 "_nt" instead of "_bnd" for NOTRACK prefix.
22564 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
22565 (output_indirect_thunk_function): Likewise.
22566 (): Likewise.
22567 (ix86_code_end): Update output_indirect_thunk_function calls.
22568 (ix86_output_indirect_branch_via_reg): Replace
22569 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
22570 (ix86_output_indirect_branch_via_push): Likewise.
22571 (ix86_output_function_return): Likewise.
22572 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
22573 incompatible with -fcf-protection=branch and
22574 -fcheck-pointer-bounds.
22575
22576 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22577
22578 PR target/83335
22579 * config/aarch64/aarch64.c (aarch64_print_address_internal):
22580 Change gcc_assert call to output_operand_lossage.
22581
22582 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22583
22584 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
22585
22586 2018-02-22 DJ Delorie <dj@redhat.com>
22587 Sebastian Perta <sebastian.perta@renesas.com>
22588 Oleg Endo <olegendo@gcc.gnu.org>
22589
22590 * config/rx/rx.c (rx_rtx_costs): New function.
22591 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
22592
22593 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
22594
22595 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
22596
22597 2018-02-22 Martin Liska <mliska@suse.cz>
22598
22599 PR driver/83193
22600 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
22601 Add "native" as a possible value.
22602
22603 2018-02-22 Martin Liska <mliska@suse.cz>
22604
22605 PR driver/83193
22606 * config/i386/i386.c (ix86_option_override_internal):
22607 Add "native" as a possible value for -march and -mtune.
22608
22609 2018-02-22 Jakub Jelinek <jakub@redhat.com>
22610
22611 PR target/84502
22612 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
22613 to all type variants.
22614
22615 PR tree-optimization/84503
22616 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
22617 width as info->bitpos + info->bitsize - start.
22618 (merged_store_group::merge_overlapping): Simplify width computation.
22619 (check_no_overlap): New function.
22620 (imm_store_chain_info::try_coalesce_bswap): Compute expected
22621 start + width and last_order of the group, fail if check_no_overlap
22622 fails.
22623 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
22624 to group if check_no_overlap fails.
22625
22626 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22627
22628 * config/rs6000/altivec.md: Delete contraint arguments to
22629 define_expand, define_split, and define_peephole2, and in
22630 define_insn_and_split if always unused.
22631 * config/rs6000/darwin.md: Ditto.
22632 * config/rs6000/dfp.md: Ditto.
22633 * config/rs6000/rs6000.md: Ditto.
22634 * config/rs6000/sync.md: Ditto.
22635 * config/rs6000/vector.md: Ditto.
22636 * config/rs6000/vsx.md: Ditto.
22637
22638 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22639
22640 * config/rs6000/altivec.md: Write output control strings as braced
22641 blocks instead of double-quoted strings.
22642 * config/rs6000/darwin.md: Ditto.
22643 * config/rs6000/rs6000.md: Ditto.
22644 * config/rs6000/vector.md: Ditto.
22645 * config/rs6000/vsx.md: Ditto.
22646
22647 2018-02-21 Jason Merrill <jason@redhat.com>
22648
22649 PR c++/84314 - ICE with templates and fastcall attribute.
22650 * attribs.c (build_type_attribute_qual_variant): Remove assert.
22651
22652 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22653
22654 * ipa-cp.c (determine_versionability): Fix comment typos.
22655
22656 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22657
22658 PR c/84229
22659 * ipa-cp.c (determine_versionability): Do not version functions caling
22660 va_arg_pack.
22661
22662 2018-02-21 Martin Liska <mliska@suse.cz>
22663
22664 PR driver/83193
22665 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
22666 Add "native" as a possible value.
22667 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
22668 the macro when native cpu detection is available.
22669
22670 2018-02-21 Martin Liska <mliska@suse.cz>
22671
22672 PR driver/83193
22673 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
22674 Add "native" as a possible value.
22675 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
22676 when native cpu detection is available.
22677
22678 2018-02-21 Jakub Jelinek <jakub@redhat.com>
22679 Martin Sebor <msebor@redhat.com>
22680
22681 PR tree-optimization/84478
22682 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
22683 false.
22684 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
22685 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
22686 support which is conservatively correct, for 2 only stay conservative
22687 for maxlen. Formatting and comment capitalization fixes. Add STRICT
22688 argument to the 2 argument get_range_strlen, adjust 6 arg
22689 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
22690 false.
22691 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
22692 (gimple_fold_builtin_strlen): Pass true as last argument to
22693 get_range_strlen.
22694
22695 2018-02-20 Martin Sebor <msebor@redhat.com>
22696
22697 PR middle-end/84095
22698 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
22699 (builtin_memref::set_base_and_offset): Same. Handle inner references.
22700 (builtin_memref::builtin_memref): Factor out parts into
22701 set_base_and_offset and call it.
22702
22703 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22704
22705 PR middle-end/84406
22706 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
22707 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
22708 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
22709 search at the associated MODE_INT.
22710
22711 2018-02-20 Jeff Law <law@redhat.com>
22712
22713 PR middle-end/82123
22714 PR tree-optimization/81592
22715 PR middle-end/79257
22716 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
22717 for range data rather than using global data.
22718 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
22719 range data rather than using global data.
22720 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
22721 pass it to children as needed.
22722 (struct directive::fmtresult): Similarly.
22723 (struct directive::set_width): Similarly.
22724 (struct directive::set_precision): Similarly.
22725 (format_integer, format_directive, parse_directive): Similarly.
22726 (format_none): Accept unnamed vr_values parameter.
22727 (format_percent, format_floating, format_character): Similarly.
22728 (format_string, format_plain): Similarly.
22729 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
22730 the EVRP range analyzer for range data rather than using global data.
22731 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
22732 gimple-ssa-evrp-analyze.h
22733 (class sprintf_dom_walker): Add after_dom_children member function.
22734 Add evrp_range_analyzer member.
22735 (sprintf_dom_walker::before_dom_children): Call into the EVRP
22736 range analyzer as needed.
22737 (sprintf_dom_walker::after_dom_children): New member function.
22738 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
22739 if not optimizing.
22740 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
22741 (evrp_range_analyzer::pop_to_marker): Likewise.
22742
22743 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22744
22745 PR tree-optimization/84419
22746 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
22747 with the required type if its current type is compatible but
22748 different.
22749
22750 2018-02-20 Jakub Jelinek <jakub@redhat.com>
22751
22752 PR middle-end/82004
22753 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
22754 after vectorization.
22755
22756 2018-02-20 Martin Liska <mliska@suse.cz>
22757
22758 PR driver/83193
22759 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
22760 possible values if we don't have a hint.
22761
22762 2018-02-20 Martin Liska <mliska@suse.cz>
22763
22764 PR c/84310
22765 PR target/79747
22766 * final.c (shorten_branches): Build align_tab array with one
22767 more element.
22768 * opts.c (finish_options): Add alignment option limit check.
22769 (MAX_CODE_ALIGN): Likewise.
22770 (MAX_CODE_ALIGN_VALUE): Likewise.
22771 * doc/invoke.texi: Document maximum allowed option value for
22772 all -falign-* options.
22773
22774 2018-02-19 Jakub Jelinek <jakub@redhat.com>
22775
22776 PR target/84146
22777 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
22778 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
22779 * var-tracking.c (emit_note_insn_var_location): Remove all references
22780 to NOTE_INSN_CALL_ARG_LOCATION.
22781 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
22782 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
22783 Use copy_rtx_if_shared.
22784 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
22785 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
22786 (dwarf2out_var_location): Remove handling of
22787 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
22788 on call_insn.
22789 * final.c (final_scan_insn): Remove all references to
22790 NOTE_INSN_CALL_ARG_LOCATION.
22791 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
22792 before dumping final insns.
22793 * except.c (emit_note_eh_region_end): Remove all references to
22794 NOTE_INSN_CALL_ARG_LOCATION.
22795 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
22796 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
22797 * config/arc/arc.c (hwloop_optimize): Likewise.
22798 * config/arm/arm.c (create_fix_barrier): Likewise.
22799 * config/s390/s390.c (s390_chunkify_start): Likewise.
22800 * config/sh/sh.c (find_barrier): Likewise.
22801 * config/i386/i386.c (rest_of_insert_endbranch,
22802 ix86_seh_fixup_eh_fallthru): Likewise.
22803 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
22804 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
22805 * config/frv/frv.c (frv_function_prologue): Likewise.
22806 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
22807 reg note.
22808 (note_outside_basic_block_p): Remove all references to
22809 NOTE_INSN_CALL_ARG_LOCATION.
22810 * gengtype.c (adjust_field_rtx_def): Likewise.
22811 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
22812 Likewise.
22813 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
22814 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
22815
22816 PR c++/84444
22817 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
22818 is ADDR_EXPR.
22819
22820 PR tree-optimization/84452
22821 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
22822 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
22823 is NULL.
22824
22825 2018-02-19 Martin Liska <mliska@suse.cz>
22826
22827 PR sanitizer/82183
22828 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
22829
22830 2018-02-19 Martin Liska <mliska@suse.cz>
22831 Richard Sandiford <richard.sandiford@linaro.org>
22832
22833 PR tree-optimization/82491
22834 * gimple-fold.c (get_base_constructor): Make earlier bail out
22835 to prevent ubsan.
22836
22837 2018-02-19 Carl Love <cel@us.ibm.com>
22838
22839 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
22840 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
22841 BU_P8V_OVERLOAD_1.
22842 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
22843 P8V_BUILTIN_VEC_NEG.
22844
22845 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
22846
22847 * config/rl78/rl78.md (movdf): New define expand.
22848
22849 2018-02-19 Martin Liska <mliska@suse.cz>
22850
22851 PR other/80589
22852 * doc/invoke.texi: Fix typo.
22853 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
22854
22855 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
22856
22857 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
22858 handle rs6000_single_float and rs6000_double_float specially for
22859 e500 family CPUs.
22860
22861 2018-02-16 Jeff Law <law@redhat.com>
22862
22863 * config/rx/rx.c (add_pop_cfi_notes): New function.;
22864 (pop_regs): Use it.
22865
22866 2018-02-16 Jakub Jelinek <jakub@redhat.com>
22867
22868 PR ipa/84425
22869 * ipa-inline.c (inline_small_functions): Fix a typo.
22870
22871 2018-02-16 Nathan Sidwell <nathan@acm.org>
22872
22873 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
22874
22875 2018-02-16 Carl Love <cel@us.ibm.com>
22876
22877 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
22878 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
22879 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
22880 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
22881 expansion to P8V_BUILTIN_VEC_FLOAT2.
22882
22883 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
22884
22885 PR rtl-optimization/70023
22886 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
22887 src_regno into account.
22888
22889 2018-02-16 Carl Love <cel@us.ibm.com>
22890
22891 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
22892 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
22893 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
22894 * config/rs6000/rs6000.c: Remove case statements for
22895 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
22896 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
22897 and P9V_BUILTIN_VEC_VINSERT4B.
22898 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
22899 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
22900 * config/rs6000/vsx.md:
22901 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
22902 vec_insert4b.
22903
22904 2018-02-16 Carl Love <cel@us.ibm.com>
22905
22906 * config/rs6000/altivec.h: Add builtin names vec_extract4b
22907 vec_insert4b.
22908 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
22909 definitions.
22910 * config/rs6000/rs6000-c.c: Add the definitions for
22911 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
22912 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
22913 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
22914 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
22915 definition for insert4b and define insn *insert3b_internal.
22916 * doc/extend.texi: Add documentation for vec_extract4b.
22917
22918 2018-02-16 Nathan Sidwell <nathan@acm.org>
22919
22920 * doc/extend.texi (Backwards Compatibility): Mention friend
22921 injection. Note for-scope is deprecated.
22922 * doc/invoke.texi (-ffriend-injection): Deprecate.
22923
22924 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
22925
22926 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
22927 that moved to I2, also allow destinations that are a paradoxical
22928 subreg (instead of a normal reg).
22929
22930 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
22931
22932 PR target/83831
22933 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
22934 to QImode.
22935
22936 2018-02-16 Richard Biener <rguenther@suse.de>
22937
22938 PR tree-optimization/84037
22939 PR tree-optimization/84016
22940 PR target/82862
22941 * config/i386/i386.c (ix86_builtin_vectorization_cost):
22942 Adjust vec_construct for the fact we need additional higher latency
22943 128bit inserts for AVX256 and AVX512 vector builds.
22944 (ix86_add_stmt_cost): Scale vector construction cost for
22945 elementwise loads.
22946
22947 2018-02-16 Richard Biener <rguenther@suse.de>
22948
22949 PR tree-optimization/84417
22950 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
22951 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
22952 (non_rewritable_lvalue_p): Likewise, use poly-ints.
22953
22954 2018-02-16 Martin Liska <mliska@suse.cz>
22955
22956 PR sanitizer/84307
22957 * internal-fn.def (ASAN_CHECK): Set proper flags.
22958 (ASAN_MARK): Likewise.
22959
22960 2018-02-16 Julia Koval <julia.koval@intel.com>
22961
22962 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
22963 from PTA_CANNONLAKE.
22964
22965 2018-02-16 Jakub Jelinek <jakub@redhat.com>
22966
22967 PR target/84272
22968 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
22969 Use ++iter rather than iter++ for std::list iterators.
22970 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
22971 defer deleting them until all nodes in the forest are processed. Do
22972 free even leaf nodes. Change to_process into auto_vec.
22973
22974 PR bootstrap/84405
22975 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
22976 * vec.h (vec_default_construct): Use memset instead of placement new
22977 if BROKEN_VALUE_INITIALIZATION is defined.
22978 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
22979 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
22980 is defined.
22981
22982 PR rtl-optimization/83723
22983 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
22984 * lra.c (lra_substitute_pseudo): Likewise. If true, use
22985 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
22986 recursive calls.
22987 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
22988 callers.
22989 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
22990
22991 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
22992
22993 PR rtl-optimization/81443
22994 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
22995 from inner REGs to paradoxical SUBREGs.
22996
22997 2018-02-16 Richard Biener <rguenther@suse.de>
22998
22999 PR tree-optimization/84399
23000 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
23001 For operands we can analyze at their definition make sure we can
23002 analyze them at each use as well.
23003
23004 2018-02-16 Richard Biener <rguenther@suse.de>
23005
23006 PR tree-optimization/84190
23007 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
23008 volatile accesses if the decl isn't volatile.
23009
23010 2018-02-15 Jason Merrill <jason@redhat.com>
23011
23012 PR c++/84314 - ICE with templates and fastcall attribute.
23013 * attribs.c (build_type_attribute_qual_variant): Don't clobber
23014 TYPE_CANONICAL on an existing type.
23015
23016 2018-02-15 Jakub Jelinek <jakub@redhat.com>
23017
23018 PR tree-optimization/84383
23019 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
23020 dstoff nor call operand_equal_p if dstbase is NULL.
23021
23022 PR tree-optimization/84334
23023 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
23024 also a CONSTANT_CLASS_P, punt.
23025
23026 2018-02-14 Jim Wilson <jimw@sifive.com>
23027
23028 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
23029 first SMALL_OPERAND check. New local min_second_step. Move assert
23030 to where locals are set. Add TARGET_RVC support.
23031 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
23032
23033 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
23034
23035 * doc/invoke.texi: Correct -Wformat-overflow code sample.
23036
23037 2018-02-14 Martin Sebor <msebor@redhat.com>
23038
23039 PR tree-optimization/83698
23040 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
23041 arrays constrain the offset range to their bounds.
23042 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
23043 (builtin_access::overlap): Avoid setting the size of overlap if it's
23044 already been set.
23045 (maybe_diag_overlap): Also consider arrays when deciding what values
23046 of offsets to include in diagnostics.
23047
23048 2018-02-14 Martin Sebor <msebor@redhat.com>
23049
23050 PR c/84108
23051 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
23052 that correspond to the kind of a declaration.
23053
23054 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
23055
23056 PR target/83984
23057 * config/pa/pa.md: Load address of PIC label using the linkage table
23058 if the label is nonlocal.
23059
23060 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
23061
23062 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
23063 warning message if user requests -maltivec=be.
23064 * doc/invoke.texi: Document deprecation of -maltivec=be.
23065
23066 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
23067
23068 PR target/84220
23069 * config/rs6000/rs6000-c.c: Update definitions for
23070 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
23071 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
23072
23073 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
23074
23075 PR target/84239
23076 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
23077 add _get_ssp intrinsics. Remove argument from
23078 __builtin_ia32_rdssp[d|q].
23079 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
23080 * config/i386/i386-builtin.def: Remove argument from
23081 __builtin_ia32_rdssp[d|q].
23082 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
23083 ix86_expand_special_args_builtin for _rdssp[d|q].
23084 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
23085 Clear register before usage.
23086 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
23087 Add documentation for new _get_ssp and _inc_ssp intrinsics.
23088
23089 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
23090
23091 PR tree-optimization/84357
23092 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
23093 operand 1 of an ARRAY_REF too.
23094
23095 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
23096
23097 PR target/83831
23098 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
23099 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23100 declarations.
23101 (set_of_reg): New struct.
23102 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
23103 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
23104 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23105 functions.
23106 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
23107 Split into bitclr, bitset, bitinvert patterns if appropriate.
23108 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
23109 use rx_fuse_in_memory_bitop.
23110 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
23111 to named insn, correct maximum insn length.
23112
23113 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
23114
23115 PR target/79242
23116 * machmode.def: Define a complex mode for PARTIAL_INT.
23117 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
23118 MODE_PARTIAL_INT.
23119 * doc/rtl.texi: Document CSPImode.
23120 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
23121 handling.
23122 (msp430_hard_regno_nregs_with_padding): Likewise.
23123
23124 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
23125
23126 PR target/84279
23127 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
23128
23129 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
23130
23131 PR rtl-optimization/84169
23132 * combine.c (try_combine): New variable split_i2i3. Set it to true if
23133 we generated a parallel as new i3 and we split that to new i2 and i3
23134 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
23135 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
23136 those to i2, not i1. Partially rewrite this scan code.
23137
23138 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23139
23140 PR c/82210
23141 * stor-layout.c (place_field): For variable length fields, adjust
23142 offset_align afterwards not just based on the field's alignment,
23143 but also on the size.
23144
23145 PR middle-end/84309
23146 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
23147 of exps and logs in the use_exp2 case.
23148
23149 2018-02-13 Jeff Law <law@redhat.com>
23150
23151 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
23152 entry for "vector".
23153
23154 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
23155 ARGS as unused.
23156
23157 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
23158
23159 PR debug/84342
23160 PR debug/84319
23161 * common.opt (gas-loc-support, gas-locview-support): New.
23162 (ginline-points, ginternal-reset-location-views): New.
23163 * doc/invoke.texi: Document them. Use @itemx where intended.
23164 (gvariable-location-views): Adjust.
23165 * target.def (reset_location_view): New.
23166 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
23167 (TARGET_RESET_LOCATION_VIEW): New.
23168 * doc/tm.texi: Rebuilt.
23169 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
23170 (dwarf2out_default_as_locview_support): New.
23171 (output_asm_line_debug_info): Use option variables.
23172 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
23173 (output_loc_list): Likewise.
23174 (add_high_low_attributes): Check option variables.
23175 Don't output entry view attribute in strict mode.
23176 (gen_inlined_subroutine_die): Check option variables.
23177 (dwarf2out_inline_entry): Likewise.
23178 (init_sections_and_labels): Likewise.
23179 (dwarf2out_early_finish): Likewise.
23180 (maybe_reset_location_view): New, from...
23181 (dwarf2out_var_location): ... here. Call it.
23182 * debug.h (dwarf2out_default_as_loc_support): Declare.
23183 (dwarf2out_default_as_locview_support): Declare.
23184 * hooks.c (hook_int_rtx_insn_0): New.
23185 * hooks.h (hook_int_rtx_insn_0): Declare.
23186 * toplev.c (process_options): Take -gas-loc-support and
23187 -gas-locview-support from dwarf2out. Enable
23188 -gvariable-location-views by default only with locview
23189 assembler support. Enable -ginternal-reset-location-views by
23190 default only if the target defines the corresponding hook.
23191 Enable -ginline-points by default if location views are
23192 enabled; force it disabled if statement frontiers are
23193 disabled.
23194 * tree-inline.c (expand_call_inline): Check option variables.
23195 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
23196
23197 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
23198
23199 PR tree-optimization/84321
23200 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
23201 handling. Also check whether the anti-range contains any values
23202 that satisfy the mask; switch to a VR_RANGE if not.
23203
23204 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
23205
23206 PR sanitizer/84340
23207 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
23208
23209 2018-02-13 Martin Jambor <mjambor@suse.cz>
23210
23211 PR c++/83990
23212 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
23213 of call statements, also set location of a load to a temporary.
23214
23215 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
23216
23217 * config/rl78/rl78.c (add_vector_labels): New function.
23218 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
23219 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
23220 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
23221 which checks that no arguments are passed.
23222 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
23223 * doc/extend.texi: Documentation for the new attribute.
23224
23225 2018-02-13 Andreas Schwab <schwab@suse.de>
23226
23227 * config/riscv/linux.h (CPP_SPEC): Define.
23228
23229 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23230
23231 PR target/84335
23232 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
23233 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
23234 OPTION_MASK_ISA_AES as first argument to def_builtin_const
23235 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
23236 instead of OPTION_MASK_ISA_PCLMUL as first argument to
23237 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
23238 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
23239 temporarily for AES and PCLMUL builtins.
23240
23241 PR tree-optimization/84339
23242 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
23243 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
23244 Formatting fixes.
23245
23246 PR middle-end/84309
23247 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
23248 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
23249 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
23250 inline function.
23251 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
23252 inline function.
23253 * omp-simd-clone.h: New file.
23254 * omp-simd-clone.c: Include omp-simd-clone.h.
23255 (expand_simd_clones): No longer static.
23256 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
23257 cgraph.h and omp-simd-clone.h.
23258 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
23259 (vect_recog_widen_shift_pattern): Formatting fix.
23260 (vect_pattern_recog_1): Don't check optab for calls.
23261
23262 PR target/84336
23263 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
23264 operands[2] into a REG before using gen_lowpart on it.
23265
23266 2018-02-12 Jeff Law <law@redhat.com>
23267
23268 PR target/83760
23269 * config/sh/sh.c (find_barrier): Consider a sibling call
23270 a barrier as well.
23271
23272 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
23273 successfully back substituting a reg.
23274
23275 2018-02-12 Richard Biener <rguenther@suse.de>
23276
23277 PR tree-optimization/84037
23278 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
23279 parameter, move visited init to caller.
23280 (vect_slp_analyze_operations): Separate cost from validity
23281 check, initialize visited once for all instances.
23282 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
23283 for all instances.
23284 * tree-vect-stmts.c (vect_model_simple_cost): Make early
23285 out an assert.
23286 (vect_model_promotion_demotion_cost): Likewise.
23287 (vectorizable_bswap): Guard cost modeling with !slp_node
23288 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
23289 SLP stmts.
23290 (vectorizable_call): Likewise.
23291 (vectorizable_conversion): Likewise.
23292 (vectorizable_assignment): Likewise.
23293 (vectorizable_shift): Likewise.
23294 (vectorizable_operation): Likewise.
23295 (vectorizable_store): Likewise.
23296 (vectorizable_load): Likewise.
23297 (vectorizable_condition): Likewise.
23298 (vectorizable_comparison): Likewise.
23299
23300 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
23301
23302 PR sanitizer/84307
23303 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
23304 (ASAN_MARK): Fix fnspec to account for return value, change pointer
23305 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
23306
23307 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23308
23309 PR middle-end/83665
23310 * params.def (inline-min-speedup): Increase from 8 to 15.
23311 (max-inline-insns-auto): Decrease from 40 to 30.
23312 * ipa-split.c (consider_split): Add some buffer for function to
23313 be considered inlining candidate.
23314 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
23315 default values.
23316
23317 2018-02-12 Richard Biener <rguenther@suse.de>
23318
23319 PR tree-optimization/84037
23320 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
23321 matched stmts if we cannot swap the non-matched ones.
23322
23323 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23324
23325 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
23326 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
23327 _mm_maskz_scalef_round_ss): New intrinsics.
23328 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
23329 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
23330 __builtin_ia32_scalefss_round): Remove.
23331 (__builtin_ia32_scalefsd_mask_round,
23332 __builtin_ia32_scalefss_mask_round): New intrinsics.
23333 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
23334 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
23335 ((match_operand:VF_128 2 "<round_nimm_predicate>"
23336 "<round_constraint>")): Changed to ...
23337 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
23338 "<round_scalar_constraint>")): ... this.
23339 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
23340 %0, %1, %2<round_op3>}"): Changed to ...
23341 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
23342 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
23343 %2<round_scalar_mask_op3>}"): ... this.
23344 * config/i386/subst.md (round_scalar_nimm_predicate): New.
23345
23346 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23347
23348 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
23349 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
23350 (_mm_maskz_sqrt_round_ss): New intrinsics.
23351 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
23352 (__builtin_ia32_sqrtsd_mask_round)
23353 (__builtin_ia32_sqrtss_mask_round): New builtins.
23354 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
23355 (__builtin_ia32_sqrtss_round): Remove.
23356 (__builtin_ia32_sqrtsd_mask_round)
23357 (__builtin_ia32_sqrtss_mask_round): New builtins.
23358 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
23359 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
23360 ((match_operand:VF_128 1 "vector_operand"
23361 "xBm,<round_constraint>")): Changed to ...
23362 ((match_operand:VF_128 1 "vector_operand"
23363 "xBm,<round_scalar_constraint>")): ... this.
23364 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
23365 %0, %2, %<iptr>1<round_op3>}): Changed to ...
23366 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
23367 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
23368 %<iptr>1<round_scalar_mask_op3>}): ... this.
23369 ((set_attr "prefix" "<round_prefix>")): Changed to ...
23370 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
23371
23372 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
23373
23374 PR target/84266
23375 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
23376 Cast vec_cmpeq result to correct type.
23377 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
23378 Cast vec_cmpgt result to correct type.
23379
23380 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
23381
23382 * final.c (final_scan_insn_1): Renamed from...
23383 (final_scan_insn): ... this. New wrapper, to recover
23384 seen from the outermost call in recursive ones.
23385 * config/sparc/sparc.c (output_return): Drop seen from call.
23386 (output_sibcall): Likewise.
23387 * config/visium/visium.c (output_branch): Likewise.
23388
23389 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
23390
23391 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
23392 function label.
23393
23394 2018-02-10 Alan Modra <amodra@gmail.com>
23395
23396 PR target/84300
23397 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
23398 Specify LR as an input.
23399
23400 2018-02-10 Jakub Jelinek <jakub@redhat.com>
23401
23402 PR sanitizer/83987
23403 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
23404 remove_member_access_dummy_vars): New functions.
23405 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
23406 lower_omp_1, execute_lower_omp): Use them.
23407
23408 PR rtl-optimization/84308
23409 * shrink-wrap.c (spread_components): Release todo vector.
23410
23411 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
23412
23413 PR rtl-optimization/57193
23414 * ira-color.c (struct allocno_color_data): Add member
23415 conflict_allocno_hard_prefs.
23416 (update_conflict_allocno_hard_prefs): New.
23417 (bucket_allocno_compare_func): Add a preference based on
23418 conflict_allocno_hard_prefs.
23419 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
23420 (color_allocnos): Remove a dead code. Initiate
23421 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
23422
23423 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23424
23425 PR target/84226
23426 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
23427 constraint from =wa to wa. Avoid a subreg on the output operand,
23428 instead use a pseudo and subreg it in a move.
23429 (p9_xxbrd_<mode>): Changed to ...
23430 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
23431 (p9_xxbrd_v2df): New expander.
23432 (p9_xxbrw_<mode>): Changed to ...
23433 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
23434 (p9_xxbrw_v4sf): New expander.
23435
23436 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23437
23438 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
23439
23440 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
23441
23442 PR target/83926
23443 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
23444 multiply in 32-bit mode.
23445 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
23446 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
23447 mode.
23448
23449 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23450
23451 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
23452 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
23453 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
23454 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
23455
23456 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
23457
23458 PR lto/84213
23459 * dwarf2out.c (is_trivial_indirect_ref): New function.
23460 (dwarf2out_late_global_decl): Do not generate a location
23461 attribute for variables that have a non-trivial DECL_VALUE_EXPR
23462 and that are not defined in the current unit.
23463
23464 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23465
23466 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
23467 instead of a libcall for UNORDERED.
23468
23469 2018-02-09 Tamar Christina <tamar.christina@arm.com>
23470
23471 PR target/82641
23472 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
23473 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
23474
23475 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23476
23477 PR target/PR84295
23478 * config/s390/s390.c (s390_set_current_function): Invoke
23479 s390_indirect_branch_settings also if fndecl didn't change.
23480
23481 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23482
23483 * config/rs6000/rs6000.md (blockage): Set length to zero.
23484
23485 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23486
23487 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
23488
23489 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23490
23491 PR sanitizer/84285
23492 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
23493 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
23494 -static-lib*san.
23495
23496 PR debug/84252
23497 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
23498 PARALLEL incoming that failed vt_get_decl_and_offset check.
23499
23500 PR middle-end/84237
23501 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
23502 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
23503 TREE_READONLY bit.
23504 (get_variable_section): For decls in named .bss* sections pass true as
23505 second argument to bss_initializer_p.
23506
23507 2018-02-09 Marek Polacek <polacek@redhat.com>
23508 Jakub Jelinek <jakub@redhat.com>
23509
23510 PR c++/83659
23511 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
23512 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
23513 Sync some changes from cxx_fold_indirect_ref.
23514
23515 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23516
23517 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
23518 markers.
23519 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
23520 (BLOCK_INLINE_ENTRY_LABEL): New.
23521 (dwarf2out_var_location): Disregard inline entry markers.
23522 (inline_entry_data): New struct.
23523 (inline_entry_data_hasher): New hashtable type.
23524 (inline_entry_data_hasher::hash): New.
23525 (inline_entry_data_hasher::equal): New.
23526 (inline_entry_data_table): New variable.
23527 (add_high_low_attributes): Add DW_AT_entry_pc and
23528 DW_AT_GNU_entry_view attributes if a pending entry is found
23529 in inline_entry_data_table. Add old entry_pc attribute only
23530 if debug nonbinding markers are disabled.
23531 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
23532 markers are enabled.
23533 (block_within_block_p, dwarf2out_inline_entry): New.
23534 (dwarf2out_finish): Check that no entries remained in
23535 inline_entry_data_table.
23536 * final.c (reemit_insn_block_notes): Handle inline entry notes.
23537 (final_scan_insn, notice_source_line): Likewise.
23538 (rest_of_clean_state): Skip inline entry markers.
23539 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
23540 markers.
23541 * gimple.c (gimple_build_debug_inline_entry): New.
23542 * gimple.h (enum gimple_debug_subcode): Add
23543 GIMPLE_DEBUG_INLINE_ENTRY.
23544 (gimple_build_debug_inline_entry): Declare.
23545 (gimple_debug_inline_entry_p): New.
23546 (gimple_debug_nonbind_marker_p): Adjust.
23547 * insn-notes.def (INLINE_ENTRY): New.
23548 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
23549 inline entry marker notes.
23550 (print_insn): Likewise.
23551 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
23552 (INSN_DEBUG_MARKER_KIND): Likewise.
23553 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
23554 * tree-inline.c (expand_call_inline): Build and insert
23555 debug_inline_entry stmt.
23556 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
23557 inline entry blocks early, if nonbind markers are enabled.
23558 (dump_scope_block): Dump fragment info.
23559 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
23560 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
23561 (gimple_build_debug_inline_entry): New.
23562 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
23563 Enable/disable inline entry points too.
23564 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
23565 (DEBUG_INSN): Describe inline entry markers.
23566
23567 * common.opt (gvariable-location-views): New.
23568 (gvariable-location-views=incompat5): New.
23569 * config.in: Rebuilt.
23570 * configure: Rebuilt.
23571 * configure.ac: Test assembler for view support.
23572 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
23573 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
23574 * dwarf2out.c (var_loc_view): New typedef.
23575 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
23576 (dwarf2out_locviews_in_attribute): New.
23577 (dwarf2out_locviews_in_loclist): New.
23578 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
23579 (enum dw_line_info_opcode): Add LI_adv_address.
23580 (struct dw_line_info_table): Add view.
23581 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
23582 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
23583 (zero_view_p): New variable.
23584 (ZERO_VIEW_P): New macro.
23585 (output_asm_line_debug_info): New.
23586 (struct var_loc_node): Add view.
23587 (add_AT_view_list, AT_loc_list): New.
23588 (add_var_loc_to_decl): Add view param. Test it against last.
23589 (new_loc_list): Add view params. Record them.
23590 (AT_loc_list_ptr): Handle loc and view lists.
23591 (view_list_to_loc_list_val_node): New.
23592 (print_dw_val): Handle dw_val_class_view_list.
23593 (size_of_die): Likewise.
23594 (value_format): Likewise.
23595 (loc_list_has_views): New.
23596 (gen_llsym): Set vl_symbol too.
23597 (maybe_gen_llsym, skip_loc_list_entry): New.
23598 (dwarf2out_maybe_output_loclist_view_pair): New.
23599 (output_loc_list): Output view list or entries too.
23600 (output_view_list_offset): New.
23601 (output_die): Handle dw_val_class_view_list.
23602 (output_dwarf_version): New.
23603 (output_compilation_unit_header): Use it.
23604 (output_skeleton_debug_sections): Likewise.
23605 (output_rnglists, output_line_info): Likewise.
23606 (output_pubnames, output_aranges): Update version comments.
23607 (output_one_line_info_table): Output view numbers in asm comments.
23608 (dw_loc_list): Determine current endview, pass it to new_loc_list.
23609 Call maybe_gen_llsym.
23610 (loc_list_from_tree_1): Adjust.
23611 (add_AT_location_description): Create view list attribute if
23612 needed, check it's absent otherwise.
23613 (convert_cfa_to_fb_loc_list): Adjust.
23614 (maybe_emit_file): Call output_asm_line_debug_info for test.
23615 (dwarf2out_var_location): Reset views as needed. Precompute
23616 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
23617 attribute. Set view.
23618 (new_line_info_table): Reset next view.
23619 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
23620 (dwarf2out_source_line): Likewise. Output view resets and labels to
23621 the assembler, or select appropriate line info opcodes.
23622 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
23623 (optimize_string_length): Catch it. Adjust.
23624 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
23625 dw_val_class_view_list, and remove it if no longer needed.
23626 (hash_loc_list): Hash view numbers.
23627 (loc_list_hasher::equal): Compare them.
23628 (optimize_location_lists): Check whether a view list symbol is
23629 needed, and whether the locview attribute is present, and
23630 whether they match. Remove the locview attribute if no longer
23631 needed.
23632 (index_location_lists): Call skip_loc_list_entry for test.
23633 (dwarf2out_finish): Call output_asm_line_debug_info for test.
23634 Use output_dwarf_version.
23635 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
23636 (struct dw_val_node): Add val_view_list.
23637 * final.c (SEEN_NEXT_VIEW): New.
23638 (set_next_view_needed): New.
23639 (clear_next_view_needed): New.
23640 (maybe_output_next_view): New.
23641 (final_start_function): Rename to...
23642 (final_start_function_1): ... this. Take pointer to FIRST,
23643 add SEEN parameter. Emit param bindings in the initial view.
23644 (final_start_function): Reintroduce SEEN-less interface.
23645 (final): Rename to...
23646 (final_1): ... this. Take SEEN parameter. Output final pending
23647 next view at the end.
23648 (final): Reintroduce seen-less interface.
23649 (final_scan_insn): Output pending next view before switching
23650 sections or ending a block. Mark the next view as needed when
23651 outputting variable locations. Notify debug backend of section
23652 changes, and of location view changes.
23653 (rest_of_handle_final): Adjust.
23654 * toplev.c (process_options): Autodetect value for debug variable
23655 location views option. Warn on incompat5 without -gdwarf-5.
23656 * doc/invoke.texi (gvariable-location-views): New.
23657 (gvariable-location-views=incompat5): New.
23658 (gno-variable-location-views): New.
23659
23660 2018-02-08 David Malcolm <dmalcolm@redhat.com>
23661
23662 PR tree-optimization/84136
23663 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
23664 that the result of find_edge is non-NULL.
23665
23666 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23667
23668 PR target/83008
23669 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
23670 storing integer register in SImode. Fix cost of 256 and 512
23671 byte aligned SSE register store.
23672
23673 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23674
23675 * config/i386/i386.c (ix86_multiplication_cost): Fix
23676 multiplication cost for TARGET_AVX512DQ.
23677
23678 2018-02-08 Marek Polacek <polacek@redhat.com>
23679
23680 PR tree-optimization/84238
23681 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
23682 get_range_strlen.
23683
23684 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23685
23686 PR tree-optimization/84265
23687 * tree-vect-stmts.c (vectorizable_store): Don't treat
23688 VMAT_CONTIGUOUS accesses as grouped.
23689 (vectorizable_load): Likewise.
23690
23691 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23692
23693 PR tree-optimization/81635
23694 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
23695 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
23696 (test_round_for_mask): New functions.
23697 (wide_int_cc_tests): Call test_round_for_mask.
23698 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
23699 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
23700 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
23701 range returned by get_range_info.
23702
23703 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23704
23705 PR ipa/81360
23706 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
23707 * symtab.c: Include builtins.h
23708 (symtab_node::output_to_lto_symbol_table_p): Move here
23709 from lto-streamer-out.c:output_symbol_p.
23710 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
23711 (output_symbol_p): Move all logic to symtab.c
23712 (produce_symtab): Update.
23713
23714 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23715
23716 * config/s390/s390-opts.h (enum indirect_branch): Define.
23717 * config/s390/s390-protos.h (s390_return_addr_from_memory)
23718 (s390_indirect_branch_via_thunk)
23719 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
23720 (enum s390_indirect_branch_type): Define.
23721 * config/s390/s390.c (struct s390_frame_layout, struct
23722 machine_function): Remove.
23723 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
23724 (indirect_branch_table_label_no, indirect_branch_table_name):
23725 Define variables.
23726 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
23727 (enum s390_indirect_branch_option): Define.
23728 (s390_return_addr_from_memory): New function.
23729 (s390_handle_string_attribute): New function.
23730 (s390_attribute_table): Add new attribute handler.
23731 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
23732 (s390_indirect_branch_via_thunk): New function.
23733 (s390_indirect_branch_via_inline_thunk): New function.
23734 (s390_function_ok_for_sibcall): When jumping via thunk disallow
23735 sibling call optimization for non z10 compiles.
23736 (s390_emit_call): Force indirect branch target to be a single
23737 register. Add r1 clobber for non-z10 compiles.
23738 (s390_emit_epilogue): Emit return jump via return_use expander.
23739 (s390_reorg): Handle JUMP_INSNs as execute targets.
23740 (s390_option_override_internal): Perform validity checks for the
23741 new command line options.
23742 (s390_indirect_branch_attrvalue): New function.
23743 (s390_indirect_branch_settings): New function.
23744 (s390_set_current_function): Invoke s390_indirect_branch_settings.
23745 (s390_output_indirect_thunk_function): New function.
23746 (s390_code_end): Implement target hook.
23747 (s390_case_values_threshold): Implement target hook.
23748 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
23749 macros.
23750 * config/s390/s390.h (struct s390_frame_layout)
23751 (struct machine_function): Move here from s390.c.
23752 (TARGET_INDIRECT_BRANCH_NOBP_RET)
23753 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
23754 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
23755 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
23756 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
23757 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
23758 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
23759 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
23760 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
23761 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
23762 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
23763 (mnemonic attribute): Add values which aren't recognized
23764 automatically.
23765 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
23766 pattern for branch conversion. Fix mnemonic attribute.
23767 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
23768 indirect branch via thunk if requested.
23769 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
23770 ("*indirect_jump"): Disable for branch conversion using out of
23771 line thunks.
23772 ("indirect_jump_via_thunk<mode>_z10")
23773 ("indirect_jump_via_thunk<mode>")
23774 ("indirect_jump_via_inlinethunk<mode>_z10")
23775 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
23776 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
23777 ("casesi_jump_via_inlinethunk<mode>_z10")
23778 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
23779 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
23780 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
23781 ("*indirect2_jump"): Disable for branch conversion.
23782 ("casesi_jump"): Turn into expander and expand patterns for branch
23783 conversion.
23784 ("return_use"): New expander.
23785 ("*return"): Emit return via thunk and rename it to ...
23786 ("*return<mode>"): ... this one.
23787 * config/s390/s390.opt: Add new options and and enum for the
23788 option values.
23789
23790 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23791
23792 * lra-constraints.c (match_reload): Unconditionally use
23793 gen_lowpart_SUBREG, rather than selecting between that
23794 and equivalent gen_rtx_SUBREG code.
23795
23796 2018-02-08 Richard Biener <rguenther@suse.de>
23797
23798 PR tree-optimization/84233
23799 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
23800 changed flag instead of boguously re-using phi_inserted.
23801
23802 2018-02-08 Martin Jambor <mjambor@suse.cz>
23803
23804 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
23805 static local variables.
23806
23807 2018-02-08 Richard Biener <rguenther@suse.de>
23808
23809 PR tree-optimization/84278
23810 * tree-vect-stmts.c (vectorizable_store): When looking for
23811 smaller vector types to perform grouped strided loads/stores
23812 make sure the mode is supported by the target.
23813 (vectorizable_load): Likewise.
23814
23815 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23816
23817 * config/aarch64/aarch64.c (aarch64_components_for_bb):
23818 Increase LDP/STP opportunities by adding adjacent callee-saves.
23819
23820 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23821
23822 PR rtl-optimization/84068
23823 PR rtl-optimization/83459
23824 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
23825
23826 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
23827
23828 PR tree-optimization/84224
23829 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
23830 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
23831 non-zero arguments.
23832
23833 2018-02-07 Iain Sandoe <iain@codesourcery.com>
23834
23835 PR target/84113
23836 * config/rs6000/altivec.md (*restore_world): Remove LR use.
23837 * config/rs6000/predicates.md (restore_world_operation): Adjust op
23838 count, remove one USE.
23839
23840 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
23841
23842 * doc/install.texi (Configuration): Document the
23843 --with-long-double-format={ibm,ieee} PowerPC configuration
23844 options.
23845
23846 PR target/84154
23847 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
23848 Convert from define_expand to be define_insn_and_split. Rework
23849 float/double/_Float128 conversions to QI/HI/SImode to work with
23850 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
23851 conversions to QI/HImode types did a store and then a load to
23852 truncate the value. For conversions to VSX registers, don't split
23853 the insn, instead emit the code directly. Use the code iterator
23854 any_fix to combine signed and unsigned conversions.
23855 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
23856 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
23857 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23858 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
23859 (fix_<mode>di2_hw): Likewise.
23860 (fixuns_<mode>di2_hw): Likewise.
23861 (fix_<mode>si2_hw): Likewise.
23862 (fixuns_<mode>si2_hw): Likewise.
23863 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
23864 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23865 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
23866 fix<uns>_trunc<SFDF:mode>si2_p8.
23867 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
23868 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
23869 (fix<uns>_<mode>_mem): Likewise.
23870 (fctiw<u>z_<mode>_mem): Likewise.
23871 (fix<uns>_<mode>_mem): Likewise.
23872 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
23873 the register allocator from doing a direct move to the GPRs to do
23874 a store, and instead use the ISA 3.0 store byte/half-word from
23875 vector register instruction. For IEEE 128-bit floating point,
23876 also optimize stores of 32-bit ints.
23877 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
23878
23879 2018-02-07 Alan Hayward <alan.hayward@arm.com>
23880
23881 * genextract.c (push_pathstr_operand): New function to support
23882 [a-zA-Z].
23883 (walk_rtx): Call push_pathstr_operand.
23884 (print_path): Support [a-zA-Z].
23885
23886 2018-02-07 Richard Biener <rguenther@suse.de>
23887
23888 PR tree-optimization/84037
23889 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
23890 (cse_and_gimplify_to_preheader): Declare.
23891 (vect_get_place_in_interleaving_chain): Likewise.
23892 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
23893 ivexpr_map.
23894 (_loop_vec_info::~_loop_vec_info): Delete it.
23895 (cse_and_gimplify_to_preheader): New function.
23896 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
23897 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
23898 (vectorizable_load): Likewise. For grouped stores always base
23899 the IV on the first element.
23900 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
23901 condition before gimplifying.
23902
23903 2018-02-07 Jakub Jelinek <jakub@redhat.com>
23904
23905 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
23906 *DIV_EXPR and *MOD_EXPR.
23907
23908 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
23909
23910 PR target/84248
23911 * config/i386/i386.c (ix86_option_override_internal): Mask out
23912 the CF_SET bit when checking -fcf-protection.
23913
23914 2018-02-07 Tom de Vries <tom@codesourcery.com>
23915
23916 PR libgomp/84217
23917 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
23918 enough.
23919
23920 2018-02-07 Richard Biener <rguenther@suse.de>
23921
23922 PR tree-optimization/84204
23923 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
23924 this place.
23925
23926 PR tree-optimization/84205
23927 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
23928 special-case isl_ast_op_zdiv_r.
23929
23930 PR tree-optimization/84223
23931 * graphite-scop-detection.c (gather_bbs::before_dom_children):
23932 Only add conditions from within the region.
23933 (gather_bbs::after_dom_children): Adjust.
23934
23935 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
23936
23937 PR target/84209
23938 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
23939 * config/avr/avr.md: Only post-reload split REG-REG moves if
23940 either register is GENERAL_REG_P.
23941
23942 2018-02-07 Jakub Jelinek <jakub@redhat.com>
23943
23944 PR tree-optimization/84235
23945 * tree-ssa-scopedtables.c
23946 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
23947 if the subtraction is performed in floating point type where NaNs are
23948 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
23949 build 1. Formatting fix.
23950
23951 2018-02-06 Jakub Jelinek <jakub@redhat.com>
23952
23953 PR target/84146
23954 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
23955 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
23956 and skip it regardless of bb boundaries. Use CALL_P macro,
23957 don't test INSN_P (insn) together with CALL_P or JUMP_P check
23958 unnecessarily, formatting fix.
23959
23960 2018-02-06 Michael Collison <michael.collison@arm.com>
23961
23962 * config/arm/thumb2.md:
23963 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
23964 (*thumb_mov_notscc): Ditto.
23965
23966 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
23967
23968 PR target/84154
23969 * config/rs6000/rs6000.md (su code attribute): Use "u" for
23970 unsigned_fix, not "s".
23971
23972 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
23973
23974 * configure.ac (gcc_fn_eh_frame_ro): New function.
23975 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
23976 correct .eh_frame permissions.
23977 * configure: Regenerate.
23978
23979 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
23980
23981 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
23982 irrelevant options.
23983
23984 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
23985
23986 * config/rs6000/rs6000.c (rs6000_option_override_internal):
23987 Display warning message for -mno-speculate-indirect-jumps.
23988
23989 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
23990
23991 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
23992 Undocumented.
23993 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
23994
23995 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
23996
23997 PR tree-optimization/84225
23998 * tree-eh.c (find_trapping_overflow): Only call
23999 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
24000
24001 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24002
24003 PR target/84145
24004 * config/i386/i386.c: Reimplement the check of possible options
24005 -mibt/-mshstk conbination. Change error messages.
24006 * doc/invoke.texi: Fix a typo: remove extra '='.
24007
24008 2018-02-06 Marek Polacek <polacek@redhat.com>
24009
24010 PR tree-optimization/84228
24011 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
24012
24013 2018-02-06 Tamar Christina <tamar.christina@arm.com>
24014
24015 PR target/82641
24016 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
24017 emitted arch directives.
24018 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
24019 __ARM_FEATURE_COPROC before changing architectures.
24020
24021 2018-02-06 Richard Biener <rguenther@suse.de>
24022
24023 * config/i386/i386.c (print_reg): Fix typo.
24024 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
24025
24026 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
24027
24028 * configure: Regenerate.
24029
24030 2018-02-05 Martin Sebor <msebor@redhat.com>
24031
24032 PR tree-optimization/83369
24033 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
24034 inlining context.
24035
24036 2018-02-05 Martin Liska <mliska@suse.cz>
24037
24038 * doc/invoke.texi: Cherry-pick upstream r323995.
24039
24040 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
24041
24042 * ira.c (ira_init_register_move_cost): Adjust comment.
24043
24044 2018-02-05 Martin Liska <mliska@suse.cz>
24045
24046 PR gcov-profile/84137
24047 * doc/gcov.texi: Fix typo in documentation.
24048
24049 2018-02-05 Martin Liska <mliska@suse.cz>
24050
24051 PR gcov-profile/83879
24052 * doc/gcov.texi: Document necessity of --dynamic-list-data when
24053 using dlopen functionality.
24054
24055 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
24056
24057 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
24058 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
24059 _mm_maskz_range_ss, _mm_mask_range_round_ss,
24060 _mm_maskz_range_round_ss): New intrinsics.
24061 (__builtin_ia32_rangesd128_round)
24062 (__builtin_ia32_rangess128_round): Remove.
24063 (__builtin_ia32_rangesd128_mask_round,
24064 __builtin_ia32_rangess128_mask_round): New builtins.
24065 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
24066 __builtin_ia32_rangess128_round): Remove.
24067 (__builtin_ia32_rangesd128_mask_round,
24068 __builtin_ia32_rangess128_mask_round): New builtins.
24069 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
24070 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
24071 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
24072 "<round_saeonly_constraint>")): Changed to ...
24073 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
24074 "<round_saeonly_scalar_constraint>")): ... this.
24075 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
24076 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
24077 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
24078 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
24079 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
24080
24081 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
24082
24083 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
24084 options.
24085 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
24086 Remove all values except native, 8540 and 8548.
24087
24088 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
24089
24090 * config/i386/i386.c (ix86_output_function_return): Pass
24091 INVALID_REGNUM, instead of -1, as invalid register number to
24092 indirect_thunk_name and output_indirect_thunk.
24093
24094 2018-02-02 Julia Koval <julia.koval@intel.com>
24095
24096 * config.gcc: Add -march=icelake.
24097 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
24098 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
24099 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
24100 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
24101 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
24102 (processor_target_table): Add icelake.
24103 (ix86_option_override_internal): Handle new PTAs.
24104 (get_builtin_code_for_version): Handle icelake.
24105 (M_INTEL_COREI7_ICELAKE): New.
24106 (fold_builtin_cpu): Handle icelake.
24107 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
24108 * doc/invoke.texi: Add -march=icelake.
24109
24110 2018-02-02 Julia Koval <julia.koval@intel.com>
24111
24112 * config/i386/i386.c (ix86_option_override_internal): Change flags type
24113 to wide_int_bitmask.
24114 * wide-int-bitmask.h: New.
24115
24116 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24117
24118 PR target/84066
24119 * config/i386/i386.md: Replace Pmode with word_mode in
24120 builtin_setjmp_setup and builtin_longjmp to support x32.
24121
24122 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
24123
24124 PR target/56010
24125 PR target/83743
24126 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
24127 #include "opts.h".
24128 (rs6000_supported_cpu_names): New static variable.
24129 (linux_cpu_translation_table): Likewise.
24130 (elf_platform) <cpu>: Define new static variable and use it.
24131 Translate kernel AT_PLATFORM name to canonical name if needed.
24132 Error if platform name is unknown.
24133
24134 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
24135
24136 PR target/84089
24137 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
24138
24139 2018-02-01 Jeff Law <law@redhat.com>
24140
24141 PR target/84128
24142 * config/i386/i386.c (release_scratch_register_on_entry): Add new
24143 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
24144 the scratch if RELEASE_VIA_POP is false.
24145 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
24146 If we have to save a temporary register, decrement SIZE appropriately.
24147 Pass new arguments to release_scratch_register_on_entry.
24148 (ix86_adjust_stack_and_probe): Likewise.
24149 (ix86_emit_probe_stack_range): Pass new arguments to
24150 release_scratch_register_on_entry.
24151
24152 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
24153
24154 PR rtl-optimization/84157
24155 * combine.c (change_zero_ext): Use REG_P predicate in
24156 front of HARD_REGISTER_P predicate.
24157
24158 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
24159
24160 * config/avr/avr.c (avr_option_override): Move disabling of
24161 -fdelete-null-pointer-checks to...
24162 * common/config/avr/avr-common.c (avr_option_optimization_table):
24163 ...here.
24164
24165 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24166
24167 PR tree-optimization/81635
24168 * tree-data-ref.c (split_constant_offset_1): For types that
24169 wrap on overflow, try to use range info to prove that wrapping
24170 cannot occur.
24171
24172 2018-02-01 Renlin Li <renlin.li@arm.com>
24173
24174 PR target/83370
24175 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
24176 TAILCALL_ADDR_REGS.
24177 (aarch64_register_move_cost): Likewise.
24178 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
24179 TAILCALL_ADDR_REGS.
24180 (REG_CLASS_NAMES): Likewise.
24181 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
24182 TAILCALL_ADDR_REGS. Remove IP registers.
24183 * config/aarch64/aarch64.md (Ucs): Update register constraint.
24184
24185 2018-02-01 Richard Biener <rguenther@suse.de>
24186
24187 * domwalk.h (dom_walker::dom_walker): Add additional constructor
24188 for specifying RPO order and allow NULL for that.
24189 * domwalk.c (dom_walker::dom_walker): Likewise.
24190 (dom_walker::walk): Handle NULL RPO order.
24191 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
24192 in RPO order.
24193 (rewrite_update_dom_walker): Likewise.
24194 (mark_def_dom_walker): Likewise.
24195
24196 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24197
24198 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
24199 (aarch64_maybe_expand_sve_subreg_move): Declare.
24200 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
24201 * config/aarch64/predicates.md (aarch64_any_register_operand): New
24202 predicate.
24203 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
24204 that are semantically a reverse operation.
24205 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
24206 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
24207 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
24208 functions.
24209 (aarch64_can_change_mode_class): For big-endian, forbid changes
24210 between two SVE modes if they have different element sizes.
24211
24212 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24213
24214 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
24215 the TImode handling for big-endian targets.
24216
24217 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24218
24219 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
24220 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
24221 not just bytes.
24222 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
24223 Remove BSWAP handing for big-endian targets and use the form of
24224 LD1RQ appropariate for the mode.
24225
24226 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24227
24228 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
24229 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
24230 duplicated element.
24231
24232 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24233
24234 PR tearget/83845
24235 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
24236 check for operands that need to go through aarch64_sve_reload_be.
24237
24238 2018-02-01 Jakub Jelinek <jakub@redhat.com>
24239
24240 PR tree-optimization/81661
24241 PR tree-optimization/84117
24242 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
24243 * tree-eh.c: Include gimplify.h.
24244 (find_trapping_overflow, replace_trapping_overflow,
24245 rewrite_to_non_trapping_overflow): New functions.
24246 * tree-vect-loop.c: Include tree-eh.h.
24247 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
24248 * tree-data-ref.c: Include tree-eh.h.
24249 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
24250
24251 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
24252
24253 PR rtl-optimization/84123
24254 * combine.c (change_zero_ext): Check if hard register satisfies
24255 can_change_dest_mode before calling gen_lowpart_SUBREG.
24256
24257 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
24258
24259 PR target/82444
24260 * ira.c (ira_init_register_move_cost): Remove assert.
24261
24262 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24263
24264 PR rtl-optimization/84071
24265 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
24266 * doc/tm.texi: Regenerate.
24267
24268 2018-01-31 Richard Biener <rguenther@suse.de>
24269
24270 PR tree-optimization/84132
24271 * tree-data-ref.c (analyze_miv_subscript): Properly
24272 check whether evolution_function_is_affine_multivariate_p
24273 before calling gcd_of_steps_may_divide_p.
24274
24275 2018-01-31 Julia Koval <julia.koval@intel.com>
24276
24277 PR target/83618
24278 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
24279 * config/i386/i386.md (rdpid_rex64) New.
24280 (rdpid): Make 32bit only.
24281
24282 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
24283
24284 PR lto/84105
24285 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
24286 an IDENTIFIER_NODE for FUNCTION_TYPE's.
24287
24288 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24289
24290 Revert
24291 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
24292
24293 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
24294
24295 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24296
24297 PR rtl-optimization/84071
24298 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
24299 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
24300
24301 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24302
24303 * config/arc/arc.c (arc_handle_aux_attribute): New function.
24304 (arc_attribute_table): Add 'aux' attribute.
24305 (arc_in_small_data_p): Consider aux like variables.
24306 (arc_is_aux_reg_p): New function.
24307 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
24308 (arc_get_aux_arg): New function.
24309 (prepare_move_operands): Handle aux-register access.
24310 (arc_handle_aux_attribute): New function.
24311 * doc/extend.texi (ARC Variable attributes): Add subsection.
24312
24313 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24314
24315 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
24316 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
24317 (arc_attribute_table): Add 'uncached' attribute.
24318 (arc_print_operand): Print '.di' flag for uncached memory
24319 accesses.
24320 (arc_in_small_data_p): Do not consider for small data the uncached
24321 types.
24322 (arc_is_uncached_mem_p): New function.
24323 * config/arc/predicates.md (compact_store_memory_operand): Check
24324 for uncached memory accesses.
24325 (nonvol_nonimm_operand): Likewise.
24326 * doc/extend.texi (ARC Type Attribute): New subsection.
24327
24328 2018-01-31 Jakub Jelinek <jakub@redhat.com>
24329
24330 PR c/84100
24331 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
24332 falign-loops=): Add Optimization flag.
24333
24334 2018-01-30 Jeff Law <law@redhat.com>
24335
24336 PR target/84064
24337 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
24338 INT_REGISTERS_SAVED. Check it prior to calling
24339 get_scratch_register_on_entry.
24340 (ix86_adjust_stack_and_probe): Similarly.
24341 (ix86_emit_probe_stack_range): Similarly.
24342 (ix86_expand_prologue): Corresponding changes.
24343
24344 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24345
24346 PR target/40411
24347 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
24348 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
24349
24350 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
24351
24352 PR target/84112
24353 * lra-constraints.c (curr_insn_transform): Process AND in the
24354 address.
24355
24356 2018-01-30 Jakub Jelinek <jakub@redhat.com>
24357
24358 PR rtl-optimization/83986
24359 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
24360 dependence against last_pending_memory_flush in addition to
24361 pending_jump_insns.
24362
24363 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
24364
24365 PR tree-optimization/81611
24366 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
24367 copies.
24368
24369 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
24370
24371 PR target/83758
24372 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
24373 a reg rtx.
24374
24375 2018-01-30 Richard Biener <rguenther@suse.de>
24376 Jakub Jelinek <jakub@redhat.com>
24377
24378 PR tree-optimization/84111
24379 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
24380 inner loops added during recursion, as they don't have up-to-date
24381 SSA form.
24382
24383 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24384
24385 PR ipa/81360
24386 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
24387 (can_inline_edge_by_limits_p): ... here.
24388 (can_early_inline_edge_p, check_callers,
24389 update_caller_keys, update_callee_keys, recursive_inlining,
24390 add_new_edges_to_heap, speculation_useful_p,
24391 inline_small_functions,
24392 inline_small_functions, flatten_function,
24393 inline_to_all_callers_1): Update.
24394
24395 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24396
24397 * profile-count.c (profile_count::combine_with_ipa_count): Handle
24398 zeros correctly.
24399
24400 2018-01-30 Richard Biener <rguenther@suse.de>
24401
24402 PR tree-optimization/83008
24403 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
24404 invariant and constant vector uses in stmts when they need
24405 more than one stmt.
24406
24407 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24408
24409 PR bootstrap/84017
24410 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
24411 * configure: Regenerate.
24412
24413 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24414
24415 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
24416 pattern.
24417 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
24418 Use gen_rtx_REG rather than gen_lowpart.
24419
24420 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24421
24422 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
24423 rather than 0 when creating partial subregs.
24424
24425 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24426
24427 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
24428 of usage.
24429
24430 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
24431
24432 PR target/81550
24433 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
24434 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
24435 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
24436 flags. This restores the settings used before the 2017-07-24.
24437 Turning off pre increment/decrement/modify allows IVOPTS to
24438 optimize DF/SF loops where the index is an int.
24439
24440 2018-01-29 Richard Biener <rguenther@suse.de>
24441 Kelvin Nilsen <kelvin@gcc.gnu.org>
24442
24443 PR bootstrap/80867
24444 * tree-vect-stmts.c (vectorizable_call): Don't call
24445 targetm.vectorize_builtin_md_vectorized_function if callee is
24446 NULL.
24447
24448 2018-01-22 Carl Love <cel@us.ibm.com>
24449
24450 * doc/extend.tex: Fix typo in second arg in
24451 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
24452
24453 2018-01-29 Richard Biener <rguenther@suse.de>
24454
24455 PR tree-optimization/84086
24456 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
24457 (flush_ssaname_freelist): When SSA names were released reset
24458 the SCEV hash table.
24459
24460 2018-01-29 Richard Biener <rguenther@suse.de>
24461
24462 PR tree-optimization/84057
24463 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
24464 removed paths when removing edges.
24465
24466 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
24467
24468 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
24469 -mfunction-return=@var{choice}.
24470
24471 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
24472
24473 PR diagnostic/84034
24474 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
24475 Handle CR like TAB.
24476 (layout::print_source_line): Likewise.
24477 (test_get_line_width_without_trailing_whitespace): Add test cases.
24478
24479 2018-01-27 Jakub Jelinek <jakub@redhat.com>
24480
24481 PR middle-end/84040
24482 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
24483 debug insns.
24484
24485 2018-01-26 Jim Wilson <jimw@sifive.com>
24486
24487 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
24488
24489 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
24490 specified.
24491
24492 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24493
24494 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
24495 and CMP + SUB-immediate -> SUBS.
24496
24497 2018-01-26 Martin Sebor <msebor@redhat.com>
24498
24499 PR tree-optimization/83896
24500 * tree-ssa-strlen.c (get_string_len): Rename...
24501 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
24502 Avoid assuming length is constant.
24503 (handle_char_store): Use HOST_WIDE_INT for string length.
24504
24505 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
24506
24507 PR target/81763
24508 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
24509 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
24510
24511 2018-01-26 Richard Biener <rguenther@suse.de>
24512
24513 PR rtl-optimization/84003
24514 * dse.c (record_store): Only record redundant stores when
24515 the earlier store aliases at least all accesses the later one does.
24516
24517 2018-01-26 Jakub Jelinek <jakub@redhat.com>
24518
24519 PR rtl-optimization/83985
24520 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
24521 REG_CFA_RESTORE insns.
24522 (delete_unmarked_insns): Don't ignore separate shrink wrapping
24523 REG_CFA_RESTORE insns here.
24524
24525 PR c/83989
24526 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
24527 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
24528
24529 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24530
24531 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
24532 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
24533 (arc_init): Likewise.
24534 (arc_override_options): Likewise.
24535 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
24536 value.
24537 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
24538 support.
24539 * config/arc/arc.h (TARGET_DBNZ): Define.
24540 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
24541 properly set the tune attribute.
24542 (dbnz): Use TARGET_DBNZ guard.
24543 * config/arc/arc.opt (mtune): Add core3 option.
24544
24545 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24546
24547 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
24548 recognize new pic like addresses.
24549 (arc_delegitimize_address): Clean up.
24550
24551 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24552
24553 * config/arc/arc-arches.def: Option mrf16 valid for all
24554 architectures.
24555 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
24556 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
24557 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
24558 * config/arc/arc-tables.opt: Regenerate.
24559 * config/arc/arc.c (arc_conditional_register_usage): Handle
24560 reduced register file case.
24561 (arc_file_start): Set must have build attributes.
24562 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
24563 mrf16 option value.
24564 * config/arc/arc.opt (mrf16): Add new option.
24565 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
24566 * config/arc/genmultilib.awk: Handle new mrf16 option.
24567 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
24568 * config/arc/t-multilib: Regenerate.
24569 * doc/invoke.texi (ARC Options): Document mrf16 option.
24570
24571 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24572
24573 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
24574 * config/arc/arc.c (arc_handle_secure_attribute): New function.
24575 (arc_attribute_table): Add 'secure_call' attribute.
24576 (arc_print_operand): Print secure call operand.
24577 (arc_function_ok_for_sibcall): Don't optimize tail calls when
24578 secure.
24579 (arc_is_secure_call_p): New function. * config/arc/arc.md
24580 (call_i): Add support for sjli instruction.
24581 (call_value_i): Likewise.
24582 * config/arc/constraints.md (Csc): New constraint.
24583
24584 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24585 John Eric Martin <John.Martin@emmicro-us.com>
24586
24587 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
24588 * config/arc/arc.c (_arc_jli_section): New struct.
24589 (arc_jli_section): New type.
24590 (rc_jli_sections): New static variable.
24591 (arc_handle_jli_attribute): New function.
24592 (arc_attribute_table): Add jli_always and jli_fixed attribute.
24593 (arc_file_end): New function.
24594 (TARGET_ASM_FILE_END): Define.
24595 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
24596 (arc_add_jli_section): New function.
24597 (jli_call_scan): Likewise.
24598 (arc_reorg): Call jli_call_scan.
24599 (arc_output_addsi): Remove 'S' from printing asm operand.
24600 (arc_is_jli_call_p): New function.
24601 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
24602 operand.
24603 (movhi_insn): Likewise.
24604 (movsi_insn): Likewise.
24605 (movsi_set_cc_insn): Likewise.
24606 (loadqi_update): Likewise.
24607 (load_zeroextendqisi_update): Likewise.
24608 (load_signextendqisi_update): Likewise.
24609 (loadhi_update): Likewise.
24610 (load_zeroextendhisi_update): Likewise.
24611 (load_signextendhisi_update): Likewise.
24612 (loadsi_update): Likewise.
24613 (loadsf_update): Likewise.
24614 (movsicc_insn): Likewise.
24615 (bset_insn): Likewise.
24616 (bxor_insn): Likewise.
24617 (bclr_insn): Likewise.
24618 (bmsk_insn): Likewise.
24619 (bicsi3_insn): Likewise.
24620 (cmpsi_cc_c_insn): Likewise.
24621 (movsi_ne): Likewise.
24622 (movsi_cond_exec): Likewise.
24623 (clrsbsi2): Likewise.
24624 (norm_f): Likewise.
24625 (normw): Likewise.
24626 (swap): Likewise.
24627 (divaw): Likewise.
24628 (flag): Likewise.
24629 (sr): Likewise.
24630 (kflag): Likewise.
24631 (ffs): Likewise.
24632 (ffs_f): Likewise.
24633 (fls): Likewise.
24634 (call_i): Remove 'S' asm letter, add jli instruction.
24635 (call_value_i): Likewise.
24636 * config/arc/arc.op (mjli-always): New option.
24637 * config/arc/constraints.md (Cji): New constraint.
24638 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
24639 operand.
24640 (subsf3_fpx): Likewise.
24641 (mulsf3_fpx): Likewise.
24642 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
24643 asm operand.
24644 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
24645 function attrbutes.
24646 * doc/invoke.texi (ARC): Document mjli-always option.
24647
24648 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
24649
24650 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
24651 avoid addition with 0 and use incw and decw where possible.
24652
24653 2018-01-26 Richard Biener <rguenther@suse.de>
24654
24655 PR tree-optimization/81082
24656 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
24657 association if it requires casting to unsigned.
24658 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
24659 from fold_plusminus_mult_expr to catch important cases late when
24660 range info is available.
24661
24662 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24663
24664 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
24665 * configure.ac (hidden_linkonce): New test.
24666 * configure: Regenerate.
24667 * config.in: Regenerate.
24668
24669 2018-01-26 Julia Koval <julia.koval@intel.com>
24670
24671 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
24672 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
24673 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
24674 _mm_mask_bitshuffle_epi64_mask): Fix type.
24675 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
24676 USI_FTYPE_V4DI_V4DI_USI): Remove.
24677 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
24678 __builtin_ia32_vpshufbitqmb256_mask,
24679 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
24680 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
24681 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
24682
24683 2018-01-26 Alan Modra <amodra@gmail.com>
24684
24685 PR target/84033
24686 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
24687 UNSPEC_VBPERMQ. Sort other unspecs.
24688
24689 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
24690
24691 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
24692
24693 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
24694
24695 PR middle-end/83055
24696 * predict.c (drop_profile): Do not push/pop cfun; update also
24697 node->count.
24698 (handle_missing_profiles): Fix logic looking for zero profiles.
24699
24700 2018-01-25 Jakub Jelinek <jakub@redhat.com>
24701
24702 PR middle-end/83977
24703 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
24704 on functions with #pragma omp declare simd or functions with simd
24705 attribute.
24706 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
24707 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
24708 Remove trailing \n from warning_at calls.
24709
24710 2018-01-25 Tom de Vries <tom@codesourcery.com>
24711
24712 PR target/84028
24713 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24714 for neutered workers.
24715
24716 2018-01-24 Joseph Myers <joseph@codesourcery.com>
24717
24718 PR target/68467
24719 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
24720 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
24721
24722 2018-01-24 Jeff Law <law@redhat.com>
24723
24724 PR target/83994
24725 * i386.c (get_probe_interval): Move to earlier point.
24726 (ix86_compute_frame_layout): If -fstack-clash-protection and
24727 the frame is larger than the probe interval, then use pushes
24728 to save registers rather than reg->mem moves.
24729 (ix86_expand_prologue): Remove conditional for int_registers_saved
24730 assertion.
24731
24732 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
24733
24734 PR target/84014
24735 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
24736 min/max for never referenced object.
24737
24738 2018-01-24 Jakub Jelinek <jakub@redhat.com>
24739
24740 PR middle-end/83977
24741 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
24742 here.
24743 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
24744 attributes from DECL_ATTRIBUTES (decl) without affecting
24745 DECL_ATTRIBUTES (current_function_decl).
24746 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
24747 functions with non-NULL DECL_ABSTRACT_ORIGIN.
24748
24749 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
24750
24751 PR tree-optimization/83979
24752 * fold-const.c (fold_comparison): Use constant_boolean_node
24753 instead of boolean_{true,false}_node.
24754
24755 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
24756
24757 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
24758 with zero counts.
24759
24760 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24761
24762 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
24763 Simplify the clause that sets the length attribute.
24764 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
24765 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
24766 clause that sets the length attribute.
24767 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
24768
24769 2018-01-24 Tom de Vries <tom@codesourcery.com>
24770
24771 PR target/83589
24772 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
24773 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
24774 Add strict parameter.
24775 (prevent_branch_around_nothing): Insert dummy insn between branch to
24776 label and label with no ptx insn inbetween.
24777 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
24778
24779 2018-01-24 Tom de Vries <tom@codesourcery.com>
24780
24781 PR target/81352
24782 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24783 for neutered threads in warp.
24784 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
24785
24786 2018-01-24 Richard Biener <rguenther@suse.de>
24787
24788 PR tree-optimization/83176
24789 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
24790 operands.
24791
24792 2018-01-24 Richard Biener <rguenther@suse.de>
24793
24794 PR tree-optimization/82819
24795 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
24796 code generating pluses that are no-ops in the target precision.
24797
24798 2018-01-24 Richard Biener <rguenther@suse.de>
24799
24800 PR middle-end/84000
24801 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
24802
24803 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24804
24805 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
24806 to merge probabilities.
24807 * predict.c (probably_never_executed): Also mark as cold functions
24808 with global 0 profile and guessed local profile.
24809 * profile-count.c (profile_probability::combine_with_count): New
24810 member function.
24811 * profile-count.h (profile_probability::operator*,
24812 profile_probability::operator*=, profile_probability::operator/,
24813 profile_probability::operator/=): Reduce precision to adjusted
24814 and set value to guessed on contradictory divisions.
24815 (profile_probability::combine_with_freq): Remove.
24816 (profile_probability::combine_wiht_count): Declare.
24817 (profile_count::force_nonzero):: Set to adjusted.
24818 (profile_count::probability_in):: Set quality to adjusted.
24819 * tree-ssa-tail-merge.c (replace_block_by): Use
24820 combine_with_count.
24821
24822 2018-01-23 Andrew Waterman <andrew@sifive.com>
24823 Jim Wilson <jimw@sifive.com>
24824
24825 * config/riscv/riscv.c (riscv_stack_boundary): New.
24826 (riscv_option_override): Set riscv_stack_boundary. Handle
24827 riscv_preferred_stack_boundary_arg.
24828 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
24829 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
24830 (STACK_BOUNDARY): Set to riscv_stack_boundary.
24831 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
24832 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
24833 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
24834
24835 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
24836
24837 PR target/83905
24838 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
24839 of struct ix86_frame.
24840 (ix86_expand_epilogue): Likewise. Add a local variable for
24841 the reg_save_offset field in struct ix86_frame.
24842
24843 2018-01-23 Bin Cheng <bin.cheng@arm.com>
24844
24845 PR tree-optimization/82604
24846 * tree-loop-distribution.c (enum partition_kind): New enum item
24847 PKIND_PARTIAL_MEMSET.
24848 (partition_builtin_p): Support above new enum item.
24849 (generate_code_for_partition): Ditto.
24850 (compute_access_range): Differentiate cases that equality can be
24851 proven at all loops, the innermost loops or no loops.
24852 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
24853 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
24854 (finalize_partitions, distribute_loop): Don't fuse partition of
24855 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
24856 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
24857 parloop is enabled.
24858
24859 2018-01-23 Martin Liska <mliska@suse.cz>
24860
24861 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
24862 order to ignore the predictor.
24863 (PRED_POLYMORPHIC_CALL): Likewise.
24864 (PRED_RECURSIVE_CALL): Likewise.
24865
24866 2018-01-23 Martin Liska <mliska@suse.cz>
24867
24868 * tree-profile.c (tree_profiling): Print function header to
24869 aware reader which function we are working on.
24870 * value-prof.c (gimple_find_values_to_profile): Do not print
24871 not interesting value histograms.
24872
24873 2018-01-23 Martin Liska <mliska@suse.cz>
24874
24875 * profile-count.h (enum profile_quality): Add
24876 profile_uninitialized as the first value. Do not number values
24877 as they are zero based.
24878 (profile_count::verify): Update sanity check.
24879 (profile_probability::verify): Likewise.
24880
24881 2018-01-23 Nathan Sidwell <nathan@acm.org>
24882
24883 * doc/invoke.texi (ffor-scope): Deprecate.
24884
24885 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24886
24887 PR tree-optimization/83510
24888 * domwalk.c (set_all_edges_as_executable): New function.
24889 (dom_walker::dom_walker): Convert bool param
24890 "skip_unreachable_blocks" to enum reachability. Move setup of
24891 edge flags to set_all_edges_as_executable and only do it when
24892 reachability is REACHABLE_BLOCKS.
24893 * domwalk.h (enum dom_walker::reachability): New enum.
24894 (dom_walker::dom_walker): Convert bool param
24895 "skip_unreachable_blocks" to enum reachability.
24896 (set_all_edges_as_executable): New decl.
24897 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
24898 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
24899 "reachability".
24900 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
24901 but converting true to REACHABLE_BLOCKS.
24902 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
24903 * tree-vrp.c
24904 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
24905 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
24906 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
24907 REACHABLE_BLOCKS.
24908 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
24909 if check_all_array_refs will be called.
24910
24911 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24912
24913 * tree.c (selftest::test_location_wrappers): Add more test
24914 coverage.
24915
24916 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24917
24918 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
24919 (selftest::test_bit_in_range): Likewise.
24920
24921 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
24922
24923 PR testsuite/83888
24924 * doc/sourcebuild.texi (vect_float): Say that the selector
24925 only describes the situation when -funsafe-math-optimizations is on.
24926 (vect_float_strict): Document.
24927
24928 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
24929
24930 PR tree-optimization/83965
24931 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
24932 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
24933 instead of checking only for a reduction.
24934 (vect_recog_widen_sum_pattern): Likewise.
24935
24936 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24937
24938 * predict.c (probably_never_executed): Only use precise profile info.
24939 (compute_function_frequency): Skip after inlining hack since we now
24940 have quality checking.
24941
24942 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24943
24944 * profile-count.h (profile_probability::very_unlikely,
24945 profile_probability::unlikely, profile_probability::even): Set
24946 precision to guessed.
24947
24948 2018-01-23 Richard Biener <rguenther@suse.de>
24949
24950 PR tree-optimization/83963
24951 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
24952 Properly terminate dominator walk when crossing the exit edge not
24953 when visiting its source block.
24954
24955 2018-01-23 Jakub Jelinek <jakub@redhat.com>
24956
24957 PR c++/83918
24958 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
24959 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
24960
24961 2018-01-22 Jakub Jelinek <jakub@redhat.com>
24962
24963 PR tree-optimization/83957
24964 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
24965 semicolon after for body surrounded by braces.
24966
24967 PR tree-optimization/83081
24968 * profile-count.h (profile_probability::split): New method.
24969 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
24970 Use profile_probability::split.
24971 (do_compare_rtx_and_jump): Fix adjustment of probabilities
24972 when splitting a single conditional jump into 2.
24973
24974 2018-01-22 David Malcolm <dmalcolm@redhat.com>
24975
24976 PR tree-optimization/69452
24977 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
24978 decl.
24979
24980 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
24981
24982 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
24983 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
24984 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
24985
24986 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
24987
24988 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
24989 declaration.
24990 * config/rl78/rl78.md (movdi): New define_expand.
24991 * config/rl78/rl78.c (rl78_split_movdi): New function.
24992
24993 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
24994
24995 PR target/83862
24996 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
24997 no longer used.
24998 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
24999 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
25000 128-bit to produce an UNSPEC move to get the double word with the
25001 signbit and then a shift directly to do signbit.
25002 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
25003 implementation with a new version that just does either a direct
25004 move or a regular move. Move memory interface to separate insns.
25005 Move insns so they are next to the expander.
25006 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
25007 with signbit move. Split big and little endian case.
25008 (signbit<mode>2_dm_mem_le): Likewise.
25009 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
25010 (signbit<mode>2_dm2): Likewise.
25011
25012 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25013
25014 * config/rl78/rl78.md (anddi3): New define_expand.
25015
25016 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25017
25018 * config/rl78/rl78.md (umindi3): New define_expand.
25019
25020 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25021
25022 * config/rl78/rl78.md (smindi3): New define_expand.
25023
25024 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25025
25026 * config/rl78/rl78.md (smaxdi3): New define_expand.
25027
25028 2018-01-22 Carl Love <cel@us.ibm.com>
25029
25030 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
25031 LVX_V1TI): Add macro expansion.
25032 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
25033 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
25034 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
25035 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
25036 Change check to determine if the instruction is a byte reversing
25037 entry. Fix typo in comment.
25038 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
25039 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
25040 Add def_builtin calls for new builtins.
25041 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
25042 Add define_insn expansion.
25043
25044 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25045
25046 * config/rl78/rl78.md (umaxdi3): New define_expand.
25047
25048 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25049
25050 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
25051 for non-QImode registers.
25052
25053 2018-01-22 Richard Biener <rguenther@suse.de>
25054
25055 PR tree-optimization/83963
25056 * graphite-scop-detection.c (scop_detection::get_sese): Delay
25057 including the loop exit block.
25058 (scop_detection::merge_sese): Likewise.
25059 (scop_detection::add_scop): Do it here instead.
25060
25061 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25062
25063 * doc/sourcebuild.texi (arm_softfloat): Document.
25064
25065 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
25066
25067 PR gcc/77734
25068 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
25069 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
25070 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
25071
25072 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25073 David Edelsohn <dje.gcc@gmail.com>
25074
25075 PR target/83946
25076 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25077 Change "crset eq" to "crset 2".
25078 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25079 (*call_indirect_aix<mode>_nospec): Likewise.
25080 (*call_value_indirect_aix<mode>_nospec): Likewise.
25081 (*call_indirect_elfv2<mode>_nospec): Likewise.
25082 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
25083 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
25084 change assembly output from . to $.
25085 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25086 (indirect_jump<mode>_nospec): Change assembly output from . to $.
25087 (*tablejump<mode>_internal1_nospec): Likewise.
25088
25089 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
25090
25091 PR target/80870
25092 * config/sh/sh_optimize_sett_clrt.cc:
25093 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
25094
25095 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
25096
25097 PR tree-optimization/83940
25098 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
25099 offset_dt to vect_constant_def rather than vect_unknown_def_type.
25100 (vect_check_load_store_mask): Add a mask_dt_out parameter and
25101 use it to pass back the definition type.
25102 (vect_check_store_rhs): Likewise rhs_dt_out.
25103 (vect_build_gather_load_calls): Add a mask_dt argument and use
25104 it instead of a call to vect_is_simple_use.
25105 (vectorizable_store): Update calls to vect_check_load_store_mask
25106 and vect_check_store_rhs. Use the dt returned by the latter instead
25107 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
25108 instead of calls to vect_is_simple_use. Pass the scalar rather
25109 than the vector operand to vect_is_simple_use when handling
25110 second and subsequent copies of an rhs value.
25111 (vectorizable_load): Update calls to vect_check_load_store_mask
25112 and vect_build_gather_load_calls. Use the cached mask_dt and
25113 gs_info.offset_dt instead of calls to vect_is_simple_use.
25114
25115 2018-01-20 Jakub Jelinek <jakub@redhat.com>
25116
25117 PR middle-end/83945
25118 * tree-emutls.c: Include gimplify.h.
25119 (lower_emutls_2): New function.
25120 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
25121 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
25122 it before further processing.
25123
25124 PR target/83930
25125 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
25126 UINTVAL (trueop1) instead of INTVAL (op1).
25127
25128 2018-01-19 Jakub Jelinek <jakub@redhat.com>
25129
25130 PR debug/81570
25131 PR debug/83728
25132 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
25133 INCOMING_FRAME_SP_OFFSET if not defined.
25134 (scan_trace): Add ENTRY argument. If true and
25135 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
25136 emit a note to adjust the CFA offset.
25137 (create_cfi_notes): Adjust scan_trace callers.
25138 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
25139 INCOMING_FRAME_SP_OFFSET in the CIE.
25140 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
25141 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
25142 Likewise.
25143 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
25144 * doc/tm.texi: Regenerated.
25145
25146 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25147
25148 PR rtl-optimization/83147
25149 * lra-constraints.c (remove_inheritance_pseudos): Use
25150 lra_substitute_pseudo_within_insn.
25151
25152 2018-01-19 Tom de Vries <tom@codesourcery.com>
25153 Cesar Philippidis <cesar@codesourcery.com>
25154
25155 PR target/83920
25156 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
25157
25158 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
25159
25160 PR target/83790
25161 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
25162 spaces for function labels.
25163
25164 2018-01-19 Martin Liska <mliska@suse.cz>
25165
25166 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
25167 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
25168 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
25169 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
25170 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
25171 (PRED_CONST_RETURN): Change from 69 to 65.
25172 (PRED_NULL_RETURN): Change from 91 to 71.
25173 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
25174 (PRED_LOOP_GUARD): Change from 66 to 73.
25175
25176 2018-01-19 Martin Liska <mliska@suse.cz>
25177
25178 * predict.c (predict_insn_def): Add new assert.
25179 (struct branch_predictor): Change type to signed integer.
25180 (test_prediction_value_range): Amend test to cover
25181 PROB_UNINITIALIZED.
25182 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
25183 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
25184 (PRED_LOOP_ITERATIONS_MAX): Likewise.
25185 (PRED_LOOP_IV_COMPARE): Likewise.
25186 * predict.h (PROB_UNINITIALIZED): Define new constant.
25187
25188 2018-01-19 Martin Liska <mliska@suse.cz>
25189
25190 * predict.c (dump_prediction): Add new format for
25191 analyze_brprob.py script which is enabled with -details
25192 suboption.
25193 * profile-count.h (precise_p): New function.
25194
25195 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25196
25197 PR tree-optimization/83922
25198 * tree-vect-loop.c (vect_verify_full_masking): Return false if
25199 there are no statements that need masking.
25200 (vect_active_double_reduction_p): New function.
25201 (vect_analyze_loop_operations): Use it when handling phis that
25202 are not in the loop header.
25203
25204 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25205
25206 PR tree-optimization/83914
25207 * tree-vect-loop.c (vectorizable_induction): Don't convert
25208 init_expr or apply the peeling adjustment for inductions
25209 that are nested within the vectorized loop.
25210
25211 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25212
25213 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
25214 instead of NEG.
25215
25216 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25217
25218 PR sanitizer/81715
25219 PR testsuite/83882
25220 * function.h (gimplify_parameters): Add gimple_seq * argument.
25221 * function.c: Include gimple.h and options.h.
25222 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
25223 for the added local temporaries if needed.
25224 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
25225 if there are any parameter cleanups, wrap whole body into a
25226 try/finally with the cleanups.
25227
25228 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
25229
25230 PR target/82964
25231 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
25232 Use GET_MODE_CLASS for scalar floating point.
25233
25234 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25235
25236 PR ipa/82256
25237 patch by PaX Team
25238 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
25239 Fix call of call_cgraph_insertion_hooks.
25240
25241 2018-01-18 Martin Sebor <msebor@redhat.com>
25242
25243 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
25244
25245 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25246
25247 PR ipa/83619
25248 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
25249 frequencies.
25250
25251 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
25252
25253 PR other/70268
25254 * common.opt: (-ffile-prefix-map): New option.
25255 * opts.c (common_handle_option): Defer it.
25256 * opts-global.c (handle_common_deferred_options): Handle it.
25257 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
25258 * file-prefix-map.h: New file.
25259 (remap_debug_filename, add_debug_prefix_map): ...here.
25260 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
25261 * final.c (debug_prefix_map, add_debug_prefix_map
25262 remap_debug_filename): Move to...
25263 * file-prefix-map.c: New file.
25264 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
25265 generalize, get rid of alloca(), use strrchr() instead of strchr().
25266 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
25267 Implement in terms of add_prefix_map().
25268 (remap_macro_filename, remap_debug_filename): Implement in term of
25269 remap_filename().
25270 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
25271 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
25272 * dbxout.c: Include file-prefix-map.h.
25273 * varasm.c: Likewise.
25274 * vmsdbgout.c: Likewise.
25275 * xcoffout.c: Likewise.
25276 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
25277 * doc/cppopts.texi (-fmacro-prefix-map): Document.
25278 * doc/invoke.texi (-ffile-prefix-map): Document.
25279 (-fdebug-prefix-map): Update description.
25280
25281 2018-01-18 Martin Liska <mliska@suse.cz>
25282
25283 * config/i386/i386.c (indirect_thunk_name): Document that also
25284 lfence is emitted.
25285 (output_indirect_thunk): Document why both instructions
25286 (pause and lfence) are generated.
25287
25288 2018-01-18 Richard Biener <rguenther@suse.de>
25289
25290 PR tree-optimization/83887
25291 * graphite-scop-detection.c
25292 (scop_detection::get_nearest_dom_with_single_entry): Remove.
25293 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
25294 (scop_detection::merge_sese): Re-implement with a flood-fill
25295 algorithm that properly finds a SESE region if it exists.
25296
25297 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25298
25299 PR c/61240
25300 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
25301 pointer_diff optimizations use view_convert instead of convert.
25302
25303 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25304
25305 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25306 Generate different code for -mno-speculate-indirect-jumps.
25307 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25308 (*call_indirect_aix<mode>): Disable for
25309 -mno-speculate-indirect-jumps.
25310 (*call_indirect_aix<mode>_nospec): New define_insn.
25311 (*call_value_indirect_aix<mode>): Disable for
25312 -mno-speculate-indirect-jumps.
25313 (*call_value_indirect_aix<mode>_nospec): New define_insn.
25314 (*sibcall_nonlocal_sysv<mode>): Generate different code for
25315 -mno-speculate-indirect-jumps.
25316 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25317
25318 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
25319
25320 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
25321 long double type, set the flags for noting the default long double
25322 type, even if we don't pass or return a long double type.
25323
25324 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
25325
25326 PR ipa/83051
25327 * ipa-inline.c (flatten_function): Do not overwrite final inlining
25328 failure.
25329
25330 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
25331
25332 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
25333 support for merge[hl].
25334 (fold_mergehl_helper): New helper function.
25335 (tree-vector-builder.h): New #include for tree_vector_builder usage.
25336 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
25337 (altivec_vmrglw_direct): Add xxmrglw insn.
25338
25339 2018-01-17 Andrew Waterman <andrew@sifive.com>
25340
25341 * config/riscv/riscv.c (riscv_conditional_register_usage): If
25342 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
25343
25344 2018-01-17 David Malcolm <dmalcolm@redhat.com>
25345
25346 PR lto/83121
25347 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
25348 call the lto_location_cache before reading the
25349 DECL_SOURCE_LOCATION of the types.
25350
25351 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
25352 Richard Sandiford <richard.sandiford@linaro.org>
25353
25354 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
25355 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
25356 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
25357 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
25358 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
25359 Add declaration.
25360 * config/aarch64/constraints.md (aarch64_movti_operand):
25361 Limit immediates.
25362 * config/aarch64/predicates.md (Uti): Add new constraint.
25363
25364 2018-01-17 Carl Love <cel@us.ibm.com>
25365
25366 * config/rs6000/vsx.md (define_expand xl_len_r,
25367 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
25368 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
25369 lxvll.
25370 (define_expand, define_insn): Move the shift left from the
25371 define_insn to the define_expand for lxvl and stxvl instructions.
25372 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
25373 and XL_LEN_R definitions to PURE.
25374
25375 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
25376
25377 * config/i386/i386.c (indirect_thunk_name): Declare regno
25378 as unsigned int. Compare regno with INVALID_REGNUM.
25379 (output_indirect_thunk): Ditto.
25380 (output_indirect_thunk_function): Ditto.
25381 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
25382 in the call to output_indirect_thunk_function.
25383
25384 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
25385
25386 PR middle-end/83884
25387 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
25388 rather than the size of inner_type to determine the stack slot size
25389 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
25390
25391 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
25392
25393 PR target/83546
25394 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
25395 to PTA_SILVERMONT.
25396
25397 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
25398
25399 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
25400 endian Linux systems to optionally enable multilibs for selecting
25401 the long double type if the user configured an explicit type.
25402 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
25403 have no long double multilibs if not defined.
25404 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
25405 warn if the user used -mabi={ieee,ibm}longdouble and we built
25406 multilibs for long double.
25407 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
25408 appropriate multilib option.
25409 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
25410 multilib options.
25411 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
25412 for building long double multilibs.
25413 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
25414
25415 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
25416
25417 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
25418 copies.
25419
25420 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
25421 64 bits.
25422 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
25423 128 bits.
25424
25425 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
25426 variables.
25427
25428 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
25429 return value.
25430
25431 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25432
25433 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
25434 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
25435
25436 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
25437
25438 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
25439 different rtl trees depending on TARGET_64BIT.
25440 (rs6000_gen_lvx): Likewise.
25441
25442 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25443
25444 * config/visium/visium.md (nop): Tweak comment.
25445 (hazard_nop): Likewise.
25446
25447 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25448
25449 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
25450 -mspeculate-indirect-jumps.
25451 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
25452 for -mno-speculate-indirect-jumps.
25453 (*call_indirect_elfv2<mode>_nospec): New define_insn.
25454 (*call_value_indirect_elfv2<mode>): Disable for
25455 -mno-speculate-indirect-jumps.
25456 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
25457 (indirect_jump): Emit different RTL for
25458 -mno-speculate-indirect-jumps.
25459 (*indirect_jump<mode>): Disable for
25460 -mno-speculate-indirect-jumps.
25461 (*indirect_jump<mode>_nospec): New define_insn.
25462 (tablejump): Emit different RTL for
25463 -mno-speculate-indirect-jumps.
25464 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
25465 (tablejumpsi_nospec): New define_expand.
25466 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
25467 (tablejumpdi_nospec): New define_expand.
25468 (*tablejump<mode>_internal1): Disable for
25469 -mno-speculate-indirect-jumps.
25470 (*tablejump<mode>_internal1_nospec): New define_insn.
25471 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
25472 option.
25473
25474 2018-01-16 Artyom Skrobov tyomitch@gmail.com
25475
25476 * caller-save.c (insert_save): Drop unnecessary parameter. All
25477 callers updated.
25478
25479 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25480 Richard Biener <rguenth@suse.de>
25481
25482 PR libgomp/83590
25483 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
25484 return early, inline manually is_gimple_sizepos. Make sure if we
25485 call gimplify_expr we don't end up with a gimple constant.
25486 * tree.c (variably_modified_type_p): Don't return true for
25487 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
25488 * gimplify.h (is_gimple_sizepos): Remove.
25489
25490 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25491
25492 PR tree-optimization/83857
25493 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
25494 vectorizable_live_operation for pure SLP statements.
25495 (vectorizable_live_operation): Handle PHIs.
25496
25497 2018-01-16 Richard Biener <rguenther@suse.de>
25498
25499 PR tree-optimization/83867
25500 * tree-vect-stmts.c (vect_transform_stmt): Precompute
25501 nested_in_vect_loop_p since the scalar stmt may get invalidated.
25502
25503 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25504
25505 PR c/83844
25506 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
25507 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
25508 If off is not INTEGER_CST, issue a may not be aligned warning
25509 rather than isn't aligned. Use isn%'t rather than isn't.
25510 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
25511 into MULT_EXPR.
25512 <case MULT_EXPR>: Improve the case when bottom and one of the
25513 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
25514 operand, in that case check if the other operand is multiple of
25515 bottom divided by the INTEGER_CST operand.
25516
25517 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25518
25519 PR target/83858
25520 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
25521 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
25522 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
25523 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
25524 * config/pa/pa.c (pa_function_arg_advance): Likewise.
25525 (pa_function_arg, pa_arg_partial_bytes): Likewise.
25526 (pa_function_arg_size): New function.
25527
25528 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25529
25530 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
25531 in a separate statement.
25532
25533 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25534
25535 PR tree-optimization/83847
25536 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
25537 group gathers and scatters.
25538
25539 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25540
25541 PR rtl-optimization/86620
25542 * params.def (max-sched-ready-insns): Bump minimum value to 1.
25543
25544 PR rtl-optimization/83213
25545 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
25546 to last if both are JUMP_INSNs.
25547
25548 PR tree-optimization/83843
25549 * gimple-ssa-store-merging.c
25550 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
25551 store_immediate_info for bswap/nop orig_stores.
25552
25553 2018-01-15 Andrew Waterman <andrew@sifive.com>
25554
25555 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
25556 !TARGET_MUL.
25557 <UDIV>: Increase cost if !TARGET_DIV.
25558
25559 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
25560
25561 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
25562 (define_attr "cr_logical_3op"): New.
25563 (cceq_ior_compare): Adjust.
25564 (cceq_ior_compare_complement): Adjust.
25565 (*cceq_rev_compare): Adjust.
25566 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
25567 (is_cracked_insn): Adjust.
25568 (insn_must_be_first_in_group): Adjust.
25569 * config/rs6000/40x.md: Adjust.
25570 * config/rs6000/440.md: Adjust.
25571 * config/rs6000/476.md: Adjust.
25572 * config/rs6000/601.md: Adjust.
25573 * config/rs6000/603.md: Adjust.
25574 * config/rs6000/6xx.md: Adjust.
25575 * config/rs6000/7450.md: Adjust.
25576 * config/rs6000/7xx.md: Adjust.
25577 * config/rs6000/8540.md: Adjust.
25578 * config/rs6000/cell.md: Adjust.
25579 * config/rs6000/e300c2c3.md: Adjust.
25580 * config/rs6000/e500mc.md: Adjust.
25581 * config/rs6000/e500mc64.md: Adjust.
25582 * config/rs6000/e5500.md: Adjust.
25583 * config/rs6000/e6500.md: Adjust.
25584 * config/rs6000/mpc.md: Adjust.
25585 * config/rs6000/power4.md: Adjust.
25586 * config/rs6000/power5.md: Adjust.
25587 * config/rs6000/power6.md: Adjust.
25588 * config/rs6000/power7.md: Adjust.
25589 * config/rs6000/power8.md: Adjust.
25590 * config/rs6000/power9.md: Adjust.
25591 * config/rs6000/rs64.md: Adjust.
25592 * config/rs6000/titan.md: Adjust.
25593
25594 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25595
25596 * config/i386/predicates.md (indirect_branch_operand): Rewrite
25597 ix86_indirect_branch_register logic.
25598
25599 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25600
25601 * config/i386/constraints.md (Bs): Update
25602 ix86_indirect_branch_register check. Don't check
25603 ix86_indirect_branch_register with GOT_memory_operand.
25604 (Bw): Likewise.
25605 * config/i386/predicates.md (GOT_memory_operand): Don't check
25606 ix86_indirect_branch_register here.
25607 (GOT32_symbol_operand): Likewise.
25608
25609 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25610
25611 * config/i386/predicates.md (constant_call_address_operand):
25612 Rewrite ix86_indirect_branch_register logic.
25613 (sibcall_insn_operand): Likewise.
25614
25615 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25616
25617 * config/i386/constraints.md (Bs): Replace
25618 ix86_indirect_branch_thunk_register with
25619 ix86_indirect_branch_register.
25620 (Bw): Likewise.
25621 * config/i386/i386.md (indirect_jump): Likewise.
25622 (tablejump): Likewise.
25623 (*sibcall_memory): Likewise.
25624 (*sibcall_value_memory): Likewise.
25625 Peepholes of indirect call and jump via memory: Likewise.
25626 * config/i386/i386.opt: Likewise.
25627 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25628 (GOT_memory_operand): Likewise.
25629 (call_insn_operand): Likewise.
25630 (sibcall_insn_operand): Likewise.
25631 (GOT32_symbol_operand): Likewise.
25632
25633 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25634
25635 PR middle-end/83837
25636 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
25637 type rather than type addr's type points to.
25638 (expand_omp_atomic_mutex): Likewise.
25639 (expand_omp_atomic): Likewise.
25640
25641 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25642
25643 PR target/83839
25644 * config/i386/i386.c (output_indirect_thunk_function): Use
25645 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
25646 for __x86_return_thunk.
25647
25648 2018-01-15 Richard Biener <rguenther@suse.de>
25649
25650 PR middle-end/83850
25651 * expmed.c (extract_bit_field_1): Fix typo.
25652
25653 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25654
25655 PR target/83687
25656 * config/arm/iterators.md (VF): New mode iterator.
25657 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
25658 Remove integer-related logic from pattern.
25659 (neon_vabd<mode>_3): Likewise.
25660
25661 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25662
25663 PR middle-end/82694
25664 * common.opt (fstrict-overflow): No longer an alias.
25665 (fwrapv-pointer): New option.
25666 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
25667 also for pointer types based on flag_wrapv_pointer.
25668 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
25669 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
25670 opts->x_flag_wrapv got set.
25671 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
25672 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
25673 POINTER_TYPE_OVERFLOW_UNDEFINED.
25674 * match.pd: Likewise in address comparison pattern.
25675 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
25676
25677 2018-01-15 Richard Biener <rguenther@suse.de>
25678
25679 PR lto/83804
25680 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
25681 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
25682 Reset type names to their identifier if their TYPE_DECL doesn't
25683 have linkage (and thus is used for ODR and devirt).
25684 (save_debug_info_for_decl): Remove.
25685 (save_debug_info_for_type): Likewise.
25686 (add_tree_to_fld_list): Adjust.
25687 * tree-pretty-print.c (dump_generic_node): Make dumping of
25688 type names more robust.
25689
25690 2018-01-15 Richard Biener <rguenther@suse.de>
25691
25692 * BASE-VER: Bump to 8.0.1.
25693
25694 2018-01-14 Martin Sebor <msebor@redhat.com>
25695
25696 PR other/83508
25697 * builtins.c (check_access): Avoid warning when the no-warning bit
25698 is set.
25699
25700 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
25701
25702 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
25703 * ira-color (allocno_hard_regs_compare): Likewise.
25704
25705 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
25706
25707 PR target/83013
25708 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
25709 Use .pushsection/.popsection.
25710
25711 2018-01-14 Martin Sebor <msebor@redhat.com>
25712
25713 PR c++/81327
25714 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
25715
25716 2018-01-14 Jakub Jelinek <jakub@redhat.com>
25717
25718 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
25719 entry from extra_headers.
25720 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
25721 extra_headers, make the list bitwise identical to the i?86-*-* one.
25722
25723 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25724
25725 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
25726 -mcmodel=large with -mindirect-branch=thunk,
25727 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
25728 -mfunction-return=thunk-extern.
25729 * doc/invoke.texi: Document -mcmodel=large is incompatible with
25730 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
25731 -mfunction-return=thunk and -mfunction-return=thunk-extern.
25732
25733 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25734
25735 * config/i386/i386.c (print_reg): Print the name of the full
25736 integer register without '%'.
25737 (ix86_print_operand): Handle 'V'.
25738 * doc/extend.texi: Document 'V' modifier.
25739
25740 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25741
25742 * config/i386/constraints.md (Bs): Disallow memory operand for
25743 -mindirect-branch-register.
25744 (Bw): Likewise.
25745 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25746 (GOT_memory_operand): Likewise.
25747 (call_insn_operand): Likewise.
25748 (sibcall_insn_operand): Likewise.
25749 (GOT32_symbol_operand): Likewise.
25750 * config/i386/i386.md (indirect_jump): Call convert_memory_address
25751 for -mindirect-branch-register.
25752 (tablejump): Likewise.
25753 (*sibcall_memory): Likewise.
25754 (*sibcall_value_memory): Likewise.
25755 Disallow peepholes of indirect call and jump via memory for
25756 -mindirect-branch-register.
25757 (*call_pop): Replace m with Bw.
25758 (*call_value_pop): Likewise.
25759 (*sibcall_pop_memory): Replace m with Bs.
25760 * config/i386/i386.opt (mindirect-branch-register): New option.
25761 * doc/invoke.texi: Document -mindirect-branch-register option.
25762
25763 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25764
25765 * config/i386/i386-protos.h (ix86_output_function_return): New.
25766 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
25767 set function_return_type.
25768 (indirect_thunk_name): Add ret_p to indicate thunk for function
25769 return.
25770 (output_indirect_thunk_function): Pass false to
25771 indirect_thunk_name.
25772 (ix86_output_indirect_branch_via_reg): Likewise.
25773 (ix86_output_indirect_branch_via_push): Likewise.
25774 (output_indirect_thunk_function): Create alias for function
25775 return thunk if regno < 0.
25776 (ix86_output_function_return): New function.
25777 (ix86_handle_fndecl_attribute): Handle function_return.
25778 (ix86_attribute_table): Add function_return.
25779 * config/i386/i386.h (machine_function): Add
25780 function_return_type.
25781 * config/i386/i386.md (simple_return_internal): Use
25782 ix86_output_function_return.
25783 (simple_return_internal_long): Likewise.
25784 * config/i386/i386.opt (mfunction-return=): New option.
25785 (indirect_branch): Mention -mfunction-return=.
25786 * doc/extend.texi: Document function_return function attribute.
25787 * doc/invoke.texi: Document -mfunction-return= option.
25788
25789 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25790
25791 * config/i386/i386-opts.h (indirect_branch): New.
25792 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
25793 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
25794 with local indirect jump when converting indirect call and jump.
25795 (ix86_set_indirect_branch_type): New.
25796 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
25797 (indirectlabelno): New.
25798 (indirect_thunk_needed): Likewise.
25799 (indirect_thunk_bnd_needed): Likewise.
25800 (indirect_thunks_used): Likewise.
25801 (indirect_thunks_bnd_used): Likewise.
25802 (INDIRECT_LABEL): Likewise.
25803 (indirect_thunk_name): Likewise.
25804 (output_indirect_thunk): Likewise.
25805 (output_indirect_thunk_function): Likewise.
25806 (ix86_output_indirect_branch_via_reg): Likewise.
25807 (ix86_output_indirect_branch_via_push): Likewise.
25808 (ix86_output_indirect_branch): Likewise.
25809 (ix86_output_indirect_jmp): Likewise.
25810 (ix86_code_end): Call output_indirect_thunk_function if needed.
25811 (ix86_output_call_insn): Call ix86_output_indirect_branch if
25812 needed.
25813 (ix86_handle_fndecl_attribute): Handle indirect_branch.
25814 (ix86_attribute_table): Add indirect_branch.
25815 * config/i386/i386.h (machine_function): Add indirect_branch_type
25816 and has_local_indirect_jump.
25817 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
25818 to true.
25819 (tablejump): Likewise.
25820 (*indirect_jump): Use ix86_output_indirect_jmp.
25821 (*tablejump_1): Likewise.
25822 (simple_return_indirect_internal): Likewise.
25823 * config/i386/i386.opt (mindirect-branch=): New option.
25824 (indirect_branch): New.
25825 (keep): Likewise.
25826 (thunk): Likewise.
25827 (thunk-inline): Likewise.
25828 (thunk-extern): Likewise.
25829 * doc/extend.texi: Document indirect_branch function attribute.
25830 * doc/invoke.texi: Document -mindirect-branch= option.
25831
25832 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
25833
25834 PR ipa/83051
25835 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
25836
25837 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
25838
25839 * ipa-inline.c (want_inline_small_function_p): Return false if
25840 inlining has already failed with CIF_FINAL_ERROR.
25841 (update_caller_keys): Call want_inline_small_function_p before
25842 can_inline_edge_p.
25843 (update_callee_keys): Likewise.
25844
25845 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25846
25847 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
25848 New function.
25849 (rs6000_quadword_masked_address_p): Likewise.
25850 (quad_aligned_load_p): Likewise.
25851 (quad_aligned_store_p): Likewise.
25852 (const_load_sequence_p): Add comment to describe the outer-most loop.
25853 (mimic_memory_attributes_and_flags): New function.
25854 (rs6000_gen_stvx): Likewise.
25855 (replace_swapped_aligned_store): Likewise.
25856 (rs6000_gen_lvx): Likewise.
25857 (replace_swapped_aligned_load): Likewise.
25858 (replace_swapped_load_constant): Capitalize argument name in
25859 comment describing this function.
25860 (rs6000_analyze_swaps): Add a third pass to search for vector loads
25861 and stores that access quad-word aligned addresses and replace
25862 with stvx or lvx instructions when appropriate.
25863 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
25864 New function prototype.
25865 (rs6000_quadword_masked_address_p): Likewise.
25866 (rs6000_gen_lvx): Likewise.
25867 (rs6000_gen_stvx): Likewise.
25868 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
25869 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
25870 when memory address is aligned.
25871 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
25872 this split to select lvx instruction when memory address is aligned.
25873 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
25874 instruction when memory address is aligned.
25875 (*vsx_le_perm_load_v16qi): Likewise.
25876 (four unnamed splitters): Modify to select the stvx instruction
25877 when memory is aligned.
25878
25879 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
25880
25881 * predict.c (determine_unlikely_bbs): Handle correctly BBs
25882 which appears in the queue multiple times.
25883
25884 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25885 Alan Hayward <alan.hayward@arm.com>
25886 David Sherwood <david.sherwood@arm.com>
25887
25888 * tree-vectorizer.h (vec_lower_bound): New structure.
25889 (_loop_vec_info): Add check_nonzero and lower_bounds.
25890 (LOOP_VINFO_CHECK_NONZERO): New macro.
25891 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
25892 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
25893 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
25894 fields. Make seg_len the distance travelled, not including the
25895 access size.
25896 (dr_direction_indicator): Declare.
25897 (dr_zero_step_indicator): Likewise.
25898 (dr_known_forward_stride_p): Likewise.
25899 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
25900 tree-ssanames.h.
25901 (runtime_alias_check_p): Allow runtime alias checks with
25902 variable strides.
25903 (operator ==): Compare access_size and align.
25904 (prune_runtime_alias_test_list): Rework for new distinction between
25905 the access_size and seg_len.
25906 (create_intersect_range_checks_index): Likewise. Cope with polynomial
25907 segment lengths.
25908 (get_segment_min_max): New function.
25909 (create_intersect_range_checks): Use it.
25910 (dr_step_indicator): New function.
25911 (dr_direction_indicator): Likewise.
25912 (dr_zero_step_indicator): Likewise.
25913 (dr_known_forward_stride_p): Likewise.
25914 * tree-loop-distribution.c (data_ref_segment_size): Return
25915 DR_STEP * (niters - 1).
25916 (compute_alias_check_pairs): Update call to the dr_with_seg_len
25917 constructor.
25918 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
25919 (vect_preserves_scalar_order_p): New function, split out from...
25920 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
25921 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
25922 (vect_vfa_access_size): New function.
25923 (vect_vfa_align): Likewise.
25924 (vect_compile_time_alias): Take access_size_a and access_b arguments.
25925 (dump_lower_bound): New function.
25926 (vect_check_lower_bound): Likewise.
25927 (vect_small_gap_p): Likewise.
25928 (vectorizable_with_step_bound_p): Likewise.
25929 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
25930 depencies if the vectorization factor is 1. Convert the checks
25931 for nonzero steps into checks on the bounds of DR_STEP. Try using
25932 a bunds check for variable steps if the minimum required step is
25933 relatively small. Update calls to the dr_with_seg_len
25934 constructor and to vect_compile_time_alias.
25935 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
25936 function.
25937 (vect_loop_versioning): Call it.
25938 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
25939 when retrying.
25940 (vect_estimate_min_profitable_iters): Account for any bounds checks.
25941
25942 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25943 Alan Hayward <alan.hayward@arm.com>
25944 David Sherwood <david.sherwood@arm.com>
25945
25946 * doc/sourcebuild.texi (vect_scatter_store): Document.
25947 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
25948 optabs.
25949 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
25950 Document.
25951 * genopinit.c (main): Add supports_vec_scatter_store and
25952 supports_vec_scatter_store_cached to target_optabs.
25953 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
25954 IFN_MASK_SCATTER_STORE.
25955 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
25956 functions.
25957 * internal-fn.h (internal_store_fn_p): Declare.
25958 (internal_fn_stored_value_index): Likewise.
25959 * internal-fn.c (scatter_store_direct): New macro.
25960 (expand_scatter_store_optab_fn): New function.
25961 (direct_scatter_store_optab_supported_p): New macro.
25962 (internal_store_fn_p): New function.
25963 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
25964 IFN_MASK_SCATTER_STORE.
25965 (internal_fn_mask_index): Likewise.
25966 (internal_fn_stored_value_index): New function.
25967 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
25968 for scatter stores.
25969 * optabs-query.h (supports_vec_scatter_store_p): Declare.
25970 * optabs-query.c (supports_vec_scatter_store_p): New function.
25971 * tree-vectorizer.h (vect_get_store_rhs): Declare.
25972 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
25973 true for scatter stores.
25974 (vect_gather_scatter_fn_p): Handle scatter stores too.
25975 (vect_check_gather_scatter): Consider using scatter stores if
25976 supports_vec_scatter_store_p.
25977 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
25978 scatter stores too.
25979 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
25980 internal_fn_stored_value_index.
25981 (check_load_store_masking): Handle scatter stores too.
25982 (vect_get_store_rhs): Make public.
25983 (vectorizable_call): Use internal_store_fn_p.
25984 (vectorizable_store): Handle scatter store internal functions.
25985 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
25986 when deciding whether the end of the group has been reached.
25987 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
25988 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
25989 (mask_scatter_store<mode>): New insns.
25990
25991 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25992 Alan Hayward <alan.hayward@arm.com>
25993 David Sherwood <david.sherwood@arm.com>
25994
25995 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
25996 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
25997 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
25998 function.
25999 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
26000 Use vect_truncate_gather_scatter_offset if we can't treat the
26001 operation as a normal gather load or scatter store.
26002 (get_group_load_store_type): Take the gather_scatter_info
26003 as argument. Try using a gather load or scatter store for
26004 single-element groups.
26005 (get_load_store_type): Update calls to get_group_load_store_type
26006 and vect_use_strided_gather_scatters_p.
26007
26008 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26009 Alan Hayward <alan.hayward@arm.com>
26010 David Sherwood <david.sherwood@arm.com>
26011
26012 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
26013 optional tree argument.
26014 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
26015 null target hooks.
26016 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
26017 but continue to use the current value as a fallback.
26018 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
26019 to compare the updates.
26020 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
26021 (get_load_store_type): Use it when handling a strided access.
26022 (vect_get_strided_load_store_ops): New function.
26023 (vect_get_data_ptr_increment): Likewise.
26024 (vectorizable_load): Handle strided gather loads. Always pass
26025 a step to vect_create_data_ref_ptr and bump_vector_ptr.
26026
26027 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26028 Alan Hayward <alan.hayward@arm.com>
26029 David Sherwood <david.sherwood@arm.com>
26030
26031 * doc/md.texi (gather_load@var{m}): Document.
26032 (mask_gather_load@var{m}): Likewise.
26033 * genopinit.c (main): Add supports_vec_gather_load and
26034 supports_vec_gather_load_cached to target_optabs.
26035 * optabs-tree.c (init_tree_optimization_optabs): Use
26036 ggc_cleared_alloc to allocate target_optabs.
26037 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
26038 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
26039 functions.
26040 * internal-fn.h (internal_load_fn_p): Declare.
26041 (internal_gather_scatter_fn_p): Likewise.
26042 (internal_fn_mask_index): Likewise.
26043 (internal_gather_scatter_fn_supported_p): Likewise.
26044 * internal-fn.c (gather_load_direct): New macro.
26045 (expand_gather_load_optab_fn): New function.
26046 (direct_gather_load_optab_supported_p): New macro.
26047 (direct_internal_fn_optab): New function.
26048 (internal_load_fn_p): Likewise.
26049 (internal_gather_scatter_fn_p): Likewise.
26050 (internal_fn_mask_index): Likewise.
26051 (internal_gather_scatter_fn_supported_p): Likewise.
26052 * optabs-query.c (supports_at_least_one_mode_p): New function.
26053 (supports_vec_gather_load_p): Likewise.
26054 * optabs-query.h (supports_vec_gather_load_p): Declare.
26055 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
26056 and memory_type field.
26057 (NUM_PATTERNS): Bump to 15.
26058 * tree-vect-data-refs.c: Include internal-fn.h.
26059 (vect_gather_scatter_fn_p): New function.
26060 (vect_describe_gather_scatter_call): Likewise.
26061 (vect_check_gather_scatter): Try using internal functions for
26062 gather loads. Recognize existing calls to a gather load function.
26063 (vect_analyze_data_refs): Consider using gather loads if
26064 supports_vec_gather_load_p.
26065 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
26066 (vect_get_gather_scatter_offset_type): Likewise.
26067 (vect_convert_mask_for_vectype): Likewise.
26068 (vect_add_conversion_to_patterm): Likewise.
26069 (vect_try_gather_scatter_pattern): Likewise.
26070 (vect_recog_gather_scatter_pattern): New pattern recognizer.
26071 (vect_vect_recog_func_ptrs): Add it.
26072 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
26073 internal_fn_mask_index and internal_gather_scatter_fn_p.
26074 (check_load_store_masking): Take the gather_scatter_info as an
26075 argument and handle gather loads.
26076 (vect_get_gather_scatter_ops): New function.
26077 (vectorizable_call): Check internal_load_fn_p.
26078 (vectorizable_load): Likewise. Handle gather load internal
26079 functions.
26080 (vectorizable_store): Update call to check_load_store_masking.
26081 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
26082 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
26083 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
26084 (aarch64_gather_scale_operand_d): New predicates.
26085 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
26086 (mask_gather_load<mode>): New insns.
26087
26088 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26089 Alan Hayward <alan.hayward@arm.com>
26090 David Sherwood <david.sherwood@arm.com>
26091
26092 * optabs.def (fold_left_plus_optab): New optab.
26093 * doc/md.texi (fold_left_plus_@var{m}): Document.
26094 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
26095 * internal-fn.c (fold_left_direct): Define.
26096 (expand_fold_left_optab_fn): Likewise.
26097 (direct_fold_left_optab_supported_p): Likewise.
26098 * fold-const-call.c (fold_const_fold_left): New function.
26099 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
26100 * tree-parloops.c (valid_reduction_p): New function.
26101 (gather_scalar_reductions): Use it.
26102 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
26103 (vect_finish_replace_stmt): Declare.
26104 * tree-vect-loop.c (fold_left_reduction_fn): New function.
26105 (needs_fold_left_reduction_p): New function, split out from...
26106 (vect_is_simple_reduction): ...here. Accept reductions that
26107 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
26108 (vect_force_simple_reduction): Also store the reduction type in
26109 the assignment's STMT_VINFO_REDUC_TYPE.
26110 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
26111 (merge_with_identity): New function.
26112 (vect_expand_fold_left): Likewise.
26113 (vectorize_fold_left_reduction): Likewise.
26114 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
26115 scalar phi in place for it. Check for target support and reject
26116 cases that would reassociate the operation. Defer the transform
26117 phase to vectorize_fold_left_reduction.
26118 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
26119 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
26120 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
26121
26122 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26123
26124 * tree-if-conv.c (predicate_mem_writes): Remove redundant
26125 call to ifc_temp_var.
26126
26127 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26128 Alan Hayward <alan.hayward@arm.com>
26129 David Sherwood <david.sherwood@arm.com>
26130
26131 * target.def (legitimize_address_displacement): Take the original
26132 offset as a poly_int.
26133 * targhooks.h (default_legitimize_address_displacement): Update
26134 accordingly.
26135 * targhooks.c (default_legitimize_address_displacement): Likewise.
26136 * doc/tm.texi: Regenerate.
26137 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
26138 as an argument, moving assert of ad->disp == ad->disp_term to...
26139 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
26140 Try calling targetm.legitimize_address_displacement before expanding
26141 the address rather than afterwards, and adjust for the new interface.
26142 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
26143 Match the new hook interface. Handle SVE addresses.
26144 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
26145 new hook interface.
26146
26147 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26148
26149 * Makefile.in (OBJS): Add early-remat.o.
26150 * target.def (select_early_remat_modes): New hook.
26151 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
26152 * doc/tm.texi: Regenerate.
26153 * targhooks.h (default_select_early_remat_modes): Declare.
26154 * targhooks.c (default_select_early_remat_modes): New function.
26155 * timevar.def (TV_EARLY_REMAT): New timevar.
26156 * passes.def (pass_early_remat): New pass.
26157 * tree-pass.h (make_pass_early_remat): Declare.
26158 * early-remat.c: New file.
26159 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
26160 function.
26161 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
26162
26163 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26164 Alan Hayward <alan.hayward@arm.com>
26165 David Sherwood <david.sherwood@arm.com>
26166
26167 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
26168 vfm1 with a bound_epilog parameter.
26169 (vect_do_peeling): Update calls accordingly, and move the prologue
26170 call earlier in the function. Treat the base bound_epilog as 0 for
26171 fully-masked loops and retain vf - 1 for other loops. Add 1 to
26172 this base when peeling for gaps.
26173 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
26174 with fully-masked loops.
26175 (vect_estimate_min_profitable_iters): Handle the single peeled
26176 iteration in that case.
26177
26178 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26179 Alan Hayward <alan.hayward@arm.com>
26180 David Sherwood <david.sherwood@arm.com>
26181
26182 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
26183 single-element interleaving even if the size is not a power of 2.
26184 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
26185 accesses for single-element interleaving if the group size is
26186 not a power of 2.
26187
26188 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26189 Alan Hayward <alan.hayward@arm.com>
26190 David Sherwood <david.sherwood@arm.com>
26191
26192 * doc/md.texi (fold_extract_last_@var{m}): Document.
26193 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
26194 * optabs.def (fold_extract_last_optab): New optab.
26195 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
26196 * internal-fn.c (fold_extract_direct): New macro.
26197 (expand_fold_extract_optab_fn): Likewise.
26198 (direct_fold_extract_optab_supported_p): Likewise.
26199 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
26200 * tree-vect-loop.c (vect_model_reduction_cost): Handle
26201 EXTRACT_LAST_REDUCTION.
26202 (get_initial_def_for_reduction): Do not create an initial vector
26203 for EXTRACT_LAST_REDUCTION reductions.
26204 (vectorizable_reduction): Leave the scalar phi in place for
26205 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
26206 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
26207 epilogue code for EXTRACT_LAST_REDUCTION and defer the
26208 transform phase to vectorizable_condition.
26209 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
26210 split out from...
26211 (vect_finish_stmt_generation): ...here.
26212 (vect_finish_replace_stmt): New function.
26213 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
26214 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
26215 pattern.
26216 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
26217
26218 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26219 Alan Hayward <alan.hayward@arm.com>
26220 David Sherwood <david.sherwood@arm.com>
26221
26222 * doc/md.texi (extract_last_@var{m}): Document.
26223 * optabs.def (extract_last_optab): New optab.
26224 * internal-fn.def (EXTRACT_LAST): New internal function.
26225 * internal-fn.c (cond_unary_direct): New macro.
26226 (expand_cond_unary_optab_fn): Likewise.
26227 (direct_cond_unary_optab_supported_p): Likewise.
26228 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
26229 loops using EXTRACT_LAST.
26230 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
26231 (extract_last_<mode>): ...this optab.
26232 (vec_extract<mode><Vel>): Update accordingly.
26233
26234 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26235 Alan Hayward <alan.hayward@arm.com>
26236 David Sherwood <david.sherwood@arm.com>
26237
26238 * target.def (empty_mask_is_expensive): New hook.
26239 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
26240 * doc/tm.texi: Regenerate.
26241 * targhooks.h (default_empty_mask_is_expensive): Declare.
26242 * targhooks.c (default_empty_mask_is_expensive): New function.
26243 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
26244 if the target says that empty masks are expensive.
26245 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
26246 New function.
26247 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
26248
26249 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26250 Alan Hayward <alan.hayward@arm.com>
26251 David Sherwood <david.sherwood@arm.com>
26252
26253 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
26254 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
26255 (vect_use_loop_mask_for_alignment_p): New function.
26256 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
26257 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
26258 niters_skip argument. Make sure that the first niters_skip elements
26259 of the first iteration are inactive.
26260 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
26261 Update call to vect_set_loop_masks_directly.
26262 (get_misalign_in_elems): New function, split out from...
26263 (vect_gen_prolog_loop_niters): ...here.
26264 (vect_update_init_of_dr): Take a code argument that specifies whether
26265 the adjustment should be added or subtracted.
26266 (vect_update_init_of_drs): Likewise.
26267 (vect_prepare_for_masked_peels): New function.
26268 (vect_do_peeling): Skip prologue peeling if we're using a mask
26269 instead. Update call to vect_update_inits_of_drs.
26270 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26271 mask_skip_niters.
26272 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
26273 alignment. Do not include the number of peeled iterations in
26274 the minimum threshold in that case.
26275 (vectorizable_induction): Adjust the start value down by
26276 LOOP_VINFO_MASK_SKIP_NITERS iterations.
26277 (vect_transform_loop): Call vect_prepare_for_masked_peels.
26278 Take the number of skipped iterations into account when calculating
26279 the loop bounds.
26280 * tree-vect-stmts.c (vect_gen_while_not): New function.
26281
26282 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26283 Alan Hayward <alan.hayward@arm.com>
26284 David Sherwood <david.sherwood@arm.com>
26285
26286 * doc/sourcebuild.texi (vect_fully_masked): Document.
26287 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
26288 default value to 0.
26289 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
26290 split out from...
26291 (vect_analyze_loop_2): ...here. Don't check the vectorization
26292 factor against the number of loop iterations if the loop is
26293 fully-masked.
26294
26295 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26296 Alan Hayward <alan.hayward@arm.com>
26297 David Sherwood <david.sherwood@arm.com>
26298
26299 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
26300 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
26301 (dump_groups): Update accordingly.
26302 (iv_use::mem_type): New member variable.
26303 (address_p): New function.
26304 (record_use): Add a mem_type argument and initialize the new
26305 mem_type field.
26306 (record_group_use): Add a mem_type argument. Use address_p.
26307 Remove obsolete null checks of base_object. Update call to record_use.
26308 (find_interesting_uses_op): Update call to record_group_use.
26309 (find_interesting_uses_cond): Likewise.
26310 (find_interesting_uses_address): Likewise.
26311 (get_mem_type_for_internal_fn): New function.
26312 (find_address_like_use): Likewise.
26313 (find_interesting_uses_stmt): Try find_address_like_use before
26314 calling find_interesting_uses_op.
26315 (addr_offset_valid_p): Use the iv mem_type field as the type
26316 of the addressed memory.
26317 (add_autoinc_candidates): Likewise.
26318 (get_address_cost): Likewise.
26319 (split_small_address_groups_p): Use address_p.
26320 (split_address_groups): Likewise.
26321 (add_iv_candidate_for_use): Likewise.
26322 (autoinc_possible_for_pair): Likewise.
26323 (rewrite_groups): Likewise.
26324 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
26325 (determine_group_iv_cost): Update after split of USE_ADDRESS.
26326 (get_alias_ptr_type_for_ptr_address): New function.
26327 (rewrite_use_address): Rewrite address uses in calls that were
26328 identified by find_address_like_use.
26329
26330 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26331 Alan Hayward <alan.hayward@arm.com>
26332 David Sherwood <david.sherwood@arm.com>
26333
26334 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
26335 TARGET_MEM_REFs.
26336 * gimple-expr.h (is_gimple_addressable: Likewise.
26337 * gimple-expr.c (is_gimple_address): Likewise.
26338 * internal-fn.c (expand_call_mem_ref): New function.
26339 (expand_mask_load_optab_fn): Use it.
26340 (expand_mask_store_optab_fn): Likewise.
26341
26342 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26343 Alan Hayward <alan.hayward@arm.com>
26344 David Sherwood <david.sherwood@arm.com>
26345
26346 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
26347 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
26348 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
26349 (cond_umax@var{mode}): Document.
26350 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
26351 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
26352 (cond_umin_optab, cond_umax_optab): New optabs.
26353 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
26354 (COND_IOR, COND_XOR): New internal functions.
26355 * internal-fn.h (get_conditional_internal_fn): Declare.
26356 * internal-fn.c (cond_binary_direct): New macro.
26357 (expand_cond_binary_optab_fn): Likewise.
26358 (direct_cond_binary_optab_supported_p): Likewise.
26359 (get_conditional_internal_fn): New function.
26360 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
26361 Cope with reduction statements that are vectorized as calls rather
26362 than assignments.
26363 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
26364 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
26365 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
26366 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
26367 (UNSPEC_COND_EOR): New unspecs.
26368 (optab): Add mappings for them.
26369 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
26370 (sve_int_op, sve_fp_op): New int attributes.
26371
26372 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26373 Alan Hayward <alan.hayward@arm.com>
26374 David Sherwood <david.sherwood@arm.com>
26375
26376 * optabs.def (while_ult_optab): New optab.
26377 * doc/md.texi (while_ult@var{m}@var{n}): Document.
26378 * internal-fn.def (WHILE_ULT): New internal function.
26379 * internal-fn.h (direct_internal_fn_supported_p): New override
26380 that takes two types as argument.
26381 * internal-fn.c (while_direct): New macro.
26382 (expand_while_optab_fn): New function.
26383 (convert_optab_supported_p): Likewise.
26384 (direct_while_optab_supported_p): New macro.
26385 * wide-int.h (wi::udiv_ceil): New function.
26386 * tree-vectorizer.h (rgroup_masks): New structure.
26387 (vec_loop_masks): New typedef.
26388 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
26389 and fully_masked_p.
26390 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
26391 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
26392 (vect_max_vf): New function.
26393 (slpeel_make_loop_iterate_ntimes): Delete.
26394 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
26395 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
26396 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
26397 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
26398 internal-fn.h, stor-layout.h and optabs-query.h.
26399 (vect_set_loop_mask): New function.
26400 (add_preheader_seq): Likewise.
26401 (add_header_seq): Likewise.
26402 (interleave_supported_p): Likewise.
26403 (vect_maybe_permute_loop_masks): Likewise.
26404 (vect_set_loop_masks_directly): Likewise.
26405 (vect_set_loop_condition_masked): Likewise.
26406 (vect_set_loop_condition_unmasked): New function, split out from
26407 slpeel_make_loop_iterate_ntimes.
26408 (slpeel_make_loop_iterate_ntimes): Rename to..
26409 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
26410 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
26411 (vect_do_peeling): Update call accordingly.
26412 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
26413 loops.
26414 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26415 mask_compare_type, can_fully_mask_p and fully_masked_p.
26416 (release_vec_loop_masks): New function.
26417 (_loop_vec_info): Use it to free the loop masks.
26418 (can_produce_all_loop_masks_p): New function.
26419 (vect_get_max_nscalars_per_iter): Likewise.
26420 (vect_verify_full_masking): Likewise.
26421 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
26422 retries, and free the mask rgroups before retrying. Check loop-wide
26423 reasons for disallowing fully-masked loops. Make the final decision
26424 about whether use a fully-masked loop or not.
26425 (vect_estimate_min_profitable_iters): Do not assume that peeling
26426 for the number of iterations will be needed for fully-masked loops.
26427 (vectorizable_reduction): Disable fully-masked loops.
26428 (vectorizable_live_operation): Likewise.
26429 (vect_halve_mask_nunits): New function.
26430 (vect_double_mask_nunits): Likewise.
26431 (vect_record_loop_mask): Likewise.
26432 (vect_get_loop_mask): Likewise.
26433 (vect_transform_loop): Handle the case in which the final loop
26434 iteration might handle a partial vector. Call vect_set_loop_condition
26435 instead of slpeel_make_loop_iterate_ntimes.
26436 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
26437 (check_load_store_masking): New function.
26438 (prepare_load_store_mask): Likewise.
26439 (vectorizable_store): Handle fully-masked loops.
26440 (vectorizable_load): Likewise.
26441 (supportable_widening_operation): Use vect_halve_mask_nunits for
26442 booleans.
26443 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
26444 (vect_gen_while): New function.
26445 * config/aarch64/aarch64.md (umax<mode>3): New expander.
26446 (aarch64_uqdec<mode>): New insn.
26447
26448 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26449 Alan Hayward <alan.hayward@arm.com>
26450 David Sherwood <david.sherwood@arm.com>
26451
26452 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
26453 (reduc_xor_scal_optab): New optabs.
26454 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
26455 (reduc_xor_scal_@var{m}): Document.
26456 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
26457 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
26458 internal functions.
26459 * fold-const-call.c (fold_const_call): Handle them.
26460 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
26461 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
26462 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
26463 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
26464 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
26465 (UNSPEC_XORV): New unspecs.
26466 (optab): Add entries for them.
26467 (BITWISEV): New int iterator.
26468 (bit_reduc_op): New int attributes.
26469
26470 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26471 Alan Hayward <alan.hayward@arm.com>
26472 David Sherwood <david.sherwood@arm.com>
26473
26474 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
26475 * internal-fn.def (VEC_SHL_INSERT): New internal function.
26476 * optabs.def (vec_shl_insert_optab): New optab.
26477 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
26478 (duplicate_and_interleave): Likewise.
26479 * tree-vect-loop.c: Include internal-fn.h.
26480 (neutral_op_for_slp_reduction): New function, split out from
26481 get_initial_defs_for_reduction.
26482 (get_initial_def_for_reduction): Handle option 2 for variable-length
26483 vectors by loading the neutral value into a vector and then shifting
26484 the initial value into element 0.
26485 (get_initial_defs_for_reduction): Replace the code argument with
26486 the neutral value calculated by neutral_op_for_slp_reduction.
26487 Use gimple_build_vector for constant-length vectors.
26488 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
26489 but the first group_size elements have a neutral value.
26490 Use duplicate_and_interleave otherwise.
26491 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
26492 Update call to get_initial_defs_for_reduction. Handle SLP
26493 reductions for variable-length vectors by creating one vector
26494 result for each scalar result, with the elements associated
26495 with other scalar results stubbed out with the neutral value.
26496 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
26497 Require IFN_VEC_SHL_INSERT for double reductions on
26498 variable-length vectors, or SLP reductions that have
26499 a neutral value. Require can_duplicate_and_interleave_p
26500 support for variable-length unchained SLP reductions if there
26501 is no neutral value, such as for MIN/MAX reductions. Also require
26502 the number of vector elements to be a multiple of the number of
26503 SLP statements when doing variable-length unchained SLP reductions.
26504 Update call to vect_create_epilog_for_reduction.
26505 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
26506 and remove initial values.
26507 (duplicate_and_interleave): Make public.
26508 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
26509 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
26510
26511 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26512 Alan Hayward <alan.hayward@arm.com>
26513 David Sherwood <david.sherwood@arm.com>
26514
26515 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
26516 (can_duplicate_and_interleave_p): New function.
26517 (vect_get_and_check_slp_defs): Take the vector of statements
26518 rather than just the current one. Remove excess parentheses.
26519 Restriction rejectinon of vect_constant_def and vect_external_def
26520 for variable-length vectors to boolean types, or types for which
26521 can_duplicate_and_interleave_p is false.
26522 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
26523 (duplicate_and_interleave): New function.
26524 (vect_get_constant_vectors): Use gimple_build_vector for
26525 constant-length vectors and suitable variable-length constant
26526 vectors. Use duplicate_and_interleave for other variable-length
26527 vectors. Don't defer the update when inserting new statements.
26528
26529 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26530 Alan Hayward <alan.hayward@arm.com>
26531 David Sherwood <david.sherwood@arm.com>
26532
26533 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
26534 min_profitable_iters doesn't go negative.
26535
26536 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26537 Alan Hayward <alan.hayward@arm.com>
26538 David Sherwood <david.sherwood@arm.com>
26539
26540 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
26541 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
26542 * optabs.def (vec_mask_load_lanes_optab): New optab.
26543 (vec_mask_store_lanes_optab): Likewise.
26544 * internal-fn.def (MASK_LOAD_LANES): New internal function.
26545 (MASK_STORE_LANES): Likewise.
26546 * internal-fn.c (mask_load_lanes_direct): New macro.
26547 (mask_store_lanes_direct): Likewise.
26548 (expand_mask_load_optab_fn): Handle masked operations.
26549 (expand_mask_load_lanes_optab_fn): New macro.
26550 (expand_mask_store_optab_fn): Handle masked operations.
26551 (expand_mask_store_lanes_optab_fn): New macro.
26552 (direct_mask_load_lanes_optab_supported_p): Likewise.
26553 (direct_mask_store_lanes_optab_supported_p): Likewise.
26554 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
26555 parameter.
26556 (vect_load_lanes_supported): Likewise.
26557 * tree-vect-data-refs.c (strip_conversion): New function.
26558 (can_group_stmts_p): Likewise.
26559 (vect_analyze_data_ref_accesses): Use it instead of checking
26560 for a pair of assignments.
26561 (vect_store_lanes_supported): Take a masked_p parameter.
26562 (vect_load_lanes_supported): Likewise.
26563 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
26564 vect_store_lanes_supported and vect_load_lanes_supported.
26565 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
26566 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
26567 parameter. Don't allow gaps for masked accesses.
26568 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
26569 and vect_load_lanes_supported.
26570 (get_load_store_type): Take a masked_p parameter and update
26571 call to get_group_load_store_type.
26572 (vectorizable_store): Update call to get_load_store_type.
26573 Handle IFN_MASK_STORE_LANES.
26574 (vectorizable_load): Update call to get_load_store_type.
26575 Handle IFN_MASK_LOAD_LANES.
26576
26577 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26578 Alan Hayward <alan.hayward@arm.com>
26579 David Sherwood <david.sherwood@arm.com>
26580
26581 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
26582 modes for SVE.
26583 * config/aarch64/aarch64-protos.h
26584 (aarch64_sve_struct_memory_operand_p): Declare.
26585 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
26586 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
26587 (VPRED, vpred): Handle SVE structure modes.
26588 * config/aarch64/constraints.md (Utx): New constraint.
26589 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
26590 (aarch64_sve_struct_nonimmediate_operand): New predicates.
26591 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
26592 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
26593 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
26594 structure modes. Split into pieces after RA.
26595 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
26596 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
26597 New patterns.
26598 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
26599 SVE structure modes.
26600 (aarch64_classify_address): Likewise.
26601 (sizetochar): Move earlier in file.
26602 (aarch64_print_operand): Handle SVE register lists.
26603 (aarch64_array_mode): New function.
26604 (aarch64_sve_struct_memory_operand_p): Likewise.
26605 (TARGET_ARRAY_MODE): Redefine.
26606
26607 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26608 Alan Hayward <alan.hayward@arm.com>
26609 David Sherwood <david.sherwood@arm.com>
26610
26611 * target.def (array_mode): New target hook.
26612 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
26613 * doc/tm.texi: Regenerate.
26614 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
26615 * hooks.c (hook_optmode_mode_uhwi_none): New function.
26616 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
26617 targetm.array_mode.
26618 * stor-layout.c (mode_for_array): Likewise. Support polynomial
26619 type sizes.
26620
26621 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26622 Alan Hayward <alan.hayward@arm.com>
26623 David Sherwood <david.sherwood@arm.com>
26624
26625 * fold-const.c (fold_binary_loc): Check the argument types
26626 rather than the result type when testing for a vector operation.
26627
26628 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26629
26630 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
26631 * doc/tm.texi: Regenerate.
26632
26633 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26634 Alan Hayward <alan.hayward@arm.com>
26635 David Sherwood <david.sherwood@arm.com>
26636
26637 * doc/invoke.texi (-msve-vector-bits=): Document new option.
26638 (sve): Document new AArch64 extension.
26639 * doc/md.texi (w): Extend the description of the AArch64
26640 constraint to include SVE vectors.
26641 (Upl, Upa): Document new AArch64 predicate constraints.
26642 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
26643 enum.
26644 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
26645 (msve-vector-bits=): New option.
26646 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
26647 SVE when these are disabled.
26648 (sve): New extension.
26649 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
26650 modes. Adjust their number of units based on aarch64_sve_vg.
26651 (MAX_BITSIZE_MODE_ANY_MODE): Define.
26652 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
26653 aarch64_addr_query_type.
26654 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
26655 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
26656 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
26657 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
26658 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
26659 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
26660 (aarch64_simd_imm_zero_p): Delete.
26661 (aarch64_check_zero_based_sve_index_immediate): Declare.
26662 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26663 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26664 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26665 (aarch64_sve_float_mul_immediate_p): Likewise.
26666 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26667 rather than an rtx.
26668 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
26669 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
26670 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
26671 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
26672 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
26673 (aarch64_regmode_natural_size): Likewise.
26674 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
26675 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
26676 left one place.
26677 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
26678 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
26679 for VG and the SVE predicate registers.
26680 (V_ALIASES): Add a "z"-prefixed alias.
26681 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
26682 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
26683 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
26684 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
26685 (REG_CLASS_NAMES): Add entries for them.
26686 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
26687 and the predicate registers.
26688 (aarch64_sve_vg): Declare.
26689 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
26690 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
26691 (REGMODE_NATURAL_SIZE): Define.
26692 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
26693 SVE macros.
26694 * config/aarch64/aarch64.c: Include cfgrtl.h.
26695 (simd_immediate_info): Add a constructor for series vectors,
26696 and an associated step field.
26697 (aarch64_sve_vg): New variable.
26698 (aarch64_dbx_register_number): Handle VG and the predicate registers.
26699 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
26700 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
26701 (VEC_ANY_DATA, VEC_STRUCT): New constants.
26702 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
26703 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
26704 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
26705 (aarch64_get_mask_mode): New functions.
26706 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
26707 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
26708 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
26709 predicate modes and predicate registers. Explicitly restrict
26710 GPRs to modes of 16 bytes or smaller. Only allow FP registers
26711 to store a vector mode if it is recognized by
26712 aarch64_classify_vector_mode.
26713 (aarch64_regmode_natural_size): New function.
26714 (aarch64_hard_regno_caller_save_mode): Return the original mode
26715 for predicates.
26716 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
26717 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
26718 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
26719 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
26720 functions.
26721 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
26722 does not overlap dest if the function is frame-related. Handle
26723 SVE constants.
26724 (aarch64_split_add_offset): New function.
26725 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
26726 them aarch64_add_offset.
26727 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
26728 and update call to aarch64_sub_sp.
26729 (aarch64_add_cfa_expression): New function.
26730 (aarch64_expand_prologue): Pass extra temporary registers to the
26731 functions above. Handle the case in which we need to emit new
26732 DW_CFA_expressions for registers that were originally saved
26733 relative to the stack pointer, but now have to be expressed
26734 relative to the frame pointer.
26735 (aarch64_output_mi_thunk): Pass extra temporary registers to the
26736 functions above.
26737 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
26738 IP0 and IP1 values for SVE frames.
26739 (aarch64_expand_vec_series): New function.
26740 (aarch64_expand_sve_widened_duplicate): Likewise.
26741 (aarch64_expand_sve_const_vector): Likewise.
26742 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
26743 Handle SVE constants. Use emit_move_insn to move a force_const_mem
26744 into the register, rather than emitting a SET directly.
26745 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
26746 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
26747 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
26748 (offset_9bit_signed_scaled_p): New functions.
26749 (aarch64_replicate_bitmask_imm): New function.
26750 (aarch64_bitmask_imm): Use it.
26751 (aarch64_cannot_force_const_mem): Reject expressions involving
26752 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
26753 (aarch64_classify_index): Handle SVE indices, by requiring
26754 a plain register index with a scale that matches the element size.
26755 (aarch64_classify_address): Handle SVE addresses. Assert that
26756 the mode of the address is VOIDmode or an integer mode.
26757 Update call to aarch64_classify_symbol.
26758 (aarch64_classify_symbolic_expression): Update call to
26759 aarch64_classify_symbol.
26760 (aarch64_const_vec_all_in_range_p): New function.
26761 (aarch64_print_vector_float_operand): Likewise.
26762 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
26763 "vN" for FP registers with SVE modes. Handle (const ...) vectors
26764 and the FP immediates 1.0 and 0.5.
26765 (aarch64_print_address_internal): Handle SVE addresses.
26766 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
26767 (aarch64_regno_regclass): Handle predicate registers.
26768 (aarch64_secondary_reload): Handle big-endian reloads of SVE
26769 data modes.
26770 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
26771 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
26772 (aarch64_convert_sve_vector_bits): New function.
26773 (aarch64_override_options): Use it to handle -msve-vector-bits=.
26774 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26775 rather than an rtx.
26776 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
26777 Handle SVE vector and predicate modes. Accept VL-based constants
26778 that need only one temporary register, and VL offsets that require
26779 no temporary registers.
26780 (aarch64_conditional_register_usage): Mark the predicate registers
26781 as fixed if SVE isn't available.
26782 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
26783 Return true for SVE vector and predicate modes.
26784 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
26785 rather than an unsigned int. Handle SVE modes.
26786 (aarch64_preferred_simd_mode): Update call accordingly. Handle
26787 SVE modes.
26788 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
26789 if SVE is enabled.
26790 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26791 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26792 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26793 (aarch64_sve_float_mul_immediate_p): New functions.
26794 (aarch64_sve_valid_immediate): New function.
26795 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
26796 Explicitly reject structure modes. Check for INDEX constants.
26797 Handle PTRUE and PFALSE constants.
26798 (aarch64_check_zero_based_sve_index_immediate): New function.
26799 (aarch64_simd_imm_zero_p): Delete.
26800 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
26801 vector modes. Accept constants in the range of CNT[BHWD].
26802 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
26803 ask for an Advanced SIMD mode.
26804 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
26805 (aarch64_simd_vector_alignment): Handle SVE predicates.
26806 (aarch64_vectorize_preferred_vector_alignment): New function.
26807 (aarch64_simd_vector_alignment_reachable): Use it instead of
26808 the vector size.
26809 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
26810 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
26811 functions.
26812 (MAX_VECT_LEN): Delete.
26813 (expand_vec_perm_d): Add a vec_flags field.
26814 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
26815 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
26816 (aarch64_evpc_ext): Don't apply a big-endian lane correction
26817 for SVE modes.
26818 (aarch64_evpc_rev): Rename to...
26819 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
26820 (aarch64_evpc_rev_global): New function.
26821 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
26822 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
26823 MAX_VECT_LEN.
26824 (aarch64_evpc_sve_tbl): New function.
26825 (aarch64_expand_vec_perm_const_1): Update after rename of
26826 aarch64_evpc_rev. Handle SVE permutes too, trying
26827 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
26828 than aarch64_evpc_tbl.
26829 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
26830 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
26831 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
26832 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
26833 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
26834 (aarch64_expand_sve_vcond): New functions.
26835 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
26836 of aarch64_vector_mode_p.
26837 (aarch64_dwarf_poly_indeterminate_value): New function.
26838 (aarch64_compute_pressure_classes): Likewise.
26839 (aarch64_can_change_mode_class): Likewise.
26840 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
26841 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
26842 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
26843 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
26844 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
26845 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
26846 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
26847 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
26848 constraints.
26849 (Dn, Dl, Dr): Accept const as well as const_vector.
26850 (Dz): Likewise. Compare against CONST0_RTX.
26851 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
26852 of "vector" where appropriate.
26853 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
26854 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
26855 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
26856 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
26857 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
26858 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
26859 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
26860 (v_int_equiv): Extend to SVE modes.
26861 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
26862 mode attributes.
26863 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
26864 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
26865 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
26866 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
26867 (SVE_COND_FP_CMP): New int iterators.
26868 (perm_hilo): Handle the new unpack unspecs.
26869 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
26870 attributes.
26871 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
26872 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
26873 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
26874 (aarch64_equality_operator, aarch64_constant_vector_operand)
26875 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
26876 (aarch64_sve_nonimmediate_operand): Likewise.
26877 (aarch64_sve_general_operand): Likewise.
26878 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
26879 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
26880 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
26881 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
26882 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
26883 (aarch64_sve_float_arith_immediate): Likewise.
26884 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
26885 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
26886 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
26887 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
26888 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
26889 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
26890 (aarch64_sve_float_arith_operand): Likewise.
26891 (aarch64_sve_float_arith_with_sub_operand): Likewise.
26892 (aarch64_sve_float_mul_operand): Likewise.
26893 (aarch64_sve_vec_perm_operand): Likewise.
26894 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
26895 (aarch64_mov_operand): Accept const_poly_int and const_vector.
26896 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
26897 as well as const_vector.
26898 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
26899 in file. Use CONST0_RTX and CONSTM1_RTX.
26900 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
26901 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
26902 Use aarch64_simd_imm_zero.
26903 * config/aarch64/aarch64-sve.md: New file.
26904 * config/aarch64/aarch64.md: Include it.
26905 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
26906 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
26907 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
26908 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
26909 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
26910 (sve): New attribute.
26911 (enabled): Disable instructions with the sve attribute unless
26912 TARGET_SVE.
26913 (movqi, movhi): Pass CONST_POLY_INT operaneds through
26914 aarch64_expand_mov_immediate.
26915 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
26916 CNT[BHSD] immediates.
26917 (movti): Split CONST_POLY_INT moves into two halves.
26918 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
26919 Split additions that need a temporary here if the destination
26920 is the stack pointer.
26921 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
26922 (*add<mode>3_poly_1): New instruction.
26923 (set_clobber_cc): New expander.
26924
26925 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26926
26927 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
26928 parameter and use it instead of GET_MODE_SIZE (innermode). Use
26929 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
26930 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
26931 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
26932 Change innermode from fixed_mode_size to machine_mode.
26933 (simplify_subreg): Update call accordingly. Handle a constant-sized
26934 subreg of a variable-length CONST_VECTOR.
26935
26936 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26937 Alan Hayward <alan.hayward@arm.com>
26938 David Sherwood <david.sherwood@arm.com>
26939
26940 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
26941 (add_offset_to_base): New function, split out from...
26942 (create_mem_ref): ...here. When handling a scale other than 1,
26943 check first whether the address is valid without the offset.
26944 Add it into the base if so, leaving the index and scale as-is.
26945
26946 2018-01-12 Jakub Jelinek <jakub@redhat.com>
26947
26948 PR c++/83778
26949 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
26950 fold_for_warn before checking if arg2 is INTEGER_CST.
26951
26952 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
26953
26954 * config/rs6000/predicates.md (load_multiple_operation): Delete.
26955 (store_multiple_operation): Delete.
26956 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
26957 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
26958 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
26959 guarded by TARGET_STRING.
26960 (rs6000_output_load_multiple): Delete.
26961 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
26962 OPTION_MASK_STRING / TARGET_STRING handling.
26963 (print_operand) <'N', 'O'>: Add comment that these are unused now.
26964 (const rs6000_opt_masks) <"string">: Change mask to 0.
26965 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
26966 (MASK_STRING): Delete.
26967 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
26968 parts. Simplify.
26969 (load_multiple): Delete.
26970 (*ldmsi8): Delete.
26971 (*ldmsi7): Delete.
26972 (*ldmsi6): Delete.
26973 (*ldmsi5): Delete.
26974 (*ldmsi4): Delete.
26975 (*ldmsi3): Delete.
26976 (store_multiple): Delete.
26977 (*stmsi8): Delete.
26978 (*stmsi7): Delete.
26979 (*stmsi6): Delete.
26980 (*stmsi5): Delete.
26981 (*stmsi4): Delete.
26982 (*stmsi3): Delete.
26983 (movmemsi_8reg): Delete.
26984 (corresponding unnamed define_insn): Delete.
26985 (movmemsi_6reg): Delete.
26986 (corresponding unnamed define_insn): Delete.
26987 (movmemsi_4reg): Delete.
26988 (corresponding unnamed define_insn): Delete.
26989 (movmemsi_2reg): Delete.
26990 (corresponding unnamed define_insn): Delete.
26991 (movmemsi_1reg): Delete.
26992 (corresponding unnamed define_insn): Delete.
26993 * config/rs6000/rs6000.opt (mno-string): New.
26994 (mstring): Replace by deprecation warning stub.
26995 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
26996
26997 2018-01-12 Jakub Jelinek <jakub@redhat.com>
26998
26999 * regrename.c (regrename_do_replace): If replacing the same
27000 reg multiple times, try to reuse last created gen_raw_REG.
27001
27002 PR debug/81155
27003 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
27004 main to workaround a bug in GDB.
27005
27006 2018-01-12 Tom de Vries <tom@codesourcery.com>
27007
27008 PR target/83737
27009 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
27010
27011 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
27012
27013 PR rtl-optimization/80481
27014 * ira-color.c (get_cap_member): New function.
27015 (allocnos_conflict_by_live_ranges_p): Use it.
27016 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
27017 (setup_slot_coalesced_allocno_live_ranges): Ditto.
27018
27019 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
27020
27021 PR target/83628
27022 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
27023 (*saddl_se_1): Ditto.
27024 (*ssubsi_1): Ditto.
27025 (*ssubl_se_1): Ditto.
27026
27027 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27028
27029 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
27030 rather than wi::to_widest for DR_INITs.
27031 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
27032 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
27033 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
27034 INTEGER_CSTs.
27035 (vect_analyze_group_access_1): Note that here.
27036
27037 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27038
27039 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
27040 polynomial type sizes.
27041
27042 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27043
27044 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
27045 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
27046 (gimple_add_tmp_var): Likewise.
27047
27048 2018-01-12 Martin Liska <mliska@suse.cz>
27049
27050 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
27051 (gimple_alloc_sizes): Likewise.
27052 (dump_gimple_statistics): Use PRIu64 in printf format.
27053 * gimple.h: Change uint64_t to int.
27054
27055 2018-01-12 Martin Liska <mliska@suse.cz>
27056
27057 * tree-core.h: Use uint64_t instead of int.
27058 * tree.c (tree_node_counts): Likewise.
27059 (tree_node_sizes): Likewise.
27060 (dump_tree_statistics): Use PRIu64 in printf format.
27061
27062 2018-01-12 Martin Liska <mliska@suse.cz>
27063
27064 * Makefile.in: As qsort_chk is implemented in vec.c, add
27065 vec.o to linkage of gencfn-macros.
27066 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
27067 passing the info to record_node_allocation_statistics.
27068 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
27069 and pass the info.
27070 * ggc-common.c (struct ggc_usage): Add operator== and use
27071 it in operator< and compare function.
27072 * mem-stats.h (struct mem_usage): Likewise.
27073 * vec.c (struct vec_usage): Remove operator< and compare
27074 function. Can be simply inherited.
27075
27076 2018-01-12 Martin Jambor <mjambor@suse.cz>
27077
27078 PR target/81616
27079 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
27080 * tree-ssa-math-opts.c: Include domwalk.h.
27081 (convert_mult_to_fma_1): New function.
27082 (fma_transformation_info): New type.
27083 (fma_deferring_state): Likewise.
27084 (cancel_fma_deferring): New function.
27085 (result_of_phi): Likewise.
27086 (last_fma_candidate_feeds_initial_phi): Likewise.
27087 (convert_mult_to_fma): Added deferring logic, split actual
27088 transformation to convert_mult_to_fma_1.
27089 (math_opts_dom_walker): New type.
27090 (math_opts_dom_walker::after_dom_children): New method, body moved
27091 here from pass_optimize_widening_mul::execute, added deferring logic
27092 bits.
27093 (pass_optimize_widening_mul::execute): Moved most of code to
27094 math_opts_dom_walker::after_dom_children.
27095 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
27096 * config/i386/i386.c (ix86_option_override_internal): Added
27097 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
27098
27099 2018-01-12 Richard Biener <rguenther@suse.de>
27100
27101 PR debug/83157
27102 * dwarf2out.c (gen_variable_die): Do not reset old_die for
27103 inline instance vars.
27104
27105 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
27106
27107 PR target/81819
27108 * config/rx/rx.c (rx_is_restricted_memory_address):
27109 Handle SUBREG case.
27110
27111 2018-01-12 Richard Biener <rguenther@suse.de>
27112
27113 PR tree-optimization/80846
27114 * target.def (split_reduction): New target hook.
27115 * targhooks.c (default_split_reduction): New function.
27116 * targhooks.h (default_split_reduction): Declare.
27117 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
27118 target requests first reduce vectors by combining low and high
27119 parts.
27120 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
27121 (get_vectype_for_scalar_type_and_size): Export.
27122 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
27123 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
27124 * doc/tm.texi: Regenerate.
27125 * config/i386/i386.c (ix86_split_reduction): Implement
27126 TARGET_VECTORIZE_SPLIT_REDUCTION.
27127
27128 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27129
27130 PR target/83368
27131 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
27132 in PIC mode except for TARGET_VXWORKS_RTP.
27133 * config/sparc/sparc.c: Include cfgrtl.h.
27134 (TARGET_INIT_PIC_REG): Define.
27135 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
27136 (sparc_pic_register_p): New predicate.
27137 (sparc_legitimate_address_p): Use it.
27138 (sparc_legitimize_pic_address): Likewise.
27139 (sparc_delegitimize_address): Likewise.
27140 (sparc_mode_dependent_address_p): Likewise.
27141 (gen_load_pcrel_sym): Remove 4th parameter.
27142 (load_got_register): Adjust call to above. Remove obsolete stuff.
27143 (sparc_expand_prologue): Do not call load_got_register here.
27144 (sparc_flat_expand_prologue): Likewise.
27145 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
27146 (sparc_use_pseudo_pic_reg): New function.
27147 (sparc_init_pic_reg): Likewise.
27148 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
27149 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
27150
27151 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
27152
27153 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
27154 Add item for branch_cost.
27155
27156 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27157
27158 PR rtl-optimization/83565
27159 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
27160 not extend the result to a larger mode for rotate operations.
27161 (num_sign_bit_copies1): Likewise.
27162
27163 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
27164
27165 PR target/40411
27166 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
27167 -symbolic.
27168 Use values-Xc.o for -pedantic.
27169 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
27170
27171 2018-01-12 Martin Liska <mliska@suse.cz>
27172
27173 PR ipa/83054
27174 * ipa-devirt.c (final_warning_record::grow_type_warnings):
27175 New function.
27176 (possible_polymorphic_call_targets): Use it.
27177 (ipa_devirt): Likewise.
27178
27179 2018-01-12 Martin Liska <mliska@suse.cz>
27180
27181 * profile-count.h (enum profile_quality): Use 0 as invalid
27182 enum value of profile_quality.
27183
27184 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
27185
27186 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
27187 -mext-string options.
27188
27189 2018-01-12 Richard Biener <rguenther@suse.de>
27190
27191 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
27192 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
27193 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
27194 Likewise.
27195 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
27196
27197 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
27198
27199 * configure.ac (--with-long-double-format): Add support for the
27200 configuration option to change the default long double format on
27201 PowerPC systems.
27202 * config.gcc (powerpc*-linux*-*): Likewise.
27203 * configure: Regenerate.
27204 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
27205 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
27206 used without modification.
27207
27208 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27209
27210 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
27211 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
27212 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
27213 MISC_BUILTIN_SPEC_BARRIER.
27214 (rs6000_init_builtins): Likewise.
27215 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
27216 enum value.
27217 (speculation_barrier): New define_insn.
27218 * doc/extend.texi: Document __builtin_speculation_barrier.
27219
27220 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27221
27222 PR target/83203
27223 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
27224 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
27225 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
27226 iterators.
27227 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
27228 integral modes instead of "ss" and "sd".
27229 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
27230 vectors with 32-bit and 64-bit elements.
27231 (vecdupssescalarmodesuffix): New mode attribute.
27232 (vec_dup<mode>): Use it.
27233
27234 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
27235
27236 PR target/83330
27237 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
27238 frame if argument is passed on stack.
27239
27240 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27241
27242 PR target/82682
27243 * ree.c (combine_reaching_defs): Optimize also
27244 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
27245 reg2=any_extend(exp); reg1=reg2;, formatting fix.
27246
27247 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27248
27249 PR middle-end/83189
27250 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
27251
27252 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27253
27254 PR middle-end/83718
27255 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
27256 after they are computed.
27257
27258 2018-01-11 Bin Cheng <bin.cheng@arm.com>
27259
27260 PR tree-optimization/83695
27261 * gimple-loop-linterchange.cc
27262 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
27263 reset cached scev information after interchange.
27264 (pass_linterchange::execute): Remove call to scev_reset_htab.
27265
27266 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27267
27268 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
27269 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
27270 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
27271 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
27272 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
27273 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
27274 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
27275 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
27276 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
27277 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
27278 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
27279 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
27280 (V_lane_reg): Likewise.
27281 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
27282 New define_expand.
27283 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
27284 (vfmal_lane_low<mode>_intrinsic,
27285 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
27286 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
27287 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
27288 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
27289 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
27290 vfmsl_lane_high<mode>_intrinsic): New define_insns.
27291
27292 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27293
27294 * config/arm/arm-cpus.in (fp16fml): New feature.
27295 (ALL_SIMD): Add fp16fml.
27296 (armv8.2-a): Add fp16fml as an option.
27297 (armv8.3-a): Likewise.
27298 (armv8.4-a): Add fp16fml as part of fp16.
27299 * config/arm/arm.h (TARGET_FP16FML): Define.
27300 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
27301 when appropriate.
27302 * config/arm/arm-modes.def (V2HF): Define.
27303 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
27304 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
27305 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
27306 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
27307 vfmsl_low, vfmsl_high): New set of builtins.
27308 * config/arm/iterators.md (PLUSMINUS): New code iterator.
27309 (vfml_op): New code attribute.
27310 (VFMLHALVES): New int iterator.
27311 (VFML, VFMLSEL): New mode attributes.
27312 (V_reg): Define mapping for V2HF.
27313 (V_hi, V_lo): New mode attributes.
27314 (VF_constraint): Likewise.
27315 (vfml_half, vfml_half_selector): New int attributes.
27316 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
27317 define_expand.
27318 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
27319 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
27320 New define_insn.
27321 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
27322 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
27323 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
27324 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
27325 documentation.
27326 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
27327 Document new effective target and option set.
27328
27329 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27330
27331 * config/arm/arm-cpus.in (armv8_4): New feature.
27332 (ARMv8_4a): New fgroup.
27333 (armv8.4-a): New arch.
27334 * config/arm/arm-tables.opt: Regenerate.
27335 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
27336 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
27337 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
27338 Add matching rules for -march=armv8.4-a and extensions.
27339 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
27340
27341 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
27342
27343 PR target/81821
27344 * config/rx/rx.md (BW): New mode attribute.
27345 (sync_lock_test_and_setsi): Add mode suffix to insn output.
27346
27347 2018-01-11 Richard Biener <rguenther@suse.de>
27348
27349 PR tree-optimization/83435
27350 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
27351 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
27352 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
27353
27354 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27355 Alan Hayward <alan.hayward@arm.com>
27356 David Sherwood <david.sherwood@arm.com>
27357
27358 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
27359 field.
27360 (aarch64_classify_address): Initialize it. Track polynomial offsets.
27361 (aarch64_print_address_internal): Use it to check for a zero offset.
27362
27363 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27364 Alan Hayward <alan.hayward@arm.com>
27365 David Sherwood <david.sherwood@arm.com>
27366
27367 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
27368 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
27369 Return a poly_int64 rather than a HOST_WIDE_INT.
27370 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
27371 rather than a HOST_WIDE_INT.
27372 * config/aarch64/aarch64.h (aarch64_frame): Protect with
27373 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
27374 hard_fp_offset, frame_size, initial_adjust, callee_offset and
27375 final_offset from HOST_WIDE_INT to poly_int64.
27376 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
27377 to_constant when getting the number of units in an Advanced SIMD
27378 mode.
27379 (aarch64_builtin_vectorized_function): Check for a constant number
27380 of units.
27381 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
27382 GET_MODE_SIZE.
27383 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
27384 attribute instead of GET_MODE_NUNITS.
27385 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
27386 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
27387 GET_MODE_SIZE for fixed-size registers.
27388 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
27389 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
27390 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
27391 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
27392 (aarch64_print_operand, aarch64_print_address_internal)
27393 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
27394 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
27395 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
27396 Handle polynomial GET_MODE_SIZE.
27397 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
27398 wider than SImode without modification.
27399 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
27400 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
27401 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
27402 passing and returning SVE modes.
27403 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
27404 rather than GEN_INT.
27405 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
27406 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
27407 (aarch64_allocate_and_probe_stack_space): Likewise.
27408 (aarch64_layout_frame): Cope with polynomial offsets.
27409 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
27410 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
27411 polynomial offsets.
27412 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
27413 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
27414 poly_int64 rather than a HOST_WIDE_INT.
27415 (aarch64_get_separate_components, aarch64_process_components)
27416 (aarch64_expand_prologue, aarch64_expand_epilogue)
27417 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
27418 (aarch64_anchor_offset): New function, split out from...
27419 (aarch64_legitimize_address): ...here.
27420 (aarch64_builtin_vectorization_cost): Handle polynomial
27421 TYPE_VECTOR_SUBPARTS.
27422 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
27423 GET_MODE_NUNITS.
27424 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
27425 number of elements from the PARALLEL rather than the mode.
27426 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
27427 rather than GET_MODE_BITSIZE.
27428 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
27429 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
27430 (aarch64_expand_vec_perm_const_1): Handle polynomial
27431 d->perm.length () and d->perm elements.
27432 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
27433 Apply to_constant to d->perm elements.
27434 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
27435 polynomial CONST_VECTOR_NUNITS.
27436 (aarch64_move_pointer): Take amount as a poly_int64 rather
27437 than an int.
27438 (aarch64_progress_pointer): Avoid temporary variable.
27439 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
27440 the mode attribute instead of GET_MODE.
27441
27442 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27443 Alan Hayward <alan.hayward@arm.com>
27444 David Sherwood <david.sherwood@arm.com>
27445
27446 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
27447 x exists before using it.
27448 (aarch64_add_constant_internal): Rename to...
27449 (aarch64_add_offset_1): ...this. Replace regnum with separate
27450 src and dest rtxes. Handle the case in which they're different,
27451 including when the offset is zero. Replace scratchreg with an rtx.
27452 Use 2 additions if there is no spare register into which we can
27453 move a 16-bit constant.
27454 (aarch64_add_constant): Delete.
27455 (aarch64_add_offset): Replace reg with separate src and dest
27456 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
27457 Use aarch64_add_offset_1.
27458 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
27459 an rtx rather than an int. Take the delta as a poly_int64
27460 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
27461 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
27462 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
27463 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
27464 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
27465 and aarch64_add_sp.
27466 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
27467 aarch64_add_constant.
27468
27469 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27470
27471 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
27472 Use scalar_float_mode.
27473
27474 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27475
27476 * config/aarch64/aarch64-simd.md
27477 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
27478 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
27479 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
27480 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
27481 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
27482 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
27483 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
27484 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
27485 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
27486 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
27487
27488 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27489
27490 PR target/83514
27491 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
27492 targ_options->x_arm_arch_string is non NULL.
27493
27494 2018-01-11 Tamar Christina <tamar.christina@arm.com>
27495
27496 * config/aarch64/aarch64.h
27497 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
27498
27499 2018-01-11 Sudakshina Das <sudi.das@arm.com>
27500
27501 PR target/82096
27502 * expmed.c (emit_store_flag_force): Swap if const op0
27503 and change VOIDmode to mode of op0.
27504
27505 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27506
27507 PR rtl-optimization/83761
27508 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
27509 than bytes to mode_for_size.
27510
27511 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27512
27513 PR middle-end/83189
27514 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
27515 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
27516 profile.
27517
27518 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27519
27520 PR middle-end/83575
27521 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
27522 when in layout mode.
27523 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
27524 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
27525 partition fixup.
27526
27527 2018-01-10 Michael Collison <michael.collison@arm.com>
27528
27529 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
27530 * config/aarch64/aarch64-option-extension.def: Add
27531 AARCH64_OPT_EXTENSION of 'fp16fml'.
27532 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27533 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
27534 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
27535 * config/aarch64/constraints.md (Ui7): New constraint.
27536 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
27537 (VFMLA_SEL_W): Ditto.
27538 (f16quad): Ditto.
27539 (f16mac1): Ditto.
27540 (VFMLA16_LOW): New int iterator.
27541 (VFMLA16_HIGH): Ditto.
27542 (UNSPEC_FMLAL): New unspec.
27543 (UNSPEC_FMLSL): Ditto.
27544 (UNSPEC_FMLAL2): Ditto.
27545 (UNSPEC_FMLSL2): Ditto.
27546 (f16mac): New code attribute.
27547 * config/aarch64/aarch64-simd-builtins.def
27548 (aarch64_fmlal_lowv2sf): Ditto.
27549 (aarch64_fmlsl_lowv2sf): Ditto.
27550 (aarch64_fmlalq_lowv4sf): Ditto.
27551 (aarch64_fmlslq_lowv4sf): Ditto.
27552 (aarch64_fmlal_highv2sf): Ditto.
27553 (aarch64_fmlsl_highv2sf): Ditto.
27554 (aarch64_fmlalq_highv4sf): Ditto.
27555 (aarch64_fmlslq_highv4sf): Ditto.
27556 (aarch64_fmlal_lane_lowv2sf): Ditto.
27557 (aarch64_fmlsl_lane_lowv2sf): Ditto.
27558 (aarch64_fmlal_laneq_lowv2sf): Ditto.
27559 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
27560 (aarch64_fmlalq_lane_lowv4sf): Ditto.
27561 (aarch64_fmlsl_lane_lowv4sf): Ditto.
27562 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
27563 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
27564 (aarch64_fmlal_lane_highv2sf): Ditto.
27565 (aarch64_fmlsl_lane_highv2sf): Ditto.
27566 (aarch64_fmlal_laneq_highv2sf): Ditto.
27567 (aarch64_fmlsl_laneq_highv2sf): Ditto.
27568 (aarch64_fmlalq_lane_highv4sf): Ditto.
27569 (aarch64_fmlsl_lane_highv4sf): Ditto.
27570 (aarch64_fmlalq_laneq_highv4sf): Ditto.
27571 (aarch64_fmlsl_laneq_highv4sf): Ditto.
27572 * config/aarch64/aarch64-simd.md:
27573 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
27574 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27575 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
27576 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27577 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
27578 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
27579 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
27580 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
27581 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
27582 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
27583 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
27584 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
27585 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
27586 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
27587 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
27588 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
27589 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
27590 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
27591 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
27592 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
27593 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
27594 (vfmlsl_low_u32): Ditto.
27595 (vfmlalq_low_u32): Ditto.
27596 (vfmlslq_low_u32): Ditto.
27597 (vfmlal_high_u32): Ditto.
27598 (vfmlsl_high_u32): Ditto.
27599 (vfmlalq_high_u32): Ditto.
27600 (vfmlslq_high_u32): Ditto.
27601 (vfmlal_lane_low_u32): Ditto.
27602 (vfmlsl_lane_low_u32): Ditto.
27603 (vfmlal_laneq_low_u32): Ditto.
27604 (vfmlsl_laneq_low_u32): Ditto.
27605 (vfmlalq_lane_low_u32): Ditto.
27606 (vfmlslq_lane_low_u32): Ditto.
27607 (vfmlalq_laneq_low_u32): Ditto.
27608 (vfmlslq_laneq_low_u32): Ditto.
27609 (vfmlal_lane_high_u32): Ditto.
27610 (vfmlsl_lane_high_u32): Ditto.
27611 (vfmlal_laneq_high_u32): Ditto.
27612 (vfmlsl_laneq_high_u32): Ditto.
27613 (vfmlalq_lane_high_u32): Ditto.
27614 (vfmlslq_lane_high_u32): Ditto.
27615 (vfmlalq_laneq_high_u32): Ditto.
27616 (vfmlslq_laneq_high_u32): Ditto.
27617 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
27618 (AARCH64_FL_FOR_ARCH8_4): New.
27619 (AARCH64_ISA_F16FML): New ISA flag.
27620 (TARGET_F16FML): New feature flag for fp16fml.
27621 (doc/invoke.texi): Document new fp16fml option.
27622
27623 2018-01-10 Michael Collison <michael.collison@arm.com>
27624
27625 * config/aarch64/aarch64-builtins.c:
27626 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
27627 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27628 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
27629 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
27630 (AARCH64_ISA_SHA3): New ISA flag.
27631 (TARGET_SHA3): New feature flag for sha3.
27632 * config/aarch64/iterators.md (sha512_op): New int attribute.
27633 (CRYPTO_SHA512): New int iterator.
27634 (UNSPEC_SHA512H): New unspec.
27635 (UNSPEC_SHA512H2): Ditto.
27636 (UNSPEC_SHA512SU0): Ditto.
27637 (UNSPEC_SHA512SU1): Ditto.
27638 * config/aarch64/aarch64-simd-builtins.def
27639 (aarch64_crypto_sha512hqv2di): New builtin.
27640 (aarch64_crypto_sha512h2qv2di): Ditto.
27641 (aarch64_crypto_sha512su0qv2di): Ditto.
27642 (aarch64_crypto_sha512su1qv2di): Ditto.
27643 (aarch64_eor3qv8hi): Ditto.
27644 (aarch64_rax1qv2di): Ditto.
27645 (aarch64_xarqv2di): Ditto.
27646 (aarch64_bcaxqv8hi): Ditto.
27647 * config/aarch64/aarch64-simd.md:
27648 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
27649 (aarch64_crypto_sha512su0qv2di): Ditto.
27650 (aarch64_crypto_sha512su1qv2di): Ditto.
27651 (aarch64_eor3qv8hi): Ditto.
27652 (aarch64_rax1qv2di): Ditto.
27653 (aarch64_xarqv2di): Ditto.
27654 (aarch64_bcaxqv8hi): Ditto.
27655 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
27656 (vsha512h2q_u64): Ditto.
27657 (vsha512su0q_u64): Ditto.
27658 (vsha512su1q_u64): Ditto.
27659 (veor3q_u16): Ditto.
27660 (vrax1q_u64): Ditto.
27661 (vxarq_u64): Ditto.
27662 (vbcaxq_u16): Ditto.
27663 * config/arm/types.md (crypto_sha512): New type attribute.
27664 (crypto_sha3): Ditto.
27665 (doc/invoke.texi): Document new sha3 option.
27666
27667 2018-01-10 Michael Collison <michael.collison@arm.com>
27668
27669 * config/aarch64/aarch64-builtins.c:
27670 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
27671 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27672 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
27673 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
27674 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
27675 (AARCH64_ISA_SM4): New ISA flag.
27676 (TARGET_SM4): New feature flag for sm4.
27677 * config/aarch64/aarch64-simd-builtins.def
27678 (aarch64_sm3ss1qv4si): Ditto.
27679 (aarch64_sm3tt1aq4si): Ditto.
27680 (aarch64_sm3tt1bq4si): Ditto.
27681 (aarch64_sm3tt2aq4si): Ditto.
27682 (aarch64_sm3tt2bq4si): Ditto.
27683 (aarch64_sm3partw1qv4si): Ditto.
27684 (aarch64_sm3partw2qv4si): Ditto.
27685 (aarch64_sm4eqv4si): Ditto.
27686 (aarch64_sm4ekeyqv4si): Ditto.
27687 * config/aarch64/aarch64-simd.md:
27688 (aarch64_sm3ss1qv4si): Ditto.
27689 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
27690 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
27691 (aarch64_sm4eqv4si): Ditto.
27692 (aarch64_sm4ekeyqv4si): Ditto.
27693 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
27694 (sm3part_op): Ditto.
27695 (CRYPTO_SM3TT): Ditto.
27696 (CRYPTO_SM3PART): Ditto.
27697 (UNSPEC_SM3SS1): New unspec.
27698 (UNSPEC_SM3TT1A): Ditto.
27699 (UNSPEC_SM3TT1B): Ditto.
27700 (UNSPEC_SM3TT2A): Ditto.
27701 (UNSPEC_SM3TT2B): Ditto.
27702 (UNSPEC_SM3PARTW1): Ditto.
27703 (UNSPEC_SM3PARTW2): Ditto.
27704 (UNSPEC_SM4E): Ditto.
27705 (UNSPEC_SM4EKEY): Ditto.
27706 * config/aarch64/constraints.md (Ui2): New constraint.
27707 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
27708 * config/arm/types.md (crypto_sm3): New type attribute.
27709 (crypto_sm4): Ditto.
27710 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
27711 (vsm3tt1aq_u32): Ditto.
27712 (vsm3tt1bq_u32): Ditto.
27713 (vsm3tt2aq_u32): Ditto.
27714 (vsm3tt2bq_u32): Ditto.
27715 (vsm3partw1q_u32): Ditto.
27716 (vsm3partw2q_u32): Ditto.
27717 (vsm4eq_u32): Ditto.
27718 (vsm4ekeyq_u32): Ditto.
27719 (doc/invoke.texi): Document new sm4 option.
27720
27721 2018-01-10 Michael Collison <michael.collison@arm.com>
27722
27723 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
27724 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
27725 (AARCH64_FL_FOR_ARCH8_4): New.
27726 (AARCH64_FL_V8_4): New flag.
27727 (doc/invoke.texi): Document new armv8.4-a option.
27728
27729 2018-01-10 Michael Collison <michael.collison@arm.com>
27730
27731 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27732 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
27733 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
27734 * config/aarch64/aarch64-option-extension.def: Add
27735 AARCH64_OPT_EXTENSION of 'sha2'.
27736 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
27737 (crypto): Disable sha2 and aes if crypto disabled.
27738 (crypto): Enable aes and sha2 if enabled.
27739 (simd): Disable sha2 and aes if simd disabled.
27740 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
27741 New flags.
27742 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
27743 (TARGET_SHA2): New feature flag for sha2.
27744 (TARGET_AES): New feature flag for aes.
27745 * config/aarch64/aarch64-simd.md:
27746 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
27747 conditional on TARGET_AES.
27748 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
27749 (aarch64_crypto_sha1hsi): Make pattern conditional
27750 on TARGET_SHA2.
27751 (aarch64_crypto_sha1hv4si): Ditto.
27752 (aarch64_be_crypto_sha1hv4si): Ditto.
27753 (aarch64_crypto_sha1su1v4si): Ditto.
27754 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
27755 (aarch64_crypto_sha1su0v4si): Ditto.
27756 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
27757 (aarch64_crypto_sha256su0v4si): Ditto.
27758 (aarch64_crypto_sha256su1v4si): Ditto.
27759 (doc/invoke.texi): Document new aes and sha2 options.
27760
27761 2018-01-10 Martin Sebor <msebor@redhat.com>
27762
27763 PR tree-optimization/83781
27764 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
27765 as string arrays.
27766
27767 2018-01-11 Martin Sebor <msebor@gmail.com>
27768 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27769
27770 PR tree-optimization/83501
27771 PR tree-optimization/81703
27772
27773 * tree-ssa-strlen.c (get_string_cst): Rename...
27774 (get_string_len): ...to this. Handle global constants.
27775 (handle_char_store): Adjust.
27776
27777 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
27778 Jim Wilson <jimw@sifive.com>
27779
27780 * config/riscv/riscv-protos.h (riscv_output_return): New.
27781 * config/riscv/riscv.c (struct machine_function): New naked_p field.
27782 (riscv_attribute_table, riscv_output_return),
27783 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
27784 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
27785 (riscv_compute_frame_info): Only compute frame->mask if not a naked
27786 function.
27787 (riscv_expand_prologue): Add early return for naked function.
27788 (riscv_expand_epilogue): Likewise.
27789 (riscv_function_ok_for_sibcall): Return false for naked function.
27790 (riscv_set_current_function): New.
27791 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
27792 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
27793 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
27794 * doc/extend.texi (RISC-V Function Attributes): New.
27795
27796 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
27797
27798 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
27799 check for 128-bit long double before checking TCmode.
27800 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
27801 128-bit long doubles before checking TFmode or TCmode.
27802 (FLOAT128_IBM_P): Likewise.
27803
27804 2018-01-10 Martin Sebor <msebor@redhat.com>
27805
27806 PR tree-optimization/83671
27807 * builtins.c (c_strlen): Unconditionally return zero for the empty
27808 string.
27809 Use -Warray-bounds for warnings.
27810 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
27811 for non-constant array indices with COMPONENT_REF, arrays of
27812 arrays, and pointers to arrays.
27813 (gimple_fold_builtin_strlen): Determine and set length range for
27814 non-constant character arrays.
27815
27816 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
27817
27818 PR middle-end/81897
27819 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
27820 empty blocks.
27821
27822 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
27823
27824 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
27825
27826 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27827
27828 PR target/83399
27829 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
27830 VECTOR_MEM_ALTIVEC_OR_VSX_P.
27831 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
27832 indexed_or_indirect_operand predicate.
27833 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
27834 (*vsx_le_perm_load_v8hi): Likewise.
27835 (*vsx_le_perm_load_v16qi): Likewise.
27836 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
27837 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
27838 (*vsx_le_perm_store_v8hi): Likewise.
27839 (*vsx_le_perm_store_v16qi): Likewise.
27840 (eight unnamed splitters): Likewise.
27841
27842 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27843
27844 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
27845 * config/rs6000/emmintrin.h: Likewise.
27846 * config/rs6000/mmintrin.h: Likewise.
27847 * config/rs6000/xmmintrin.h: Likewise.
27848
27849 2018-01-10 David Malcolm <dmalcolm@redhat.com>
27850
27851 PR c++/43486
27852 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
27853 "public_flag".
27854 * tree.c (tree_nop_conversion): Return true for location wrapper
27855 nodes.
27856 (maybe_wrap_with_location): New function.
27857 (selftest::check_strip_nops): New function.
27858 (selftest::test_location_wrappers): New function.
27859 (selftest::tree_c_tests): Call it.
27860 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
27861 (maybe_wrap_with_location): New decl.
27862 (EXPR_LOCATION_WRAPPER_P): New macro.
27863 (location_wrapper_p): New inline function.
27864 (tree_strip_any_location_wrapper): New inline function.
27865
27866 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
27867
27868 PR target/83735
27869 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
27870 stack_realign_offset for the largest alignment of stack slot
27871 actually used.
27872 (ix86_find_max_used_stack_alignment): New function.
27873 (ix86_finalize_stack_frame_flags): Use it. Set
27874 max_used_stack_alignment if we don't realign stack.
27875 * config/i386/i386.h (machine_function): Add
27876 max_used_stack_alignment.
27877
27878 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
27879
27880 * config/arm/arm.opt (-mbranch-cost): New option.
27881 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
27882 account.
27883
27884 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
27885
27886 PR target/83629
27887 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
27888 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
27889
27890 2018-01-10 Richard Biener <rguenther@suse.de>
27891
27892 PR debug/83765
27893 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
27894 early out so it also covers the case where we have a non-NULL
27895 origin.
27896
27897 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
27898
27899 PR tree-optimization/83753
27900 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
27901 for non-strided grouped accesses if the number of elements is 1.
27902
27903 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27904
27905 PR target/81616
27906 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
27907 * i386.h (TARGET_USE_GATHER): Define.
27908 * x86-tune.def (X86_TUNE_USE_GATHER): New.
27909
27910 2018-01-10 Martin Liska <mliska@suse.cz>
27911
27912 PR bootstrap/82831
27913 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
27914 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
27915 partitioning.
27916 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
27917 CLEANUP_NO_PARTITIONING is not set.
27918
27919 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
27920
27921 * doc/rtl.texi: Remove documentation of (const ...) wrappers
27922 for vectors, as a partial revert of r254296.
27923 * rtl.h (const_vec_p): Delete.
27924 (const_vec_duplicate_p): Don't test for vector CONSTs.
27925 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
27926 * expmed.c (make_tree): Likewise.
27927
27928 Revert:
27929 * common.md (E, F): Use CONSTANT_P instead of checking for
27930 CONST_VECTOR.
27931 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
27932 checking for CONST_VECTOR.
27933
27934 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
27935
27936 PR middle-end/83575
27937 * predict.c (force_edge_cold): Handle in more sane way edges
27938 with no prediction.
27939
27940 2018-01-09 Carl Love <cel@us.ibm.com>
27941
27942 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
27943 V4SI, V4SF types.
27944 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
27945 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
27946 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
27947 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
27948 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
27949 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
27950 * config/rs6000/rs6000-protos.h: Add extern defition for
27951 rs6000_generate_float2_double_code.
27952 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
27953 function.
27954 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
27955 (float2_v2df): Add define_expand.
27956
27957 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
27958
27959 PR target/83628
27960 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
27961 op_mode in the force_to_mode call.
27962
27963 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
27964
27965 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
27966 instead of checking each element individually.
27967 (aarch64_evpc_uzp): Likewise.
27968 (aarch64_evpc_zip): Likewise.
27969 (aarch64_evpc_ext): Likewise.
27970 (aarch64_evpc_rev): Likewise.
27971 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
27972 instead of checking each element individually. Return true without
27973 generating rtl if
27974 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
27975 whether all selected elements come from the same input, instead of
27976 checking each element individually. Remove calls to gen_rtx_REG,
27977 start_sequence and end_sequence and instead assert that no rtl is
27978 generated.
27979
27980 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
27981
27982 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
27983 order of HIGH and CONST checks.
27984
27985 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
27986
27987 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
27988 if the destination isn't an SSA_NAME.
27989
27990 2018-01-09 Richard Biener <rguenther@suse.de>
27991
27992 PR tree-optimization/83668
27993 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
27994 move prologue...
27995 (canonicalize_loop_form): ... here, renamed from ...
27996 (canonicalize_loop_closed_ssa_form): ... this and amended to
27997 swap successor edges for loop exit blocks to make us use
27998 the RPO order we need for initial schedule generation.
27999
28000 2018-01-09 Joseph Myers <joseph@codesourcery.com>
28001
28002 PR tree-optimization/64811
28003 * match.pd: When optimizing comparisons with Inf, avoid
28004 introducing or losing exceptions from comparisons with NaN.
28005
28006 2018-01-09 Martin Liska <mliska@suse.cz>
28007
28008 PR sanitizer/82517
28009 * asan.c (shadow_mem_size): Add gcc_assert.
28010
28011 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
28012
28013 Don't save registers in main().
28014
28015 PR target/83738
28016 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
28017 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
28018 * config/avr/avr.c (avr_set_current_function): Don't error if
28019 naked, OS_task or OS_main are specified at the same time.
28020 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
28021 OS_main.
28022 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
28023 attribute.
28024 * common/config/avr/avr-common.c (avr_option_optimization_table):
28025 Switch on -mmain-is-OS_task for optimizing compilations.
28026
28027 2018-01-09 Richard Biener <rguenther@suse.de>
28028
28029 PR tree-optimization/83572
28030 * graphite.c: Include cfganal.h.
28031 (graphite_transform_loops): Connect infinite loops to exit
28032 and remove fake edges at the end.
28033
28034 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28035
28036 * ipa-inline.c (edge_badness): Revert accidental checkin.
28037
28038 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28039
28040 PR ipa/80763
28041 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
28042 symbols; not inline clones.
28043
28044 2018-01-09 Jakub Jelinek <jakub@redhat.com>
28045
28046 PR target/83507
28047 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
28048 hard registers. Formatting fixes.
28049
28050 PR preprocessor/83722
28051 * gcc.c (try_generate_repro): Pass
28052 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
28053 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
28054 do_report_bug.
28055
28056 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
28057 Kito Cheng <kito.cheng@gmail.com>
28058
28059 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
28060 (riscv_leaf_function_p): Delete.
28061 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
28062
28063 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28064
28065 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
28066 function.
28067 (do_ifelse): New function.
28068 (do_isel): New function.
28069 (do_sub3): New function.
28070 (do_add3): New function.
28071 (do_load_mask_compare): New function.
28072 (do_overlap_load_compare): New function.
28073 (expand_compare_loop): New function.
28074 (expand_block_compare): Call expand_compare_loop() when appropriate.
28075 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
28076 option description.
28077 (-mblock-compare-inline-loop-limit): New option.
28078
28079 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
28080
28081 PR target/83677
28082 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
28083 Reverse order of second and third operands in first alternative.
28084 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
28085 of first and second elements in UNSPEC_VPERMR vector.
28086 (altivec_expand_vec_perm_le): Likewise.
28087
28088 2018-01-08 Jeff Law <law@redhat.com>
28089
28090 PR rtl-optimizatin/81308
28091 * tree-switch-conversion.c (cfg_altered): New file scoped static.
28092 (process_switch): If group_case_labels makes a change, then set
28093 cfg_altered.
28094 (pass_convert_switch::execute): If a switch is converted, then
28095 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
28096
28097 PR rtl-optimization/81308
28098 * recog.c (split_all_insns): Conditionally cleanup the CFG after
28099 splitting insns.
28100
28101 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
28102
28103 PR target/83663 - Revert r255946
28104 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
28105 generation for cases where splatting a value is not useful.
28106 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
28107 across a vec_duplicate and a paradoxical subreg forming a vector
28108 mode to a vec_concat.
28109
28110 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
28111
28112 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
28113 -march=armv8.3-a variants.
28114 * config/arm/t-multilib: Likewise.
28115 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
28116
28117 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28118
28119 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
28120 to generate rtl.
28121 (cceq_ior_compare_complement): Give it a name so I can use it, and
28122 change boolean_or_operator predicate to boolean_operator so it can
28123 be used to generate a crand.
28124 (eqne): New code iterator.
28125 (bd/bd_neg): New code_attrs.
28126 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
28127 a single define_insn.
28128 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
28129 decrement (bdnzt/bdnzf/bdzt/bdzf).
28130 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
28131 with the new names of the branch decrement patterns, and added the
28132 names of the branch decrement conditional patterns.
28133
28134 2018-01-08 Richard Biener <rguenther@suse.de>
28135
28136 PR tree-optimization/83563
28137 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
28138 cache.
28139
28140 2018-01-08 Richard Biener <rguenther@suse.de>
28141
28142 PR middle-end/83713
28143 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
28144
28145 2018-01-08 Richard Biener <rguenther@suse.de>
28146
28147 PR tree-optimization/83685
28148 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
28149 references to abnormals.
28150
28151 2018-01-08 Richard Biener <rguenther@suse.de>
28152
28153 PR lto/83719
28154 * dwarf2out.c (output_indirect_strings): Handle empty
28155 skeleton_debug_str_hash.
28156 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
28157
28158 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28159
28160 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
28161 (emit_store_direct): Likewise.
28162 (arc_trampoline_adjust_address): Likewise.
28163 (arc_asm_trampoline_template): New function.
28164 (arc_initialize_trampoline): Use asm_trampoline_template.
28165 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
28166 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
28167 * config/arc/arc.md (flush_icache): Delete pattern.
28168
28169 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28170
28171 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
28172 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
28173 munaligned-access.
28174
28175 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28176
28177 PR target/83681
28178 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
28179 by not USED_FOR_TARGET.
28180 (make_pass_resolve_sw_modes): Likewise.
28181
28182 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28183
28184 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
28185 USED_FOR_TARGET.
28186
28187 2018-01-08 Richard Biener <rguenther@suse.de>
28188
28189 PR middle-end/83580
28190 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
28191
28192 2018-01-08 Richard Biener <rguenther@suse.de>
28193
28194 PR middle-end/83517
28195 * match.pd ((t * 2) / 2) -> t): Add missing :c.
28196
28197 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
28198
28199 PR middle-end/81897
28200 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
28201 basic blocks with a small number of successors.
28202 (convert_control_dep_chain_into_preds): Improve handling of
28203 forwarder blocks.
28204 (dump_predicates): Split apart into...
28205 (dump_pred_chain): ...here...
28206 (dump_pred_info): ...and here.
28207 (can_one_predicate_be_invalidated_p): Add debugging printfs.
28208 (can_chain_union_be_invalidated_p): Improve check for invalidation
28209 of paths.
28210 (uninit_uses_cannot_happen): Avoid unnecessary if
28211 convert_control_dep_chain_into_preds yielded nothing.
28212
28213 2018-01-06 Martin Sebor <msebor@redhat.com>
28214
28215 PR tree-optimization/83640
28216 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
28217 subtracting negative offset from size.
28218 (builtin_access::overlap): Adjust offset bounds of the access to fall
28219 within the size of the object if possible.
28220
28221 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
28222
28223 PR rtl-optimization/83699
28224 * expmed.c (extract_bit_field_1): Restrict the vector usage of
28225 extract_bit_field_as_subreg to cases in which the extracted
28226 value is also a vector.
28227
28228 * lra-constraints.c (process_alt_operands): Test for the equivalence
28229 substitutions when detecting a possible reload cycle.
28230
28231 2018-01-06 Jakub Jelinek <jakub@redhat.com>
28232
28233 PR debug/83480
28234 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
28235 by default if flag_selective_schedling{,2}. Formatting fixes.
28236
28237 PR rtl-optimization/83682
28238 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
28239 if it has non-VECTOR_MODE element mode.
28240 (vec_duplicate_p): Likewise.
28241
28242 PR middle-end/83694
28243 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
28244 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
28245
28246 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28247
28248 PR target/83604
28249 * config/i386/i386-builtin.def
28250 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
28251 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
28252 Require also OPTION_MASK_ISA_AVX512F in addition to
28253 OPTION_MASK_ISA_GFNI.
28254 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
28255 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
28256 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
28257 to OPTION_MASK_ISA_GFNI.
28258 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
28259 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
28260 OPTION_MASK_ISA_AVX512BW.
28261 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
28262 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
28263 addition to OPTION_MASK_ISA_GFNI.
28264 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
28265 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
28266 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
28267 to OPTION_MASK_ISA_GFNI.
28268 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
28269 a requirement for all ISAs rather than any of them with a few
28270 exceptions.
28271 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
28272 processing.
28273 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
28274 bitmasks to be enabled with 3 exceptions, instead of requiring any
28275 enabled ISA with lots of exceptions.
28276 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
28277 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
28278 Change avx512bw in isa attribute to avx512f.
28279 * config/i386/sgxintrin.h: Add license boilerplate.
28280 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
28281 to __AVX512F__ and __AVX512VL to __AVX512VL__.
28282 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
28283 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
28284 defined.
28285 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
28286 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
28287 temporarily sse2 rather than sse if not enabled already.
28288
28289 PR target/83604
28290 * config/i386/sse.md (VI248_VLBW): Rename to ...
28291 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
28292 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
28293 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
28294 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
28295 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
28296 mode iterator instead of VI248_VLBW.
28297
28298 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
28299
28300 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
28301 (record_modified): Skip clobbers; add debug output.
28302 (param_change_prob): Use sreal frequencies.
28303
28304 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28305
28306 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
28307 punt for user-aligned variables.
28308
28309 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28310
28311 * tree-chrec.c (chrec_contains_symbols): Return true for
28312 POLY_INT_CST.
28313
28314 2018-01-05 Sudakshina Das <sudi.das@arm.com>
28315
28316 PR target/82439
28317 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
28318 of (x|y) == x for BICS pattern.
28319
28320 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28321
28322 PR tree-optimization/83605
28323 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
28324 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
28325 can throw.
28326
28327 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
28328
28329 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
28330 * config/epiphany/rtems.h: New file.
28331
28332 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28333 Uros Bizjak <ubizjak@gmail.com>
28334
28335 PR target/83554
28336 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
28337 QIreg_operand instead of register_operand predicate.
28338 * config/i386/i386.c (ix86_rop_should_change_byte_p,
28339 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
28340 comments instead of -fmitigate[-_]rop.
28341
28342 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
28343
28344 PR bootstrap/81926
28345 * cgraphunit.c (symbol_table::compile): Switch to text_section
28346 before calling assembly_start debug hook.
28347 * run-rtl-passes.c (run_rtl_passes): Likewise.
28348 Include output.h.
28349
28350 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28351
28352 * tree-vrp.c (extract_range_from_binary_expr_1): Check
28353 range_int_cst_p rather than !symbolic_range_p before calling
28354 extract_range_from_multiplicative_op_1.
28355
28356 2018-01-04 Jeff Law <law@redhat.com>
28357
28358 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
28359 redundant test in assertion.
28360
28361 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28362
28363 * doc/rtl.texi: Document machine_mode wrapper classes.
28364
28365 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28366
28367 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
28368 using tree_to_uhwi.
28369
28370 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28371
28372 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
28373 the VEC_PERM_EXPR fold to fail.
28374
28375 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28376
28377 PR debug/83585
28378 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
28379 to switched_sections.
28380
28381 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28382
28383 PR target/83680
28384 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
28385 test for d.testing.
28386
28387 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
28388
28389 PR target/83387
28390 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
28391 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
28392
28393 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28394
28395 PR debug/83666
28396 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
28397 is BLKmode and bitpos not zero or mode change is needed.
28398
28399 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28400
28401 PR target/83675
28402 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
28403 TARGET_VIS2.
28404
28405 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
28406
28407 PR target/83628
28408 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
28409 instead of MULT rtx. Update all corresponding splitters.
28410 (*saddl_se): Ditto.
28411 (*ssub<modesuffix>): Ditto.
28412 (*ssubl_se): Ditto.
28413 (*cmp_sadd_di): Update split patterns.
28414 (*cmp_sadd_si): Ditto.
28415 (*cmp_sadd_sidi): Ditto.
28416 (*cmp_ssub_di): Ditto.
28417 (*cmp_ssub_si): Ditto.
28418 (*cmp_ssub_sidi): Ditto.
28419 * config/alpha/predicates.md (const23_operand): New predicate.
28420 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
28421 Look for ASHIFT, not MULT inner operand.
28422 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
28423
28424 2018-01-04 Martin Liska <mliska@suse.cz>
28425
28426 PR gcov-profile/83669
28427 * gcov.c (output_intermediate_file): Add version to intermediate
28428 gcov file.
28429 * doc/gcov.texi: Document new field 'version' in intermediate
28430 file format. Fix location of '-k' option of gcov command.
28431
28432 2018-01-04 Martin Liska <mliska@suse.cz>
28433
28434 PR ipa/82352
28435 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
28436
28437 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28438
28439 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
28440
28441 2018-01-03 Martin Sebor <msebor@redhat.com>
28442
28443 PR tree-optimization/83655
28444 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
28445 checking calls with invalid arguments.
28446
28447 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28448
28449 * tree-vect-stmts.c (vect_get_store_rhs): New function.
28450 (vectorizable_mask_load_store): Delete.
28451 (vectorizable_call): Return false for masked loads and stores.
28452 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
28453 instead of gimple_assign_rhs1.
28454 (vectorizable_load): Handle IFN_MASK_LOAD.
28455 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
28456
28457 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28458
28459 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
28460 split out from..,
28461 (vectorizable_mask_load_store): ...here.
28462 (vectorizable_load): ...and here.
28463
28464 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28465
28466 * tree-vect-stmts.c (vect_build_all_ones_mask)
28467 (vect_build_zero_merge_argument): New functions, split out from...
28468 (vectorizable_load): ...here.
28469
28470 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28471
28472 * tree-vect-stmts.c (vect_check_store_rhs): New function,
28473 split out from...
28474 (vectorizable_mask_load_store): ...here.
28475 (vectorizable_store): ...and here.
28476
28477 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28478
28479 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
28480 split out from...
28481 (vectorizable_mask_load_store): ...here.
28482
28483 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28484
28485 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
28486 (vect_model_store_cost): Take a vec_load_store_type instead of a
28487 vect_def_type.
28488 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
28489 (vect_model_store_cost): Take a vec_load_store_type instead of a
28490 vect_def_type.
28491 (vectorizable_mask_load_store): Update accordingly.
28492 (vectorizable_store): Likewise.
28493 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
28494
28495 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28496
28497 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
28498 IFN_MASK_LOAD calls here rather than...
28499 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
28500
28501 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28502 Alan Hayward <alan.hayward@arm.com>
28503 David Sherwood <david.sherwood@arm.com>
28504
28505 * expmed.c (extract_bit_field_1): For vector extracts,
28506 fall back to extract_bit_field_as_subreg if vec_extract
28507 isn't available.
28508
28509 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28510 Alan Hayward <alan.hayward@arm.com>
28511 David Sherwood <david.sherwood@arm.com>
28512
28513 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
28514 they are variable or constant sized.
28515 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
28516 slots for constant-sized data.
28517
28518 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28519 Alan Hayward <alan.hayward@arm.com>
28520 David Sherwood <david.sherwood@arm.com>
28521
28522 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
28523 handling COND_EXPRs with boolean comparisons, try to find a better
28524 basis for the mask type than the boolean itself.
28525
28526 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28527
28528 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
28529 is calculated and how it can be overridden.
28530 * genmodes.c (max_bitsize_mode_any_mode): New variable.
28531 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
28532 if defined.
28533 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
28534 if nonzero.
28535
28536 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28537 Alan Hayward <alan.hayward@arm.com>
28538 David Sherwood <david.sherwood@arm.com>
28539
28540 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
28541 Remove the mode argument.
28542 (aarch64_simd_valid_immediate): Remove the mode and inverse
28543 arguments.
28544 * config/aarch64/iterators.md (bitsize): New iterator.
28545 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
28546 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
28547 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
28548 aarch64_simd_valid_immediate.
28549 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
28550 (aarch64_reg_or_bic_imm): Likewise.
28551 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
28552 with an insn_type enum and msl with a modifier_type enum.
28553 Replace element_width with a scalar_mode. Change the shift
28554 to unsigned int. Add constructors for scalar_float_mode and
28555 scalar_int_mode elements.
28556 (aarch64_vect_float_const_representable_p): Delete.
28557 (aarch64_can_const_movi_rtx_p)
28558 (aarch64_simd_scalar_immediate_valid_for_move)
28559 (aarch64_simd_make_constant): Update call to
28560 aarch64_simd_valid_immediate.
28561 (aarch64_advsimd_valid_immediate_hs): New function.
28562 (aarch64_advsimd_valid_immediate): Likewise.
28563 (aarch64_simd_valid_immediate): Remove mode and inverse
28564 arguments. Rewrite to use the above. Use const_vec_duplicate_p
28565 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
28566 and aarch64_float_const_representable_p on the result.
28567 (aarch64_output_simd_mov_immediate): Remove mode argument.
28568 Update call to aarch64_simd_valid_immediate and use of
28569 simd_immediate_info.
28570 (aarch64_output_scalar_simd_mov_immediate): Update call
28571 accordingly.
28572
28573 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28574 Alan Hayward <alan.hayward@arm.com>
28575 David Sherwood <david.sherwood@arm.com>
28576
28577 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
28578 (mode_nunits): Likewise CONST_MODE_NUNITS.
28579 * machmode.def (ADJUST_NUNITS): Document.
28580 * genmodes.c (mode_data::need_nunits_adj): New field.
28581 (blank_mode): Update accordingly.
28582 (adj_nunits): New variable.
28583 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
28584 parameter.
28585 (emit_mode_size_inline): Set need_bytesize_adj for all modes
28586 listed in adj_nunits.
28587 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
28588 listed in adj_nunits. Don't emit case statements for such modes.
28589 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
28590 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
28591 nothing if adj_nunits is nonnull.
28592 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
28593 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
28594 (emit_mode_fbit): Update use of print_maybe_const_decl.
28595 (emit_move_size): Likewise. Treat the array as non-const
28596 if adj_nunits.
28597 (emit_mode_adjustments): Handle adj_nunits.
28598
28599 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28600
28601 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
28602 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
28603 (VECTOR_MODES): Use it.
28604 (make_vector_modes): Take the prefix as an argument.
28605
28606 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28607 Alan Hayward <alan.hayward@arm.com>
28608 David Sherwood <david.sherwood@arm.com>
28609
28610 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
28611 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
28612 for MODE_VECTOR_BOOL.
28613 * machmode.def (VECTOR_BOOL_MODE): Document.
28614 * genmodes.c (VECTOR_BOOL_MODE): New macro.
28615 (make_vector_bool_mode): New function.
28616 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
28617 MODE_VECTOR_BOOL.
28618 * lto-streamer-in.c (lto_input_mode_table): Likewise.
28619 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
28620 Likewise.
28621 * stor-layout.c (int_mode_for_mode): Likewise.
28622 * tree.c (build_vector_type_for_mode): Likewise.
28623 * varasm.c (output_constant_pool_2): Likewise.
28624 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
28625 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
28626 for MODE_VECTOR_BOOL.
28627 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
28628 of mode class checks.
28629 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
28630 instead of a list of mode class checks.
28631 (expand_vector_scalar_condition): Likewise.
28632 (type_for_widest_vector_mode): Handle BImode as an inner mode.
28633
28634 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28635 Alan Hayward <alan.hayward@arm.com>
28636 David Sherwood <david.sherwood@arm.com>
28637
28638 * machmode.h (mode_size): Change from unsigned short to
28639 poly_uint16_pod.
28640 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
28641 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28642 or if measurement_type is not polynomial.
28643 (fixed_size_mode::includes_p): Check for constant-sized modes.
28644 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
28645 return a poly_uint16 rather than an unsigned short.
28646 (emit_mode_size): Change the type of mode_size from unsigned short
28647 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
28648 (emit_mode_adjustments): Cope with polynomial vector sizes.
28649 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28650 for GET_MODE_SIZE.
28651 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28652 for GET_MODE_SIZE.
28653 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
28654 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
28655 * caller-save.c (setup_save_areas): Likewise.
28656 (replace_reg_with_saved_mem): Likewise.
28657 * calls.c (emit_library_call_value_1): Likewise.
28658 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
28659 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
28660 (gen_lowpart_for_combine): Likewise.
28661 * convert.c (convert_to_integer_1): Likewise.
28662 * cse.c (equiv_constant, cse_insn): Likewise.
28663 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
28664 (cselib_subst_to_values): Likewise.
28665 * dce.c (word_dce_process_block): Likewise.
28666 * df-problems.c (df_word_lr_mark_ref): Likewise.
28667 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
28668 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
28669 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
28670 (rtl_for_decl_location): Likewise.
28671 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
28672 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
28673 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
28674 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
28675 (expand_expr_real_1): Likewise.
28676 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
28677 (pad_below): Likewise.
28678 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28679 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
28680 * ira.c (get_subreg_tracking_sizes): Likewise.
28681 * ira-build.c (ira_create_allocno_objects): Likewise.
28682 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
28683 (ira_sort_regnos_for_alter_reg): Likewise.
28684 * ira-costs.c (record_operand_costs): Likewise.
28685 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
28686 (resolve_simple_move): Likewise.
28687 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
28688 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
28689 (lra_constraints): Likewise.
28690 (CONST_POOL_OK_P): Reject variable-sized modes.
28691 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
28692 (add_pseudo_to_slot, lra_spill): Likewise.
28693 * omp-low.c (omp_clause_aligned_alignment): Likewise.
28694 * optabs-query.c (get_best_extraction_insn): Likewise.
28695 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
28696 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
28697 (expand_mult_highpart, valid_multiword_target_p): Likewise.
28698 * recog.c (offsettable_address_addr_space_p): Likewise.
28699 * regcprop.c (maybe_mode_change): Likewise.
28700 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
28701 * regrename.c (build_def_use): Likewise.
28702 * regstat.c (dump_reg_info): Likewise.
28703 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
28704 (find_reloads, find_reloads_subreg_address): Likewise.
28705 * reload1.c (eliminate_regs_1): Likewise.
28706 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
28707 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
28708 (simplify_binary_operation_1, simplify_subreg): Likewise.
28709 * targhooks.c (default_function_arg_padding): Likewise.
28710 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
28711 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
28712 (verify_gimple_assign_ternary): Likewise.
28713 * tree-inline.c (estimate_move_cost): Likewise.
28714 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28715 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
28716 (get_address_cost_ainc): Likewise.
28717 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
28718 (vect_supportable_dr_alignment): Likewise.
28719 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28720 (vectorizable_reduction): Likewise.
28721 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
28722 (vectorizable_operation, vectorizable_load): Likewise.
28723 * tree.c (build_same_sized_truth_vector_type): Likewise.
28724 * valtrack.c (cleanup_auto_inc_dec): Likewise.
28725 * var-tracking.c (emit_note_insn_var_location): Likewise.
28726 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
28727 (ADDR_VEC_ALIGN): Likewise.
28728
28729 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28730 Alan Hayward <alan.hayward@arm.com>
28731 David Sherwood <david.sherwood@arm.com>
28732
28733 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
28734 unsigned short.
28735 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28736 or if measurement_type is polynomial.
28737 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
28738 * combine.c (make_extraction): Likewise.
28739 * dse.c (find_shift_sequence): Likewise.
28740 * dwarf2out.c (mem_loc_descriptor): Likewise.
28741 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
28742 (extract_bit_field, extract_low_bits): Likewise.
28743 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
28744 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
28745 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
28746 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
28747 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28748 * reload.c (find_reloads): Likewise.
28749 * reload1.c (alter_reg): Likewise.
28750 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
28751 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
28752 * tree-if-conv.c (predicate_mem_writes): Likewise.
28753 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
28754 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
28755 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
28756 * valtrack.c (dead_debug_insert_temp): Likewise.
28757 * varasm.c (mergeable_constant_section): Likewise.
28758 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
28759
28760 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28761 Alan Hayward <alan.hayward@arm.com>
28762 David Sherwood <david.sherwood@arm.com>
28763
28764 * expr.c (expand_assignment): Cope with polynomial mode sizes
28765 when assigning to a CONCAT.
28766
28767 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28768 Alan Hayward <alan.hayward@arm.com>
28769 David Sherwood <david.sherwood@arm.com>
28770
28771 * machmode.h (mode_precision): Change from unsigned short to
28772 poly_uint16_pod.
28773 (mode_to_precision): Return a poly_uint16 rather than an unsigned
28774 short.
28775 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
28776 or if measurement_type is not polynomial.
28777 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
28778 in which the mode is already known to be a scalar_int_mode.
28779 * genmodes.c (emit_mode_precision): Change the type of mode_precision
28780 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
28781 initializer.
28782 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28783 for GET_MODE_PRECISION.
28784 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28785 for GET_MODE_PRECISION.
28786 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
28787 as polynomial.
28788 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
28789 (expand_field_assignment, make_extraction): Likewise.
28790 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
28791 (get_last_value): Likewise.
28792 * convert.c (convert_to_integer_1): Likewise.
28793 * cse.c (cse_insn): Likewise.
28794 * expr.c (expand_expr_real_1): Likewise.
28795 * lra-constraints.c (simplify_operand_subreg): Likewise.
28796 * optabs-query.c (can_atomic_load_p): Likewise.
28797 * optabs.c (expand_atomic_load): Likewise.
28798 (expand_atomic_store): Likewise.
28799 * ree.c (combine_reaching_defs): Likewise.
28800 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
28801 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
28802 * tree.h (type_has_mode_precision_p): Likewise.
28803 * ubsan.c (instrument_si_overflow): Likewise.
28804
28805 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28806 Alan Hayward <alan.hayward@arm.com>
28807 David Sherwood <david.sherwood@arm.com>
28808
28809 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
28810 polynomial numbers of units.
28811 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
28812 (valid_vector_subparts_p): New function.
28813 (build_vector_type): Remove temporary shim and take the number
28814 of units as a poly_uint64 rather than an int.
28815 (build_opaque_vector_type): Take the number of units as a
28816 poly_uint64 rather than an int.
28817 * tree.c (build_vector_from_ctor): Handle polynomial
28818 TYPE_VECTOR_SUBPARTS.
28819 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
28820 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
28821 (build_vector_from_val): If the number of units is variable,
28822 use build_vec_duplicate_cst for constant operands and
28823 VEC_DUPLICATE_EXPR otherwise.
28824 (make_vector_type): Remove temporary is_constant ().
28825 (build_vector_type, build_opaque_vector_type): Take the number of
28826 units as a poly_uint64 rather than an int.
28827 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
28828 VECTOR_CST_NELTS.
28829 * cfgexpand.c (expand_debug_expr): Likewise.
28830 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
28831 (store_constructor, expand_expr_real_1): Likewise.
28832 (const_scalar_mask_from_tree): Likewise.
28833 * fold-const-call.c (fold_const_reduction): Likewise.
28834 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
28835 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
28836 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
28837 (fold_relational_const): Likewise.
28838 (native_interpret_vector): Likewise. Change the size from an
28839 int to an unsigned int.
28840 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
28841 TYPE_VECTOR_SUBPARTS.
28842 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
28843 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
28844 duplicating a non-constant operand into a variable-length vector.
28845 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
28846 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
28847 * ipa-icf.c (sem_variable::equals): Likewise.
28848 * match.pd: Likewise.
28849 * omp-simd-clone.c (simd_clone_subparts): Likewise.
28850 * print-tree.c (print_node): Likewise.
28851 * stor-layout.c (layout_type): Likewise.
28852 * targhooks.c (default_builtin_vectorization_cost): Likewise.
28853 * tree-cfg.c (verify_gimple_comparison): Likewise.
28854 (verify_gimple_assign_binary): Likewise.
28855 (verify_gimple_assign_ternary): Likewise.
28856 (verify_gimple_assign_single): Likewise.
28857 * tree-pretty-print.c (dump_generic_node): Likewise.
28858 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28859 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
28860 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
28861 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
28862 (vect_shift_permute_load_chain): Likewise.
28863 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
28864 (expand_vector_condition, optimize_vector_constructor): Likewise.
28865 (lower_vec_perm, get_compute_type): Likewise.
28866 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28867 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
28868 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
28869 (vect_recog_mask_conversion_pattern): Likewise.
28870 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
28871 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
28872 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
28873 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
28874 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
28875 (vectorizable_shift, vectorizable_operation, vectorizable_store)
28876 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
28877 (supportable_widening_operation): Likewise.
28878 (supportable_narrowing_operation): Likewise.
28879 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
28880 Likewise.
28881 * varasm.c (output_constant): Likewise.
28882
28883 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28884 Alan Hayward <alan.hayward@arm.com>
28885 David Sherwood <david.sherwood@arm.com>
28886
28887 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
28888 so that both the length == 3 and length != 3 cases set up their
28889 own permute vectors. Add comments explaining why we know the
28890 number of elements is constant.
28891 (vect_permute_load_chain): Likewise.
28892
28893 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28894 Alan Hayward <alan.hayward@arm.com>
28895 David Sherwood <david.sherwood@arm.com>
28896
28897 * machmode.h (mode_nunits): Change from unsigned char to
28898 poly_uint16_pod.
28899 (ONLY_FIXED_SIZE_MODES): New macro.
28900 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
28901 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
28902 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
28903 New typedefs.
28904 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
28905 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
28906 or if measurement_type is not polynomial.
28907 * genmodes.c (ZERO_COEFFS): New macro.
28908 (emit_mode_nunits_inline): Make mode_nunits_inline return a
28909 poly_uint16.
28910 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
28911 Use ZERO_COEFFS when emitting initializers.
28912 * data-streamer.h (bp_pack_poly_value): New function.
28913 (bp_unpack_poly_value): Likewise.
28914 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28915 for GET_MODE_NUNITS.
28916 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28917 for GET_MODE_NUNITS.
28918 * tree.c (make_vector_type): Remove temporary shim and make
28919 the real function take the number of units as a poly_uint64
28920 rather than an int.
28921 (build_vector_type_for_mode): Handle polynomial nunits.
28922 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
28923 * emit-rtl.c (const_vec_series_p_1): Likewise.
28924 (gen_rtx_CONST_VECTOR): Likewise.
28925 * fold-const.c (test_vec_duplicate_folding): Likewise.
28926 * genrecog.c (validate_pattern): Likewise.
28927 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
28928 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
28929 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
28930 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
28931 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
28932 * rtlanal.c (subreg_get_info): Likewise.
28933 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
28934 (vect_grouped_load_supported): Likewise.
28935 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
28936 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
28937 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
28938 (simplify_const_unary_operation, simplify_binary_operation_1)
28939 (simplify_const_binary_operation, simplify_ternary_operation)
28940 (test_vector_ops_duplicate, test_vector_ops): Likewise.
28941 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
28942 instead of CONST_VECTOR_NUNITS.
28943 * varasm.c (output_constant_pool_2): Likewise.
28944 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
28945 explicit-encoded elements in the XVEC for variable-length vectors.
28946
28947 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28948
28949 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
28950
28951 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28952 Alan Hayward <alan.hayward@arm.com>
28953 David Sherwood <david.sherwood@arm.com>
28954
28955 * coretypes.h (fixed_size_mode): Declare.
28956 (fixed_size_mode_pod): New typedef.
28957 * builtins.h (target_builtins::x_apply_args_mode)
28958 (target_builtins::x_apply_result_mode): Change type to
28959 fixed_size_mode_pod.
28960 * builtins.c (apply_args_size, apply_result_size, result_vector)
28961 (expand_builtin_apply_args_1, expand_builtin_apply)
28962 (expand_builtin_return): Update accordingly.
28963
28964 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28965
28966 * cse.c (hash_rtx_cb): Hash only the encoded elements.
28967 * cselib.c (cselib_hash_rtx): Likewise.
28968 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
28969 CONST_VECTOR encoding.
28970
28971 2018-01-03 Jakub Jelinek <jakub@redhat.com>
28972 Jeff Law <law@redhat.com>
28973
28974 PR target/83641
28975 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
28976 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
28977 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
28978 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
28979
28980 PR target/83641
28981 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
28982 explicitly probe *sp in a noreturn function if there were any callee
28983 register saves or frame pointer is needed.
28984
28985 2018-01-03 Jakub Jelinek <jakub@redhat.com>
28986
28987 PR debug/83621
28988 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
28989 BLKmode for ternary, binary or unary expressions.
28990
28991 PR debug/83645
28992 * var-tracking.c (delete_vta_debug_insn): New inline function.
28993 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
28994 insns from get_insns () to NULL instead of each bb separately.
28995 Use delete_vta_debug_insn. No longer static.
28996 (vt_debug_insns_local, variable_tracking_main_1): Adjust
28997 delete_vta_debug_insns callers.
28998 * rtl.h (delete_vta_debug_insns): Declare.
28999 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
29000 instead of variable_tracking_main.
29001
29002 2018-01-03 Martin Sebor <msebor@redhat.com>
29003
29004 PR tree-optimization/83603
29005 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
29006 arguments past the endof the argument list in functions declared
29007 without a prototype.
29008 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
29009 Avoid checking when arguments are null.
29010
29011 2018-01-03 Martin Sebor <msebor@redhat.com>
29012
29013 PR c/83559
29014 * doc/extend.texi (attribute const): Fix a typo.
29015 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
29016 issuing -Wsuggest-attribute for void functions.
29017
29018 2018-01-03 Martin Sebor <msebor@redhat.com>
29019
29020 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
29021 offset_int::from instead of wide_int::to_shwi.
29022 (maybe_diag_overlap): Remove assertion.
29023 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
29024 * gimple-ssa-sprintf.c (format_directive): Same.
29025 (parse_directive): Same.
29026 (sprintf_dom_walker::compute_format_length): Same.
29027 (try_substitute_return_value): Same.
29028
29029 2018-01-03 Jeff Law <law@redhat.com>
29030
29031 PR middle-end/83654
29032 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
29033 non-constant residual for zero at runtime and avoid probing in
29034 that case. Reorganize code for trailing problem to mirror handling
29035 of the residual.
29036
29037 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
29038
29039 PR tree-optimization/83501
29040 * tree-ssa-strlen.c (get_string_cst): New.
29041 (handle_char_store): Call get_string_cst.
29042
29043 2018-01-03 Martin Liska <mliska@suse.cz>
29044
29045 PR tree-optimization/83593
29046 * tree-ssa-strlen.c: Include tree-cfg.h.
29047 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
29048 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
29049 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
29050 to false.
29051 (strlen_dom_walker::before_dom_children): Call
29052 gimple_purge_dead_eh_edges. Dump tranformation with details
29053 dump flags.
29054 (strlen_dom_walker::before_dom_children): Update call by adding
29055 new argument cleanup_eh.
29056 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
29057
29058 2018-01-03 Martin Liska <mliska@suse.cz>
29059
29060 PR ipa/83549
29061 * cif-code.def (VARIADIC_THUNK): New enum value.
29062 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
29063 thunks.
29064
29065 2018-01-03 Jan Beulich <jbeulich@suse.com>
29066
29067 * sse.md (mov<mode>_internal): Tighten condition for when to use
29068 vmovdqu<ssescalarsize> for TI and OI modes.
29069
29070 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29071
29072 Update copyright years.
29073
29074 2018-01-03 Martin Liska <mliska@suse.cz>
29075
29076 PR ipa/83594
29077 * ipa-visibility.c (function_and_variable_visibility): Skip
29078 functions with noipa attribure.
29079
29080 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29081
29082 * gcc.c (process_command): Update copyright notice dates.
29083 * gcov-dump.c (print_version): Ditto.
29084 * gcov.c (print_version): Ditto.
29085 * gcov-tool.c (print_version): Ditto.
29086 * gengtype.c (create_file): Ditto.
29087 * doc/cpp.texi: Bump @copying's copyright year.
29088 * doc/cppinternals.texi: Ditto.
29089 * doc/gcc.texi: Ditto.
29090 * doc/gccint.texi: Ditto.
29091 * doc/gcov.texi: Ditto.
29092 * doc/install.texi: Ditto.
29093 * doc/invoke.texi: Ditto.
29094
29095 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29096
29097 * vector-builder.h (vector_builder::m_full_nelts): Change from
29098 unsigned int to poly_uint64.
29099 (vector_builder::full_nelts): Update prototype accordingly.
29100 (vector_builder::new_vector): Likewise.
29101 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
29102 (vector_builder::operator ==): Likewise.
29103 (vector_builder::finalize): Likewise.
29104 * int-vector-builder.h (int_vector_builder::int_vector_builder):
29105 Take the number of elements as a poly_uint64 rather than an
29106 unsigned int.
29107 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
29108 from unsigned int to poly_uint64.
29109 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
29110 (vec_perm_indices::new_vector): Likewise.
29111 (vec_perm_indices::length): Likewise.
29112 (vec_perm_indices::nelts_per_input): Likewise.
29113 (vec_perm_indices::input_nelts): Likewise.
29114 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
29115 number of elements per input as a poly_uint64 rather than an
29116 unsigned int. Use the original encoding for variable-length
29117 vectors, rather than clamping each individual element.
29118 For the second and subsequent elements in each pattern,
29119 clamp the step and base before clamping their sum.
29120 (vec_perm_indices::series_p): Handle polynomial element counts.
29121 (vec_perm_indices::all_in_range_p): Likewise.
29122 (vec_perm_indices_to_tree): Likewise.
29123 (vec_perm_indices_to_rtx): Likewise.
29124 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
29125 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
29126 (tree_vector_builder::new_binary_operation): Handle polynomial
29127 element counts. Return false if we need to know the number
29128 of elements at compile time.
29129 * fold-const.c (fold_vec_perm): Punt if the number of elements
29130 isn't known at compile time.
29131
29132 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29133
29134 * vec-perm-indices.h (vec_perm_builder): Change element type
29135 from HOST_WIDE_INT to poly_int64.
29136 (vec_perm_indices::element_type): Update accordingly.
29137 (vec_perm_indices::clamp): Handle polynomial element_types.
29138 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29139 (vec_perm_indices::all_in_range_p): Likewise.
29140 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
29141 than shwi trees.
29142 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
29143 polynomial vec_perm_indices element types.
29144 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
29145 * fold-const.c (fold_vec_perm): Likewise.
29146 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
29147 * tree-vect-generic.c (lower_vec_perm): Likewise.
29148 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29149 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
29150 element type to HOST_WIDE_INT.
29151
29152 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29153 Alan Hayward <alan.hayward@arm.com>
29154 David Sherwood <david.sherwood@arm.com>
29155
29156 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
29157 rather than an int. Use plus_constant.
29158 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
29159 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
29160
29161 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29162 Alan Hayward <alan.hayward@arm.com>
29163 David Sherwood <david.sherwood@arm.com>
29164
29165 * calls.c (emit_call_1, expand_call): Change struct_value_size from
29166 a HOST_WIDE_INT to a poly_int64.
29167
29168 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29169 Alan Hayward <alan.hayward@arm.com>
29170 David Sherwood <david.sherwood@arm.com>
29171
29172 * calls.c (load_register_parameters): Cope with polynomial
29173 mode sizes. Require a constant size for BLKmode parameters
29174 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
29175 forces a parameter to be padded at the lsb end in order to
29176 fill a complete number of words, require the parameter size
29177 to be ordered wrt UNITS_PER_WORD.
29178
29179 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29180 Alan Hayward <alan.hayward@arm.com>
29181 David Sherwood <david.sherwood@arm.com>
29182
29183 * reload1.c (spill_stack_slot_width): Change element type
29184 from unsigned int to poly_uint64_pod.
29185 (alter_reg): Treat mode sizes as polynomial.
29186
29187 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29188 Alan Hayward <alan.hayward@arm.com>
29189 David Sherwood <david.sherwood@arm.com>
29190
29191 * reload.c (complex_word_subreg_p): New function.
29192 (reload_inner_reg_of_subreg, push_reload): Use it.
29193
29194 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29195 Alan Hayward <alan.hayward@arm.com>
29196 David Sherwood <david.sherwood@arm.com>
29197
29198 * lra-constraints.c (process_alt_operands): Reject matched
29199 operands whose sizes aren't ordered.
29200 (match_reload): Refer to this check here.
29201
29202 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29203 Alan Hayward <alan.hayward@arm.com>
29204 David Sherwood <david.sherwood@arm.com>
29205
29206 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
29207 that the mode size is in the set {1, 2, 4, 8, 16}.
29208
29209 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29210 Alan Hayward <alan.hayward@arm.com>
29211 David Sherwood <david.sherwood@arm.com>
29212
29213 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
29214 Use plus_constant instead of gen_rtx_PLUS.
29215
29216 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29217 Alan Hayward <alan.hayward@arm.com>
29218 David Sherwood <david.sherwood@arm.com>
29219
29220 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
29221 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
29222 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
29223 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
29224 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
29225 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
29226 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
29227 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
29228 * config/i386/i386.c (ix86_push_rounding): ...this new function.
29229 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
29230 a poly_int64.
29231 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
29232 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
29233 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
29234 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
29235 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
29236 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
29237 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
29238 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
29239 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
29240 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
29241 function.
29242 * expr.c (emit_move_resolve_push): Treat the input and result
29243 of PUSH_ROUNDING as a poly_int64.
29244 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
29245 (emit_push_insn): Likewise.
29246 * lra-eliminations.c (mark_not_eliminable): Likewise.
29247 * recog.c (push_operand): Likewise.
29248 * reload1.c (elimination_effects): Likewise.
29249 * rtlanal.c (nonzero_bits1): Likewise.
29250 * calls.c (store_one_arg): Likewise. Require the padding to be
29251 known at compile time.
29252
29253 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29254 Alan Hayward <alan.hayward@arm.com>
29255 David Sherwood <david.sherwood@arm.com>
29256
29257 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
29258 Use plus_constant instead of gen_rtx_PLUS.
29259
29260 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29261 Alan Hayward <alan.hayward@arm.com>
29262 David Sherwood <david.sherwood@arm.com>
29263
29264 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
29265 rather than an int.
29266
29267 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29268 Alan Hayward <alan.hayward@arm.com>
29269 David Sherwood <david.sherwood@arm.com>
29270
29271 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
29272 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
29273 via stack temporaries. Treat the mode size as polynomial too.
29274
29275 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29276 Alan Hayward <alan.hayward@arm.com>
29277 David Sherwood <david.sherwood@arm.com>
29278
29279 * expr.c (expand_expr_real_2): When handling conversions involving
29280 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
29281 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
29282 as a poly_uint64 too.
29283
29284 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29285 Alan Hayward <alan.hayward@arm.com>
29286 David Sherwood <david.sherwood@arm.com>
29287
29288 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
29289
29290 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29291 Alan Hayward <alan.hayward@arm.com>
29292 David Sherwood <david.sherwood@arm.com>
29293
29294 * combine.c (can_change_dest_mode): Handle polynomial
29295 REGMODE_NATURAL_SIZE.
29296 * expmed.c (store_bit_field_1): Likewise.
29297 * expr.c (store_constructor): Likewise.
29298 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
29299 and polynomial REGMODE_NATURAL_SIZE.
29300 (gen_lowpart_common): Likewise.
29301 * reginfo.c (record_subregs_of_mode): Likewise.
29302 * rtlanal.c (read_modify_subreg_p): Likewise.
29303
29304 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29305 Alan Hayward <alan.hayward@arm.com>
29306 David Sherwood <david.sherwood@arm.com>
29307
29308 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
29309 numbers of elements.
29310
29311 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29312 Alan Hayward <alan.hayward@arm.com>
29313 David Sherwood <david.sherwood@arm.com>
29314
29315 * match.pd: Cope with polynomial numbers of vector elements.
29316
29317 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29318 Alan Hayward <alan.hayward@arm.com>
29319 David Sherwood <david.sherwood@arm.com>
29320
29321 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
29322 in a POINTER_PLUS_EXPR.
29323
29324 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29325 Alan Hayward <alan.hayward@arm.com>
29326 David Sherwood <david.sherwood@arm.com>
29327
29328 * omp-simd-clone.c (simd_clone_subparts): New function.
29329 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
29330 (ipa_simd_modify_function_body): Likewise.
29331
29332 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29333 Alan Hayward <alan.hayward@arm.com>
29334 David Sherwood <david.sherwood@arm.com>
29335
29336 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
29337 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
29338 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
29339 (expand_vector_condition, vector_element): Likewise.
29340 (subparts_gt): New function.
29341 (get_compute_type): Use subparts_gt.
29342 (count_type_subparts): Delete.
29343 (expand_vector_operations_1): Use subparts_gt instead of
29344 count_type_subparts.
29345
29346 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29347 Alan Hayward <alan.hayward@arm.com>
29348 David Sherwood <david.sherwood@arm.com>
29349
29350 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
29351 (vect_compile_time_alias): ...this new function. Do the calculation
29352 on poly_ints rather than trees.
29353 (vect_prune_runtime_alias_test_list): Update call accordingly.
29354
29355 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29356 Alan Hayward <alan.hayward@arm.com>
29357 David Sherwood <david.sherwood@arm.com>
29358
29359 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
29360 numbers of units.
29361 (vect_schedule_slp_instance): Likewise.
29362
29363 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29364 Alan Hayward <alan.hayward@arm.com>
29365 David Sherwood <david.sherwood@arm.com>
29366
29367 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
29368 constant and extern definitions for variable-length vectors.
29369 (vect_get_constant_vectors): Note that the number of units
29370 is known to be constant.
29371
29372 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29373 Alan Hayward <alan.hayward@arm.com>
29374 David Sherwood <david.sherwood@arm.com>
29375
29376 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
29377 of units as polynomial. Choose between WIDE and NARROW based
29378 on multiple_p.
29379
29380 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29381 Alan Hayward <alan.hayward@arm.com>
29382 David Sherwood <david.sherwood@arm.com>
29383
29384 * tree-vect-stmts.c (simd_clone_subparts): New function.
29385 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
29386
29387 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29388 Alan Hayward <alan.hayward@arm.com>
29389 David Sherwood <david.sherwood@arm.com>
29390
29391 * tree-vect-stmts.c (vectorizable_call): Treat the number of
29392 vectors as polynomial. Use build_index_vector for
29393 IFN_GOMP_SIMD_LANE.
29394
29395 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29396 Alan Hayward <alan.hayward@arm.com>
29397 David Sherwood <david.sherwood@arm.com>
29398
29399 * tree-vect-stmts.c (get_load_store_type): Treat the number of
29400 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
29401 for variable-length vectors.
29402 (vectorizable_mask_load_store): Treat the number of units as
29403 polynomial, asserting that it is constant if the condition has
29404 already been enforced.
29405 (vectorizable_store, vectorizable_load): Likewise.
29406
29407 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29408 Alan Hayward <alan.hayward@arm.com>
29409 David Sherwood <david.sherwood@arm.com>
29410
29411 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
29412 of units as polynomial. Punt if we can't tell at compile time
29413 which vector contains the final result.
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 * tree-vect-loop.c (vectorizable_induction): Treat the number
29420 of units as polynomial. Punt on SLP inductions. Use an integer
29421 VEC_SERIES_EXPR for variable-length integer reductions. Use a
29422 cast of such a series for variable-length floating-point
29423 reductions.
29424
29425 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29426 Alan Hayward <alan.hayward@arm.com>
29427 David Sherwood <david.sherwood@arm.com>
29428
29429 * tree.h (build_index_vector): Declare.
29430 * tree.c (build_index_vector): New function.
29431 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
29432 of units as polynomial, forcibly converting it to a constant if
29433 vectorizable_reduction has already enforced the condition.
29434 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
29435 to create a {1,2,3,...} vector.
29436 (vectorizable_reduction): Treat the number of units as polynomial.
29437 Choose vectype_in based on the largest scalar element size rather
29438 than the smallest number of units. Enforce the restrictions
29439 relied on above.
29440
29441 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29442 Alan Hayward <alan.hayward@arm.com>
29443 David Sherwood <david.sherwood@arm.com>
29444
29445 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
29446 number of units as polynomial.
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 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
29453 * target.def (autovectorize_vector_sizes): Return the vector sizes
29454 by pointer, using vector_sizes rather than a bitmask.
29455 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
29456 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
29457 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
29458 Likewise.
29459 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
29460 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
29461 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
29462 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
29463 * omp-general.c (omp_max_vf): Likewise.
29464 * omp-low.c (omp_clause_aligned_alignment): Likewise.
29465 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
29466 * tree-vect-loop.c (vect_analyze_loop): Likewise.
29467 * tree-vect-slp.c (vect_slp_bb): Likewise.
29468 * doc/tm.texi: Regenerate.
29469 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
29470 to a poly_uint64.
29471 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
29472 the vector size as a poly_uint64 rather than an unsigned int.
29473 (current_vector_size): Change from an unsigned int to a poly_uint64.
29474 (get_vectype_for_scalar_type): Update accordingly.
29475 * tree.h (build_truth_vector_type): Take the size and number of
29476 units as a poly_uint64 rather than an unsigned int.
29477 (build_vector_type): Add a temporary overload that takes
29478 the number of units as a poly_uint64 rather than an unsigned int.
29479 * tree.c (make_vector_type): Likewise.
29480 (build_truth_vector_type): Take the number of units as a poly_uint64
29481 rather than an unsigned int.
29482
29483 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29484 Alan Hayward <alan.hayward@arm.com>
29485 David Sherwood <david.sherwood@arm.com>
29486
29487 * target.def (get_mask_mode): Take the number of units and length
29488 as poly_uint64s rather than unsigned ints.
29489 * targhooks.h (default_get_mask_mode): Update accordingly.
29490 * targhooks.c (default_get_mask_mode): Likewise.
29491 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
29492 * doc/tm.texi: Regenerate.
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 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
29499 * omp-general.c (omp_max_vf): Likewise.
29500 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
29501 (expand_omp_simd): Handle polynomial safelen.
29502 * omp-low.c (omplow_simd_context): Add a default constructor.
29503 (omplow_simd_context::max_vf): Change from int to poly_uint64.
29504 (lower_rec_simd_input_clauses): Update accordingly.
29505 (lower_rec_input_clauses): Likewise.
29506
29507 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29508 Alan Hayward <alan.hayward@arm.com>
29509 David Sherwood <david.sherwood@arm.com>
29510
29511 * tree-vectorizer.h (vect_nunits_for_cost): New function.
29512 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
29513 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
29514 (vect_analyze_slp_cost): Likewise.
29515 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
29516 (vect_model_load_cost): Likewise.
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-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
29523 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
29524 from an unsigned int * to a poly_uint64_pod *.
29525 (calculate_unrolling_factor): New function.
29526 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
29527
29528 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29529 Alan Hayward <alan.hayward@arm.com>
29530 David Sherwood <david.sherwood@arm.com>
29531
29532 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
29533 from an unsigned int to a poly_uint64.
29534 (_loop_vec_info::slp_unrolling_factor): Likewise.
29535 (_loop_vec_info::vectorization_factor): Change from an int
29536 to a poly_uint64.
29537 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
29538 (vect_get_num_vectors): New function.
29539 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
29540 (vect_get_num_copies): Use vect_get_num_vectors.
29541 (vect_analyze_data_ref_dependences): Change max_vf from an int *
29542 to an unsigned int *.
29543 (vect_analyze_data_refs): Change min_vf from an int * to a
29544 poly_uint64 *.
29545 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29546 than an unsigned HOST_WIDE_INT.
29547 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
29548 (vect_analyze_data_ref_dependence): Change max_vf from an int *
29549 to an unsigned int *.
29550 (vect_analyze_data_ref_dependences): Likewise.
29551 (vect_compute_data_ref_alignment): Handle polynomial vf.
29552 (vect_enhance_data_refs_alignment): Likewise.
29553 (vect_prune_runtime_alias_test_list): Likewise.
29554 (vect_shift_permute_load_chain): Likewise.
29555 (vect_supportable_dr_alignment): Likewise.
29556 (dependence_distance_ge_vf): Take the vectorization factor as a
29557 poly_uint64 rather than an unsigned HOST_WIDE_INT.
29558 (vect_analyze_data_refs): Change min_vf from an int * to a
29559 poly_uint64 *.
29560 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
29561 vfm1 as a poly_uint64 rather than an int. Make the same change
29562 for the returned bound_scalar.
29563 (vect_gen_vector_loop_niters): Handle polynomial vf.
29564 (vect_do_peeling): Likewise. Update call to
29565 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
29566 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
29567 be constant.
29568 * tree-vect-loop.c (vect_determine_vectorization_factor)
29569 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
29570 (vect_get_known_peeling_cost): Likewise.
29571 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
29572 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
29573 (vect_transform_loop): Likewise. Use the lowest possible VF when
29574 updating the upper bounds of the loop.
29575 (vect_min_worthwhile_factor): Make static. Return an unsigned int
29576 rather than an int.
29577 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
29578 polynomial unroll factors.
29579 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
29580 (vect_make_slp_decision): Likewise.
29581 (vect_supported_load_permutation_p): Likewise, and polynomial
29582 vf too.
29583 (vect_analyze_slp_cost): Handle polynomial vf.
29584 (vect_slp_analyze_node_operations): Likewise.
29585 (vect_slp_analyze_bb_1): Likewise.
29586 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29587 than an unsigned HOST_WIDE_INT.
29588 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
29589 (vectorizable_load): Handle polynomial vf.
29590 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
29591 a poly_uint64.
29592 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
29593
29594 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29595 Alan Hayward <alan.hayward@arm.com>
29596 David Sherwood <david.sherwood@arm.com>
29597
29598 * match.pd: Handle bit operations involving three constants
29599 and try to fold one pair.
29600
29601 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29602
29603 * tree-vect-loop-manip.c: Include gimple-fold.h.
29604 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
29605 niters_maybe_zero parameters. Handle other cases besides a step of 1.
29606 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
29607 Add a path that uses a step of VF instead of 1, but disable it
29608 for now.
29609 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
29610 and niters_no_overflow parameters. Update calls to
29611 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
29612 Create a new SSA name if the latter choses to use a ste other
29613 than zero, and return it via niters_vector_mult_vf_var.
29614 * tree-vect-loop.c (vect_transform_loop): Update calls to
29615 vect_do_peeling, vect_gen_vector_loop_niters and
29616 slpeel_make_loop_iterate_ntimes.
29617 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
29618 (vect_gen_vector_loop_niters): Update declarations after above changes.
29619
29620 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
29621
29622 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
29623 128-bit round to integer instructions.
29624 (ceil<mode>2): Likewise.
29625 (btrunc<mode>2): Likewise.
29626 (round<mode>2): Likewise.
29627
29628 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
29629
29630 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
29631 unaligned VSX load/store on P8/P9.
29632 (expand_block_clear): Allow the use of unaligned VSX
29633 load/store on P8/P9.
29634
29635 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
29636
29637 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
29638 New function.
29639 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
29640 swap associated with both a load and a store.
29641
29642 2018-01-02 Andrew Waterman <andrew@sifive.com>
29643
29644 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
29645 * config/riscv/riscv.md (clear_cache): Use it.
29646
29647 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
29648
29649 * web.c: Remove out-of-date comment.
29650
29651 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29652
29653 * expr.c (fixup_args_size_notes): Check that any existing
29654 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
29655 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
29656 (emit_single_push_insn): ...here.
29657
29658 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29659
29660 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
29661 (const_vector_encoded_nelts): New function.
29662 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
29663 (const_vector_int_elt, const_vector_elt): Declare.
29664 * emit-rtl.c (const_vector_int_elt_1): New function.
29665 (const_vector_elt): Likewise.
29666 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
29667 of CONST_VECTOR_ELT.
29668
29669 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29670
29671 * expr.c: Include rtx-vector-builder.h.
29672 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
29673 directly on the tree encoding.
29674 (const_vector_from_tree): Likewise.
29675 * optabs.c: Include rtx-vector-builder.h.
29676 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
29677 sequence of "u" values.
29678 * vec-perm-indices.c: Include rtx-vector-builder.h.
29679 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
29680 directly on the vec_perm_indices encoding.
29681
29682 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29683
29684 * doc/rtl.texi (const_vector): Describe new encoding scheme.
29685 * Makefile.in (OBJS): Add rtx-vector-builder.o.
29686 * rtx-vector-builder.h: New file.
29687 * rtx-vector-builder.c: Likewise.
29688 * rtl.h (rtx_def::u2): Add a const_vector field.
29689 (CONST_VECTOR_NPATTERNS): New macro.
29690 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
29691 (CONST_VECTOR_DUPLICATE_P): Likewise.
29692 (CONST_VECTOR_STEPPED_P): Likewise.
29693 (CONST_VECTOR_ENCODED_ELT): Likewise.
29694 (const_vec_duplicate_p): Check for a duplicated vector encoding.
29695 (unwrap_const_vec_duplicate): Likewise.
29696 (const_vec_series_p): Check for a non-duplicated vector encoding.
29697 Say that the function only returns true for integer vectors.
29698 * emit-rtl.c: Include rtx-vector-builder.h.
29699 (gen_const_vec_duplicate_1): Delete.
29700 (gen_const_vector): Call gen_const_vec_duplicate instead of
29701 gen_const_vec_duplicate_1.
29702 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
29703 (gen_const_vec_duplicate): Use rtx_vector_builder.
29704 (gen_const_vec_series): Likewise.
29705 (gen_rtx_CONST_VECTOR): Likewise.
29706 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
29707 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29708 Build a new vector rather than modifying a CONST_VECTOR in-place.
29709 (handle_special_swappables): Update call accordingly.
29710 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
29711 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29712 Build a new vector rather than modifying a CONST_VECTOR in-place.
29713 (handle_special_swappables): Update call accordingly.
29714
29715 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29716
29717 * simplify-rtx.c (simplify_const_binary_operation): Use
29718 CONST_VECTOR_ELT instead of XVECEXP.
29719
29720 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29721
29722 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
29723 the selector elements to be different from the data elements
29724 if the selector is a VECTOR_CST.
29725 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
29726 ssizetype for the selector.
29727
29728 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29729
29730 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
29731 before testing each element individually.
29732 * tree-vect-generic.c (lower_vec_perm): Likewise.
29733
29734 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29735
29736 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
29737 * selftest-run-tests.c (selftest::run_tests): Call it.
29738 * vector-builder.h (vector_builder::operator ==): New function.
29739 (vector_builder::operator !=): Likewise.
29740 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
29741 (vec_perm_indices::all_from_input_p): New function.
29742 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29743 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
29744 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
29745 instead of reading the VECTOR_CST directly. Detect whether both
29746 vector inputs are the same before constructing the vec_perm_indices,
29747 and update the number of inputs argument accordingly. Use the
29748 utility functions added above. Only construct sel2 if we need to.
29749
29750 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29751
29752 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
29753 the broadcast of the low byte.
29754 (expand_mult_highpart): Use an explicit encoding for the permutes.
29755 * optabs-query.c (can_mult_highpart_p): Likewise.
29756 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
29757 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29758 (vectorizable_bswap): Likewise.
29759 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
29760 explicit encoding for the power-of-2 permutes.
29761 (vect_permute_store_chain): Likewise.
29762 (vect_grouped_load_supported): Likewise.
29763 (vect_permute_load_chain): Likewise.
29764
29765 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29766
29767 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
29768 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
29769 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
29770 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29771 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
29772 (vect_gen_perm_mask_any): Likewise.
29773
29774 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29775
29776 * int-vector-builder.h: New file.
29777 * vec-perm-indices.h: Include int-vector-builder.h.
29778 (vec_perm_indices): Redefine as an int_vector_builder.
29779 (auto_vec_perm_indices): Delete.
29780 (vec_perm_builder): Redefine as a stand-alone class.
29781 (vec_perm_indices::vec_perm_indices): New function.
29782 (vec_perm_indices::clamp): Likewise.
29783 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
29784 (vec_perm_indices::new_vector): New function.
29785 (vec_perm_indices::new_expanded_vector): Update for new
29786 vec_perm_indices class.
29787 (vec_perm_indices::rotate_inputs): New function.
29788 (vec_perm_indices::all_in_range_p): Operate directly on the
29789 encoded form, without computing elided elements.
29790 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
29791 encoding. Update for new vec_perm_indices class.
29792 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
29793 the given vec_perm_builder.
29794 (expand_vec_perm_var): Update vec_perm_builder constructor.
29795 (expand_mult_highpart): Use vec_perm_builder instead of
29796 auto_vec_perm_indices.
29797 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
29798 vec_perm_indices instead of auto_vec_perm_indices. Use a single
29799 or double series encoding as appropriate.
29800 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
29801 vec_perm_indices instead of auto_vec_perm_indices.
29802 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
29803 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
29804 (vect_permute_store_chain): Likewise.
29805 (vect_grouped_load_supported): Likewise.
29806 (vect_permute_load_chain): Likewise.
29807 (vect_shift_permute_load_chain): Likewise.
29808 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
29809 (vect_transform_slp_perm_load): Likewise.
29810 (vect_schedule_slp_instance): Likewise.
29811 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29812 (vectorizable_mask_load_store): Likewise.
29813 (vectorizable_bswap): Likewise.
29814 (vectorizable_store): Likewise.
29815 (vectorizable_load): Likewise.
29816 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
29817 vec_perm_indices instead of auto_vec_perm_indices. Use
29818 tree_to_vec_perm_builder to read the vector from a tree.
29819 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
29820 vec_perm_builder instead of a vec_perm_indices.
29821 (have_whole_vector_shift): Use vec_perm_builder and
29822 vec_perm_indices instead of auto_vec_perm_indices. Leave the
29823 truncation to calc_vec_perm_mask_for_shift.
29824 (vect_create_epilog_for_reduction): Likewise.
29825 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
29826 from auto_vec_perm_indices to vec_perm_indices.
29827 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29828 instead of changing individual elements.
29829 (aarch64_vectorize_vec_perm_const): Use new_vector to install
29830 the vector in d.perm.
29831 * config/arm/arm.c (expand_vec_perm_d::perm): Change
29832 from auto_vec_perm_indices to vec_perm_indices.
29833 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29834 instead of changing individual elements.
29835 (arm_vectorize_vec_perm_const): Use new_vector to install
29836 the vector in d.perm.
29837 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
29838 Update vec_perm_builder constructor.
29839 (rs6000_expand_interleave): Likewise.
29840 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
29841 (rs6000_expand_interleave): Likewise.
29842
29843 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29844
29845 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
29846 to qimode could truncate the indices.
29847 * optabs.c (expand_vec_perm_var): Likewise.
29848
29849 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29850
29851 * Makefile.in (OBJS): Add vec-perm-indices.o.
29852 * vec-perm-indices.h: New file.
29853 * vec-perm-indices.c: Likewise.
29854 * target.h (vec_perm_indices): Replace with a forward class
29855 declaration.
29856 (auto_vec_perm_indices): Move to vec-perm-indices.h.
29857 * optabs.h: Include vec-perm-indices.h.
29858 (expand_vec_perm): Delete.
29859 (selector_fits_mode_p, expand_vec_perm_var): Declare.
29860 (expand_vec_perm_const): Declare.
29861 * target.def (vec_perm_const_ok): Replace with...
29862 (vec_perm_const): ...this new hook.
29863 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
29864 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
29865 * doc/tm.texi: Regenerate.
29866 * optabs.def (vec_perm_const): Delete.
29867 * doc/md.texi (vec_perm_const): Likewise.
29868 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
29869 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
29870 expand_vec_perm for constant permutation vectors. Assert that
29871 the mode of variable permutation vectors is the integer equivalent
29872 of the mode that is being permuted.
29873 * optabs-query.h (selector_fits_mode_p): Declare.
29874 * optabs-query.c: Include vec-perm-indices.h.
29875 (selector_fits_mode_p): New function.
29876 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
29877 is defined, instead of checking whether the vec_perm_const_optab
29878 exists. Use targetm.vectorize.vec_perm_const instead of
29879 targetm.vectorize.vec_perm_const_ok. Check whether the indices
29880 fit in the vector mode before using a variable permute.
29881 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
29882 vec_perm_indices instead of an rtx.
29883 (expand_vec_perm): Replace with...
29884 (expand_vec_perm_const): ...this new function. Take the selector
29885 as a vec_perm_indices rather than an rtx. Also take the mode of
29886 the selector. Update call to shift_amt_for_vec_perm_mask.
29887 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
29888 Use vec_perm_indices::new_expanded_vector to expand the original
29889 selector into bytes. Check whether the indices fit in the vector
29890 mode before using a variable permute.
29891 (expand_vec_perm_var): Make global.
29892 (expand_mult_highpart): Use expand_vec_perm_const.
29893 * fold-const.c: Includes vec-perm-indices.h.
29894 * tree-ssa-forwprop.c: Likewise.
29895 * tree-vect-data-refs.c: Likewise.
29896 * tree-vect-generic.c: Likewise.
29897 * tree-vect-loop.c: Likewise.
29898 * tree-vect-slp.c: Likewise.
29899 * tree-vect-stmts.c: Likewise.
29900 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
29901 Delete.
29902 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
29903 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
29904 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
29905 (aarch64_vectorize_vec_perm_const): ...this new function.
29906 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
29907 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29908 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
29909 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
29910 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
29911 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29912 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
29913 into...
29914 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
29915 check for NEON modes.
29916 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
29917 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
29918 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
29919 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
29920 into...
29921 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
29922 the old VEC_PERM_CONST conditions.
29923 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
29924 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
29925 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
29926 (ia64_vectorize_vec_perm_const_ok): Merge into...
29927 (ia64_vectorize_vec_perm_const): ...this new function.
29928 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
29929 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
29930 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
29931 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
29932 * config/mips/mips.c (mips_expand_vec_perm_const)
29933 (mips_vectorize_vec_perm_const_ok): Merge into...
29934 (mips_vectorize_vec_perm_const): ...this new function.
29935 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
29936 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
29937 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
29938 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
29939 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
29940 (rs6000_expand_vec_perm_const): Delete.
29941 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
29942 Delete.
29943 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29944 (altivec_expand_vec_perm_const_le): Take each operand individually.
29945 Operate on constant selectors rather than rtxes.
29946 (altivec_expand_vec_perm_const): Likewise. Update call to
29947 altivec_expand_vec_perm_const_le.
29948 (rs6000_expand_vec_perm_const): Delete.
29949 (rs6000_vectorize_vec_perm_const_ok): Delete.
29950 (rs6000_vectorize_vec_perm_const): New function.
29951 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
29952 an element count and rtx array.
29953 (rs6000_expand_extract_even): Update call accordingly.
29954 (rs6000_expand_interleave): Likewise.
29955 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
29956 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
29957 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
29958 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
29959 (rs6000_expand_vec_perm_const): Delete.
29960 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
29961 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29962 (altivec_expand_vec_perm_const_le): Take each operand individually.
29963 Operate on constant selectors rather than rtxes.
29964 (altivec_expand_vec_perm_const): Likewise. Update call to
29965 altivec_expand_vec_perm_const_le.
29966 (rs6000_expand_vec_perm_const): Delete.
29967 (rs6000_vectorize_vec_perm_const_ok): Delete.
29968 (rs6000_vectorize_vec_perm_const): New function. Remove stray
29969 reference to the SPE evmerge intructions.
29970 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
29971 an element count and rtx array.
29972 (rs6000_expand_extract_even): Update call accordingly.
29973 (rs6000_expand_interleave): Likewise.
29974 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
29975 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
29976 new function.
29977 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29978
29979 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29980
29981 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
29982 vector mode and that that mode matches the mode of the data
29983 being permuted.
29984 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
29985 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
29986 directly using expand_vec_perm_1 when forcing selectors into
29987 registers.
29988 (expand_vec_perm_var): New function, split out from expand_vec_perm.
29989
29990 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29991
29992 * optabs-query.h (can_vec_perm_p): Delete.
29993 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
29994 * optabs-query.c (can_vec_perm_p): Split into...
29995 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
29996 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
29997 particular selector is valid.
29998 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
29999 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
30000 (vect_grouped_load_supported): Likewise.
30001 (vect_shift_permute_load_chain): Likewise.
30002 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
30003 (vect_transform_slp_perm_load): Likewise.
30004 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
30005 (vectorizable_bswap): Likewise.
30006 (vect_gen_perm_mask_checked): Likewise.
30007 * fold-const.c (fold_ternary_loc): Likewise. Don't take
30008 implementations of variable permutation vectors into account
30009 when deciding which selector to use.
30010 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
30011 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
30012 with a false third argument.
30013 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
30014 to test whether the constant selector is valid and can_vec_perm_var_p
30015 to test whether a variable selector is valid.
30016
30017 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30018
30019 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
30020 * optabs-query.c (can_vec_perm_p): Likewise.
30021 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
30022 instead of vec_perm_indices.
30023 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
30024 (vect_gen_perm_mask_checked): Likewise,
30025 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
30026 (vect_gen_perm_mask_checked): Likewise,
30027
30028 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30029
30030 * optabs-query.h (qimode_for_vec_perm): Declare.
30031 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
30032 (qimode_for_vec_perm): ...this new function.
30033 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
30034
30035 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
30036
30037 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
30038 does not have a conditional at the top.
30039
30040 2018-01-02 Richard Biener <rguenther@suse.de>
30041
30042 * ipa-inline.c (big_speedup_p): Fix expression.
30043
30044 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30045
30046 PR target/81616
30047 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
30048 for generic 4->6.
30049
30050 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30051
30052 PR target/81616
30053 Generic tuning.
30054 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
30055 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
30056 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
30057 cond_taken_branch_cost 3->4.
30058
30059 2018-01-01 Jakub Jelinek <jakub@redhat.com>
30060
30061 PR tree-optimization/83581
30062 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
30063 TODO_cleanup_cfg if any changes have been made.
30064
30065 PR middle-end/83608
30066 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
30067 convert_modes if target mode has the right side, but different mode
30068 class.
30069
30070 PR middle-end/83609
30071 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
30072 last argument when extracting from CONCAT. If either from_real or
30073 from_imag is NULL, use expansion through memory. If result is not
30074 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
30075 the parts directly to inner mode, if even that fails, use expansion
30076 through memory.
30077
30078 PR middle-end/83623
30079 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
30080 check for bswap in mode rather than HImode and use that in expand_unop
30081 too.
30082 \f
30083 Copyright (C) 2018 Free Software Foundation, Inc.
30084
30085 Copying and distribution of this file, with or without modification,
30086 are permitted in any medium without royalty provided the copyright
30087 notice and this notice are preserved.