1 2018-10-24 Richard Biener <rguenther@suse.de>
3 PR tree-optimization/87665
4 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
7 2018-10-12 Jeff Law <law@redhat.com>
9 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
12 2018-10-23 Richard Biener <rguenther@suse.de>
14 * tree-vrp.c (add_assert_info): Guard dump_printf with
16 * gimple-ssa-evrp-analyze.c
17 (evrp_range_analyzer::record_ranges_from_incoming_edge):
18 Use value_range::ignore_equivs_equal_p.
20 2018-10-23 Richard Biener <rguenther@suse.de>
22 PR tree-optimization/87105
23 PR tree-optimization/87608
24 * passes.def (pass_all_early_optimizations): Add early phi-opt
26 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
27 addition to debug stmts.
28 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
29 and abs replacement early.
30 * tree-cfg.c (gimple_empty_block_p): Likewise.
32 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
35 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
36 specified to configure.
37 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
39 2018-10-23 Richard Biener <rguenther@suse.de>
41 PR tree-optimization/87700
42 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
44 2018-10-23 Jakub Jelinek <jakub@redhat.com>
47 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
48 second argument from __mmask16 to __mmask8.
49 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
50 _mm_mask_packs_epi32): Likewise.
51 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
53 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
55 2018-10-23 Richard Biener <rguenther@suse.de>
57 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
59 2018-10-23 Richard Biener <rguenther@suse.de>
61 PR tree-optimization/86144
62 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
65 2018-10-23 Richard Biener <rguenther@suse.de>
67 PR tree-optimization/87693
68 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
69 the case we do not find the taken edge.
71 2018-10-22 Paul Koning <ni1d@arrl.net>
73 * symtab.c (symtab_node::increase_alignment): Correct max
76 2018-10-22 Yury Gribov <tetra2005@gmail.com>
78 PR tree-optimization/87633
79 * match.pd: Do not generate unordered integer comparisons.
81 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
83 PR rtl-optimization/87600
84 * combine.c: Add include of expr.h.
85 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
87 (make_more_copies): New function, add a copy to a new pseudo after
88 the moves from hard registers into pseudos.
89 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
90 later. Call make_more_copies.
92 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
94 * lra-constraints.c (process_alt_operands): New local array,
95 matching_early_clobber. Check matching_early_clobber before
96 decrementing reject, and set matching_early_clobber after.
98 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
101 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
102 call output_addr_const and hope for the best.
104 2018-10-22 Richard Biener <rguenther@suse.de>
106 * gimple-ssa-evrp-analyze.c
107 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
108 smarter about what ranges to use.
109 * tree-vrp.c (add_assert_info): Dump here.
110 (register_edge_assert_for_2): Instead of here at multiple but
113 * gcc.dg/tree-ssa/evrp12.c: New testcase.
114 * gcc.dg/predict-6.c: Adjust.
115 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
116 * gcc.dg/tree-ssa/vrp02.c: Likewise.
117 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
119 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
120 Richard Biener <rguenther@suse.de>
122 * bitmap.h: Update data structure documentation, including a
123 description of bitmap views as either linked-lists or splay trees.
124 (struct bitmap_element_def): Update comments for splay tree bitmaps.
125 (struct bitmap_head_def): Likewise.
126 (bitmap_list_view, bitmap_tree_view): New prototypes.
127 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
129 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
130 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
131 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
132 released bitmap element here.
133 (bitmap_element_free): Remove.
134 (bitmap_elt_clear_from): Work on splay tree bitmaps.
135 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
136 this function similar ones such that linked-list bitmap implementation
137 functions are grouped.
138 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
139 and moved for grouping.
140 (bitmap_list_insert_element_after): Renamed from
141 bitmap_elt_insert_after, and moved for grouping.
142 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
143 (bitmap_tree_link_left, bitmap_tree_link_right,
144 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
145 bitmap_tree_link_element, bitmap_tree_unlink_element,
146 bitmap_tree_find_element): New functions for splay-tree bitmap
148 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
149 Renamed and moved, see above entries.
150 (bitmap_tree_listify_from): New function to convert part of a splay
151 tree bitmap to a linked-list bitmap.
152 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
153 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
154 (bitmap_find_bit): Remove.
155 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
156 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
157 Handle splay tree bitmaps.
158 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
159 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
160 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
161 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
162 bitmap_intersect_compl_p, bitmap_ior_and_compl,
163 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
164 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
165 corresponding changes to use linked-list specific bitmap_element
166 manipulation functions as applicable for efficiency.
167 (bitmap_tree_to_vec): New function.
168 (debug_bitmap_elt_file): New function split out from ...
169 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
170 (bitmap_print): Likewise.
172 PR tree-optimization/63155
173 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
175 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
178 2018-10-22 Martin Liska <mliska@suse.cz>
180 PR tree-optimization/87686
182 2018-08-29 Martin Liska <mliska@suse.cz>
184 * tree-switch-conversion.c (switch_conversion::expand):
185 Strenghten assumption about gswitch statements.
187 2018-10-22 Martin Liska <mliska@suse.cz>
189 * ipa-icf.c (sem_item::compare_attributes): Remove.
190 (sem_item::compare_referenced_symbol_properties): Use
191 attribute_list_equal instead.
192 (sem_function::equals_wpa): Likewise.
193 * ipa-icf.h: Remove compare_attributes.
195 2018-10-22 Richard Biener <rguenther@suse.de>
198 * mem-stats.h (mem_usage::operator==): Fix pasto.
200 2018-10-22 Richard Biener <rguenther@suse.de>
202 PR tree-optimization/87640
203 * tree-vrp.c (set_value_range_with_overflow): Decompose
205 (extract_range_from_binary_expr_1): Adjust.
207 2018-10-22 Martin Jambor <mjambor@suse.cz>
209 * tree-eh.h (stmt_could_throw_p): Add function parameter.
210 (stmt_can_throw_external): Likewise.
211 (stmt_can_throw_internal): Likewise.
212 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
213 (lower_eh_constructs_2): Likewise.
214 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
215 (stmt_can_throw_external): Likewise.
216 (stmt_can_throw_internal): Likewise.
217 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
218 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
219 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
220 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
221 (pass_lower_eh_dispatch::execute): Pass cfun to
222 stmt_can_throw_external.
223 (cleanup_empty_eh): Likewise.
224 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
225 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
226 stmt_can_throw_external instead of pushing it to cfun.
227 (symbol_table::create_edge): Likewise.
228 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
229 stmt_can_throw_internal.
230 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
231 to stmt_could_throw_p.
232 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
233 stmt_can_throw_internal.
234 (pass_store_merging::execute): Likewise.
235 * gimple-ssa-strength-reduction.c
236 (find_candidates_dom_walker::before_dom_children): Pass cfun to
238 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
239 stmt_can_throw_internal.
240 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
241 to stmt_can_throw_external.
242 (check_stmt): Pass cfun to stmt_could_throw_p.
243 (check_stmt): Pass cfun to stmt_can_throw_external.
244 (pass_nothrow::execute): Likewise.
245 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
246 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
247 stmt_can_throw_internal.
248 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
249 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
250 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
251 * tree-complex.c (expand_complex_libcall): Pass cfun to
252 stmt_could_throw_p and to stmt_can_throw_internal.
253 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
254 * tree-inline.c (copy_edges_for_bb): Likewise.
255 (maybe_move_debug_stmts_to_successors): Likewise.
256 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
258 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
259 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
260 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
261 stmt_can_throw_internal.
262 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
263 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
265 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
266 stmt_can_throw_internal.
267 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
268 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
270 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
271 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
272 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
273 (convert_mult_to_fma_1): Likewise.
274 (convert_to_divmod): Likewise.
275 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
276 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
277 * tree-ssa-propagate.c
278 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
279 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
280 (maybe_optimize_range_tests): Likewise.
281 (linearize_expr_tree): Likewise.
282 (reassociate_bb): Likewise.
283 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
284 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
285 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
286 (handle_char_store): Likewise.
287 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
288 stmt_can_throw_internal.
289 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
291 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
292 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
293 (vectorizable_simd_clone_call): Likewise.
294 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
295 (gimple_stringop_fixed_value): Likewise.
297 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
299 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
300 literal pool references.
301 (s390_check_qrst_address): Adapt to the new behavior of
302 s390_loadrelative_operand_p ().
304 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
307 * config/i386/sse.md (*andnot<mode>3_bcst): New.
309 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
312 * config/i386/sse.md (*<code><mode>3_bcst): New.
314 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
317 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
318 V4DI, V16SI and V8DI.
319 (*sub<mode>3<mask_name>_bcst): New.
320 (*add<mode>3<mask_name>_bcst): Likewise.
322 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
325 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
326 __builtin_ia32_vfnmsubpd512_mask.
327 (_mm512_mask_fnmsub_round_pd): Likewise.
328 (_mm512_fnmsub_pd): Likewise.
329 (_mm512_mask_fnmsub_pd): Likewise.
330 (_mm512_maskz_fnmsub_round_pd): Use
331 __builtin_ia32_vfnmsubpd512_maskz.
332 (_mm512_maskz_fnmsub_pd): Likewise.
333 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
334 (_mm512_mask_fnmsub_round_ps): Likewise.
335 (_mm512_fnmsub_ps): Likewise.
336 (_mm512_mask_fnmsub_ps): Likewise.
337 (_mm512_maskz_fnmsub_round_ps): Use
338 __builtin_ia32_vfnmsubps512_maskz.
339 (_mm512_maskz_fnmsub_ps): Likewise.
340 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
341 __builtin_ia32_vfnmsubpd256_mask.
342 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
343 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
344 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
345 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
346 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
347 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
348 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
349 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
350 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
351 __builtin_ia32_vfnmsubpd.
352 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
353 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
354 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
355 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
356 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
357 * config/i386/i386-builtin.def: Add
358 __builtin_ia32_vfnmsubpd256_mask,
359 __builtin_ia32_vfnmsubpd256_maskz,
360 __builtin_ia32_vfnmsubpd128_mask,
361 __builtin_ia32_vfnmsubpd128_maskz,
362 __builtin_ia32_vfnmsubps256_mask,
363 __builtin_ia32_vfnmsubps256_maskz,
364 __builtin_ia32_vfnmsubps128_mask,
365 __builtin_ia32_vfnmsubps128_maskz,
366 __builtin_ia32_vfnmsubpd512_mask,
367 __builtin_ia32_vfnmsubpd512_maskz,
368 __builtin_ia32_vfnmsubps512_mask,
369 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
370 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
371 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
372 __builtin_ia32_vfnmsubpd256.
373 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
374 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
375 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
377 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
379 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
381 (fmai_vmfnmsub_<mode><round_name>): Likewise.
383 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
386 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
387 __builtin_ia32_vfnmaddpd512_mask.
388 (_mm512_mask_fnmadd_round_pd): Likewise.
389 (_mm512_fnmadd_pd): Likewise.
390 (_mm512_mask_fnmadd_pd): Likewise.
391 (_mm512_maskz_fnmadd_round_pd): Use
392 __builtin_ia32_vfnmaddpd512_maskz.
393 (_mm512_maskz_fnmadd_pd): Likewise.
394 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
395 (_mm512_mask_fnmadd_round_ps): Likewise.
396 (_mm512_fnmadd_ps): Likewise.
397 (_mm512_mask_fnmadd_ps): Likewise.
398 (_mm512_maskz_fnmadd_round_ps): Use
399 __builtin_ia32_vfnmaddps512_maskz.
400 (_mm512_maskz_fnmadd_ps): Likewise.
401 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
402 __builtin_ia32_vfnmaddpd256_mask.
403 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
404 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
405 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
406 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
407 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
408 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
409 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
410 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
411 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
412 __builtin_ia32_vfnmaddpd.
413 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
414 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
415 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
416 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
417 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
418 * config/i386/i386-builtin.def: Add
419 __builtin_ia32_vfnmaddpd256_mask,
420 __builtin_ia32_vfnmaddpd256_maskz,
421 __builtin_ia32_vfnmaddpd128_mask,
422 __builtin_ia32_vfnmaddpd128_maskz,
423 __builtin_ia32_vfnmaddps256_mask,
424 __builtin_ia32_vfnmaddps256_maskz,
425 __builtin_ia32_vfnmaddps128_mask,
426 __builtin_ia32_vfnmaddps128_maskz,
427 __builtin_ia32_vfnmaddpd512_mask,
428 __builtin_ia32_vfnmaddpd512_maskz,
429 __builtin_ia32_vfnmaddps512_mask,
430 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
431 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
432 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
433 __builtin_ia32_vfnmaddpd256.
434 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
435 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
436 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
438 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
440 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
442 (fmai_vmfnmadd_<mode><round_name>): Likewise.
444 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
447 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
448 __builtin_ia32_vfmsubpd512_mask.
449 (_mm512_mask_fmsub_round_pd): Likewise.
450 (_mm512_fmsub_pd): Likewise.
451 (_mm512_mask_fmsub_pd): Likewise.
452 (_mm512_maskz_fmsub_round_pd): Use
453 __builtin_ia32_vfmsubpd512_maskz.
454 (_mm512_maskz_fmsub_pd): Likewise.
455 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
456 (_mm512_mask_fmsub_round_ps): Likewise.
457 (_mm512_fmsub_ps): Likewise.
458 (_mm512_mask_fmsub_ps): Likewise.
459 (_mm512_maskz_fmsub_round_ps): Use
460 __builtin_ia32_vfmsubps512_maskz.
461 (_mm512_maskz_fmsub_ps): Likewise.
462 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
463 __builtin_ia32_vfmsubpd256_mask.
464 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
465 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
466 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
467 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
468 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
469 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
470 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
471 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
472 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
473 __builtin_ia32_vfmsubpd.
474 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
475 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
476 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
477 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
478 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
479 * config/i386/i386-builtin.def: Add
480 __builtin_ia32_vfmsubpd256_mask,
481 __builtin_ia32_vfmsubpd256_maskz,
482 __builtin_ia32_vfmsubpd128_mask,
483 __builtin_ia32_vfmsubpd128_maskz,
484 __builtin_ia32_vfmsubps256_mask,
485 __builtin_ia32_vfmsubps256_maskz,
486 __builtin_ia32_vfmsubps128_mask,
487 __builtin_ia32_vfmsubps128_maskz,
488 __builtin_ia32_vfmsubpd512_mask,
489 __builtin_ia32_vfmsubpd512_maskz,
490 __builtin_ia32_vfmsubps512_mask,
491 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
492 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
493 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
494 __builtin_ia32_vfmsubpd256.
495 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
496 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
497 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
499 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
501 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
503 (fmai_vmfmsub_<mode><round_name>): Likewise.
505 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
507 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
508 Remove plus. Renamed to ...
509 (*sub<mode>3<mask_name>_bcst): This.
510 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
511 (*add<mode>3<mask_name>_bcst): This.
513 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
516 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
518 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
521 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
522 (_mm_or_epi32): Likewise.
523 (_mm256_xor_epi32): Likewise.
524 (_mm_xor_epi32): Likewise.
525 (_mm256_or_epi64): Likewise.
526 (_mm_or_epi64): Likewise.
527 (_mm256_xor_epi64): Likewise.
528 (_mm_xor_epi64): Likewise.
530 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
533 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
535 2018-10-20 Jakub Jelinek <jakub@redhat.com>
538 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
540 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
542 * doc/ux.texi: Move @section directly after @node.
544 2018-10-19 Jakub Jelinek <jakub@redhat.com>
548 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
549 depend closely nested inside of loop with ordered clause with
552 2018-10-19 David Malcolm <dmalcolm@redhat.com>
554 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
555 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
556 * doc/ux.texi: New file.
558 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
560 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
561 be the first CR field allocated.
563 2018-10-19 Richard Biener <rguenther@suse.de>
566 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
567 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
569 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
573 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
574 (*add<mode>3<mask_name>_bcst_2): Likewise.
576 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
579 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
580 Replace nonimmediate_operand with register_operand.
581 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
583 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
586 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
588 PR rtl-optimization/87596
589 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
590 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
591 for instructions in FROM..TO range.
593 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
595 * cfgexpand.c (expand_one_var): Use specific wording in error message
596 for non-local frame variables.
597 * stor-layout.c (layout_decl): Do not issue a warning for them.
599 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
601 * haifa-sched.c (priority): Add force_recompute parameter.
602 (apply_replacement): Call priority () with force_recompute = true.
603 (restore_pattern): Likewise.
605 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
607 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
608 HOST_BITS_PER_WIDE_INT.
609 (test_vector_ops_duplicate): Likewise.
611 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
614 * config/i386/sse.md (VF_AVX512): New.
615 (avx512bcst): Likewise.
616 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
618 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
620 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
623 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
625 * doc/invoke.texi (-dumpversion): Improve grammar.
626 (-dumpfullversion): Make more consistent with -dumpversion.
628 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
630 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
631 Set JUMP_LABEL to the jump insn.
632 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
633 Predict emitted jump and add label to jump insn.
635 2018-10-18 David Malcolm <dmalcolm@redhat.com>
637 PR tree-optimization/87562
638 * input.c (get_substring_ranges_for_loc): Use
639 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
640 getting the linemap for the endpoint. Verify that it's either
641 in the same linemap as the start point's spelling location, or
642 at least in the same file.
644 2018-10-18 Richard Biener <rguenther@suse.de>
646 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
647 feed width-specific load/store costs through ix86_vec_cost.
648 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
650 (bdver_cost): Likewise.
651 (znver1_cost): Likewise.
652 (btver1_cost): Likewise.
653 (btver2_cost): Likewise.
655 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
657 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
658 to simplify subreg of vec_merge.
660 2018-10-18 Richard Biener <rguenther@suse.de>
662 * config/i386/i386.c: Fix costing of vector FMA.
664 2018-10-18 Richard Biener <rguenther@suse.de>
666 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
668 (ix86_builtin_vectorization_cost): For vec_construct properly
669 cost insertion into SSE regs.
670 (...): Adjust calls to ix86_vec_cost.
672 2018-10-18 Richard Biener <rguenther@suse.de>
676 2018-02-07 Richard Biener <rguenther@suse.de>
678 PR tree-optimization/84204
679 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
682 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
685 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
687 (test_vector_ops_duplicate): Add test for a scalar subreg of a
688 VEC_MERGE of a VEC_DUPLICATE.
690 2018-10-17 Joseph Myers <joseph@codesourcery.com>
692 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
693 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
694 * doc/standards.texi (C Language): Document C2X.
695 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
696 (rl78_option_override): Handle "GNU C2X" language name.
698 2018-10-17 Joseph Myers <joseph@codesourcery.com>
700 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
701 Document C17 as published in 2018.
703 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
706 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
707 bail out if both sides do not have the same storage order.
709 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
711 * bitmap.c (bitmap_head::dump): New.
712 * bitmap.h (bitmap_head): Add dump().
713 * gimple-ssa-evrp-analyze.c
714 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
715 (evrp_range_analyzer::set_ssa_range_info): Same.
716 (evrp_range_analyzer::record_ranges_from_phis): Same.
717 (evrp_range_analyzer::record_ranges_from_stmt): Same.
718 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
719 * gimple-ssa-sprintf.c (get_int_range): Same.
720 (format_integer): Same.
721 (sprintf_dom_walker::handle_gimple_call): Same.
722 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
723 (ipcp_vr_lattice::top_p): Same.
724 (ipcp_vr_lattice::bottom_p): Same.
725 (ipcp_vr_lattice::set_to_bottom): Same.
726 (ipa_vr_operation_and_type_effects): Same.
727 (propagate_vr_across_jump_function): Same.
728 (ipcp_store_vr_results): Same.
729 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
730 (ipa_print_node_jump_functions_for_edge): Same.
731 (ipa_get_value_range): Same.
732 (ipa_compute_jump_functions_for_edge): Same.
733 (ipa_write_jump_function): Same.
734 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
735 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
737 * vr-values.c (set_value_range_to_nonnegative): Same.
738 (set_value_range_to_truthvalue): Same.
739 (vr_values::get_value_range): Same.
740 (vr_values::set_defs_to_varying): Same.
741 (vr_values::update_value_range): Same.
742 (symbolic_range_based_on_p): Same.
743 (vr_values::op_with_boolean_value_range_p): Same.
744 (vr_values::extract_range_for_var_from_comparison_expr): Same.
745 (vr_values::extract_range_from_ssa_name): Same.
746 (vr_values::extract_range_from_binary_expr): Same.
747 (vr_values::extract_range_from_unary_expr): Same.
748 (vr_values::extract_range_from_cond_expr): Same.
749 (vr_values::extract_range_from_comparison): Same.
750 (vr_values::check_for_binary_op_overflow): Same.
751 (vr_values::extract_range_basic): Same.
752 (vr_values::extract_range_from_assignment): Same.
753 (compare_ranges): Same.
754 (compare_range_with_value): Same.
755 (vr_values::adjust_range_with_scev): Same.
756 (vrp_valueize): Same.
757 (vrp_valueize_1): Same.
758 (vr_values::get_vr_for_comparison): Same.
759 (vr_values::compare_name_with_value): Same.
760 (vr_values::compare_names): Same.
761 (vr_values::vrp_evaluate_conditional): Same.
762 (find_case_label_ranges): Same.
763 (vr_values::vrp_visit_switch_stmt): Same.
764 (vr_values::extract_range_from_phi_node): Same.
765 (vr_values::simplify_div_or_mod_using_ranges): Same.
766 (vr_values::simplify_bit_ops_using_ranges): Same.
767 (test_for_singularity): Same.
768 (range_fits_type_p): Same.
769 (vr_values::simplify_cond_using_ranges_1): Same.
770 (vr_values::simplify_switch_using_ranges): Same.
771 (vr_values::simplify_float_conversion_using_ranges): Same.
772 (vr_values::two_valued_val_range_p): Same.
773 (vr_values::add_equivalence): Move to value_range::equiv_add.
774 * vr-values.h (vr_values::add_equivalence): Remove.
775 (VR_INITIALIZER): Remove.
776 * tree-vrp.c (value_range::set): New.
777 (value_range::equiv_add): New.
778 (value_range::value_range): New.
779 (value_range::deep_copy): New.
780 (value_range::check): New.
781 (value_range::equal_p): New.
782 (value_range::ignore_equivs_equal_p): New.
783 (value_range::operator==): New.
784 (value_range::operator!=): New.
785 (value_range::symbolic_p): New.
786 (value_range::numeric_p): New.
787 (value_range::set_undefined): New.
788 (value_range::set_varying): New.
789 (value_range::may_contain_p): New.
790 (value_range::equiv_clear): New.
791 (value_range::singleton_p): New.
792 (value_range::intersect): New.
793 (value_range::dump): New.
794 (value_range::set_and_canonicalize): New.
795 (set_value_range): Adjust for value_range API.
796 (set_value_range_to_undefined): Same.
797 (set_value_range_to_varying): Same.
798 (set_and_canonicalize_value_range): Same.
799 (set_value_range_to_nonnull): Same.
800 (set_value_range_to_null): Same.
801 (range_is_null): Same.
802 (range_is_nonnull): Same.
803 (range_int_cst_p): Same.
804 (range_int_cst_singleton_p): Same.
805 (symbolic_range_p): Same.
806 (range_includes_zero_p): Same.
807 (value_range_constant_singleton): Same.
808 (vrp_set_zero_nonzero_bits): Same.
809 (ranges_from_anti_range): Same.
810 (extract_range_into_wide_ints): Same.
811 (extract_range_from_multiplicative_op): Same.
812 (set_value_range_with_overflow): Same.
813 (extract_range_from_binary_expr_1): Same.
814 (extract_range_from_unary_expr): Same.
815 (dump_value_range): Same.
816 (debug_value_range): Same.
817 (vrp_prop::check_array_ref): Same.
818 (vrp_prop::check_mem_ref): Same.
819 (vrp_prop::vrp_initialize): Same.
820 (vrp_prop::visit_stmt): Same.
821 (intersect_ranges): Same.
822 (vrp_prop::visit_phi): Same.
823 (vrp_prop::vrp_finalize): Same.
824 (determine_value_range_1): Same.
825 (determine_value_range): Same.
826 (vrp_intersect_ranges_1): Rename to...
827 (vrp_intersect_1): this.
828 (vrp_intersect_ranges): Rename to...
829 (value_range::intersect_helper): ...this.
830 (vrp_meet_1): Rename to...
831 (value_range::union_helper): ...this.
832 (vrp_meet): Rename to...
833 (value_range::union_): ...this.
834 (copy_value_range): Remove.
835 * tree-vrp.h (struct value_range): Rewrite into a proper class.
836 (value_range::vrtype): New.
837 (value_range::type): New.
838 (value_range::equiv): New.
839 (value_range::min): New.
840 (value_range::max): New.
841 (value_range::varying_p): New.
842 (value_range::undefined_p): New.
843 (value_range::null_p): New.
844 (value_range::equiv_add): New.
845 (copy_value_range): Remove.
847 2018-10-17 David Malcolm <dmalcolm@redhat.com>
849 * Makefile.in (SELFTEST_TARGETS): New.
850 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
851 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
852 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
854 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
855 (selftest-c++-gdb, selftest-c++-valgrind): Move to
857 * configure: Regenerate.
858 * configure.ac (selftest_languages): New.
860 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
862 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
863 overflow wraps argument.
864 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
865 wide_int_range_multiplicative_op.
866 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
867 overflow wraps argument.
868 (wide_int_range_multiplicative_op): Same.
869 (wide_int_range_lshift): Same.
870 (wide_int_range_div): Same.
871 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
872 (wide_int_range_lshift): Same.
873 (wide_int_range_div): Same.
875 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
877 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
878 use sign as argument.
879 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
880 wide_int_range_shift_undefined_p.
882 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
884 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
886 (@despeculate_copy<ALLI_TI:mode>): ... This.
887 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
890 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
892 * config.gcc: Obsolete *-*-solaris2.10*.
893 * doc/install.texi (Specific, *-*-solaris2*): Document it.
895 2018-10-12 Jeff Law <law@redhat.com>
897 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
898 reg + sym +- const_int addressing modes.
900 2018-10-15 David Malcolm <dmalcolm@redhat.com>
902 * common.opt (fdiagnostics-minimum-margin-width=): New option.
903 * diagnostic-show-locus.c (layout::layout): Apply the minimum
905 (layout::start_annotation_line): Only print up to 3 of the
906 margin character, to avoid touching the left-hand side.
907 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
908 minimum margin width, as set by test_diagnostic_context's ctor.
909 (selftest::test_fixit_insert_containing_newline): Likewise.
910 (selftest::test_fixit_insert_containing_newline_2): Likewise.
911 (selftest::test_line_numbers_multiline_range): Clear
913 * diagnostic.c (diagnostic_initialize): Initialize
915 * diagnostic.h (struct diagnostic_context): Add field
917 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
918 * opts.c (common_handle_option): Handle
919 OPT_fdiagnostics_minimum_margin_width_.
920 * selftest-diagnostic.c
921 (selftest::test_diagnostic_context::test_diagnostic_context):
922 Initialize min_margin_width to 6.
923 * toplev.c (general_init): Initialize global_dc->min_margin_width.
925 2018-10-15 David Malcolm <dmalcolm@redhat.com>
927 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
928 Fix usage of "error_at_rich_loc" in the comment.
930 2018-10-15 Renlin Li <renlin.li@arm.com>
933 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
934 if-conversioned loop when it contains ifn with types not
935 supported by backend.
936 * internal-fn.c (expand_direct_optab_fn): Add an assert.
937 (direct_internal_fn_supported_p): New helper function.
938 * internal-fn.h (direct_internal_fn_supported_p): Declare.
940 2018-10-15 Jakub Jelinek <jakub@redhat.com>
943 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
944 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
945 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
947 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
949 PR tree-optimization/87022
950 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
951 bits in dist vector rather than the first one.
953 2018-10-15 Richard Biener <rguenther@suse.de>
956 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
957 (visit_loadstore): When a used restrict tag escaped verify that
958 the points-to solution of "other" pointers do not include
960 (compute_dependence_clique): If a used restrict tag escaped
961 communicated that down to visit_loadstore.
963 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
965 * config/s390/s390.c (s390_expand_vec_init): Force vector element
966 into reg if it isn't a general operand.
968 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
971 * config/i386/sse.md (*vec_dupv2di): Add register source to
974 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
977 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
978 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
979 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
980 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
982 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
984 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
985 (notice_args_size): Set it in the current trace if no insn that can
986 throw internally has been seen yet.
987 (connect_traces): When connecting args_size between traces, allow the
988 incoming values not to match if there is an insn setting it before the
989 first insn that can throw internally; in that case, force the creation
990 of a CFI note on this latter insn.
992 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
994 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
995 the base class, because using the injected-class-name was not clearly
996 specified until DR 176.
998 2018-10-12 Paul Koning <ni1d@arrl.net>
1000 * config/pdp11/pdp11.md (doloop_end): New expander.
1001 (doloop_end_insn): renamed from "doloop_end".
1002 (addqi3): New pattern.
1003 (subqi3): New pattern.
1004 * config/pdp11/predicates.md (incdec_operand): New predicate.
1006 2018-10-12 Yury Gribov <tetra2005@gmail.com>
1009 * real.c (format_helper::can_represent_integral_type_p): New function
1010 * real.h (format_helper::can_represent_integral_type_p): Ditto.
1011 * match.pd: New pattern.
1013 2018-10-12 Alexandre Oliva <oliva@adacore.com>
1015 * configure.ac: Introduce --enable-large-address-aware
1016 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
1017 * doc/install.texi: Document it.
1018 * configure, config.in: Rebuilt.
1019 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
1020 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
1021 (LINK_SPEC): Insert it.
1022 * config/i386/mingw-264.h: Likewise.
1024 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
1026 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
1028 PR rtl-optimization/87600
1029 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
1031 2018-10-12 Paul Koning <ni1d@arrl.net>
1033 * doc/md.texi (doloop_end): Document that the pattern code may
1034 need to check operand mode.
1036 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
1038 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
1039 to zero-extend between int and floating-point registers.
1040 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
1041 ldp into floating-point registers. Add type and arch attributes.
1042 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
1043 Use f_loads for type attribute.
1045 2018-10-11 Martin Sebor <msebor@redhat.com>
1047 * doc/extend.texi (attribute packed): Correct typos.
1049 2018-10-11 Martin Sebor <msebor@redhat.com>
1051 * doc/extend.texi (attribute flatten): Mention interaction with
1054 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
1057 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
1058 Set new_decl virtual flag to zero.
1060 2018-10-11 Martin Sebor <msebor@redhat.com>
1063 * doc/extend.texi (attribute format_arg): Discuss using multiple
1064 attributes on a single function.
1066 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
1068 PR tree-optimization/86829
1069 * match.pd (sin (atan (x))): New simplification rules.
1070 (cos (atan (x))): Likewise.
1071 * real.c (build_sinatan_real): New function.
1072 * real.h (build_sinatan_real): Prototype.
1074 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
1076 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
1078 (fold_mergeeo_helper): New helper function.
1079 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
1080 intrinsics. Correct some whitespace indentation issues.
1082 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
1085 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
1086 Use HOST_WIDE_INT_1U for shift.
1088 2018-10-11 Doug Rupp <rupp@adacore.com>
1089 Olivier Hainque <hainque@adacore.com>
1091 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
1092 Pass --relax to the linker for RTPs.
1093 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
1095 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
1096 Jan Hubicka <jh@suse.cz>
1097 Martin Jambor <mjambor@suse.cz>
1099 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
1100 the same elements are repeated rather than printing all of them.
1101 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
1102 "repeated" elements.
1103 * read-rtl-function.c (test_loading_repeat): New function.
1104 (read_rtl_function_c_tests): Call test_loading_repeat.
1105 * rtl-tests.c (test_dumping_repeat): New function.
1106 (rtl_tests_c_tests): Call test_dumping_repeat.
1108 2018-10-11 Richard Biener <rguenther@suse.de>
1110 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
1111 bdver?_cost): Unify to ...
1112 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
1113 * config/i386/i386.c (processor_cost_table): Adjust.
1115 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
1118 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
1119 the thunk when expanding to GIMPLE.
1121 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
1123 * varasm.c (mergeable_string_section): Don't try to move zero-length
1124 strings to the merge section.
1126 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
1129 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
1131 2018-10-10 Jakub Jelinek <jakub@redhat.com>
1134 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
1135 to special_args set.
1137 2018-10-10 Richard Biener <rguenther@suse.de>
1139 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
1140 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
1141 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
1142 and recursing and pattern terminating the recursion on SSE
1143 vector width using ix86_expand_reduc.
1144 (reduc_sminmax_scal_<mode>): Split into part reducing to half
1145 width and recursing and SSE2 vector variant doing the final
1146 reduction with ix86_expand_reduc.
1147 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
1148 with terminating the recursion at AVX level, splitting that
1151 2018-10-09 David Malcolm <dmalcolm@redhat.com>
1153 * genmatch.c (error_cb): Rename to...
1154 (diagnostic_cb): ...this, converting int params to enums.
1155 (fatal_at): Update for renaming.
1156 (warning_at): Likewise.
1158 * input.c (selftest::ebcdic_execution_charset::apply):
1159 Update for renaming of...
1160 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
1162 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
1163 converting level and reason to enums.
1164 (class selftest::lexer_error_sink): Rename to...
1165 (class selftest::lexer_test_options): ...this, renaming field
1166 "m_errors" to "m_diagnostics".
1167 (selftest::lexer_test_options::apply): Update for renaming of...
1168 (selftest::lexer_test_options::on_error): ...this, renaming to...
1169 (selftest::lexer_test_options::on_diagnostic): ...this
1170 converting level and reason to enums.
1171 (selftest::test_lexer_string_locations_raw_string_unterminated):
1172 Update for renamings.
1173 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
1176 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
1178 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
1179 * config/rs6000/pmmintrin.h: New file.
1181 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
1183 PR tree-optimization/86659
1184 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
1186 2018-10-09 Richard Biener <rguenther@suse.de>
1188 PR tree-optimization/63155
1189 * tree-ssa-structalias.c: Include tree-ssa.h.
1190 (get_constraint_for_ssa_var): For undefs return nothing_id.
1191 (find_func_aliases): Cleanup PHI handling.
1193 2018-10-09 Richard Biener <rguenther@suse.de>
1195 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
1198 2018-10-09 Martin Liska <mliska@suse.cz>
1200 * asan.c (asan_emit_stack_protection): If a stack variable
1201 is located in a same file as current function, then emit
1202 line info into variable definition string.
1204 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
1206 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
1209 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
1211 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
1214 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
1216 PR tree-optimization/86659
1217 * gimple-match.h (struct gimple_match_op): Add reverse field.
1218 (gimple_match_op::set_op): New overloaded method.
1219 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
1220 the REF_REVERSE_STORAGE_ORDER flag on the value.
1221 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
1222 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
1224 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
1227 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
1228 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
1230 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
1233 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
1234 Defined with __builtin_ia32_vfmaddsubpd512_mask.
1236 2018-10-08 Richard Biener <rguenther@suse.de>
1238 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
1239 cost the same as AVX128 ones.
1241 2018-10-08 Paul Koning <ni1d@arrl.net>
1243 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
1244 (expand_block_move): New function.
1245 * config/pdp11/pdp11.c (output_block_move): Remove.
1246 (expand_block_move): New function.
1247 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
1248 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
1249 (*movmemhi1): Remove.
1251 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
1253 * config/s390/2827.md: Increase latencies for some FP instructions.
1255 2018-10-08 Richard Biener <rguenther@suse.de>
1257 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
1259 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
1260 * tree-vectorizer.h (dump_stmt_cost): Adjust.
1261 (add_stmt_cost): Dump return value of the hook.
1263 2018-10-08 Richard Biener <rguenther@suse.de>
1265 PR tree-optimization/63155
1266 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
1267 (ssa_propagation_engine::ssa_propagate): Remove redundant
1268 bitmap bit clearing.
1270 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
1272 PR rtl-optimization/86939
1273 PR rtl-optimization/87479
1274 * ira.h (non_conflicting_reg_copy_p): New prototype.
1275 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
1276 (make_hard_regno_dead): Don't add conflicts for register
1277 ignore_reg_for_conflicts.
1278 (make_object_dead): Likewise.
1279 (non_conflicting_reg_copy_p): New function.
1280 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
1281 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
1282 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
1283 (make_hard_regno_dead): Don't add conflicts for register
1284 ignore_reg_for_conflicts. Remove special conflict handling of
1285 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
1286 check_pic_pseudo_p and update callers.
1287 (mark_pseudo_dead): Don't add conflicts for register
1288 ignore_reg_for_conflicts.
1289 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
1291 2018-10-05 Andrew Waterman <andrew@sifive.com>
1292 Jim Wilson <jimw@sifive.com>
1294 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
1295 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
1296 new pattern using HONOR_SNANS that emits one extra instruction.
1298 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
1300 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
1301 patterns): Merge SI and DI patterns to a GPR pattern.
1302 (unnamed define_insn and define_split for record form of that): Merge
1303 to a single define_insn_and_split pattern.
1305 2018-10-05 David Malcolm <dmalcolm@redhat.com>
1308 * input.c (expand_location_to_spelling_point): Add param "aspect"
1309 and use rather than hardcoding LOCATION_ASPECT_CARET.
1310 (get_substring_ranges_for_loc): Handle the case of a single token
1311 within a macro expansion.
1312 * input.h (expand_location_to_spelling_point): Add "aspect" param,
1313 defaulting to LOCATION_ASPECT_CARET.
1315 2018-10-05 Paul Koning <ni1d@arrl.net>
1317 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
1318 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
1319 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
1320 (pdp11_guard_type): New function.
1322 2018-10-05 Paul Koning <ni1d@arrl.net>
1324 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
1325 * config/pdp11/pdp11.opt (mfloat32): Remove.
1327 * doc/invoke.texi (pdp11 -mfloat32): Remove:
1328 (pdp11 -mfloat64): Remove.
1330 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
1332 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
1333 (*cmp<mode>_cc_i387): Ditto.
1334 (*cmpu<mode>_cc_i387): Ditto.
1335 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
1336 * config/i386/i386.c (ix86_expand_fp_compare): Remove
1338 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
1339 Emit x86_sahf_1 pattern.
1340 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
1341 (ix86_expand_carry_flag_compare): Ditto.
1343 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
1345 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
1346 to reg_or_0_operand. Add "C" constraint.
1347 (*cmpxf_cc_i387): Ditto.
1348 (*cmp<mode>_i387): Change operand 2 predicate
1349 to nonimm_or_0_operand. Add "C" constraint.
1350 (*cmp<mode>_cc_i387): Ditto.
1351 (*cmp<mode>_0_i387): Remove insn pattern.
1352 (*cmp<mode>_0_cc_i387): Ditto.
1354 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
1356 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
1357 * config/i386/predicates.md (nonimm_or_0_operand): Rename
1358 from vector_move_operand. Update all uses.
1360 2018-10-05 Martin Sebor <msebor@redhat.com>
1362 PR tree-optimization/87490
1363 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
1366 2018-10-05 Richard Biener <rguenther@suse.de>
1368 PR tree-optimization/63155
1369 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
1370 vertical space in dumpfiles.
1371 * tree-ssa-propagate.h
1372 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
1373 * tree-ssa-propagate.c (cfg_blocks_back): New global.
1374 (ssa_edge_worklist_back): Likewise.
1375 (curr_order): Likewise.
1376 (cfg_blocks_get): Remove abstraction.
1377 (cfg_blocks_add): Likewise.
1378 (cfg_blocks_empty_p): Likewise.
1379 (add_ssa_edge): Add to current or next worklist based on
1381 (add_control_edge): Likewise.
1382 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
1384 (ssa_propagation_engine::ssa_propagate): ... here. Unify
1385 iteration from CFG and SSA edge worklist so we process
1386 everything in RPO order, prioritizing forward progress
1388 (ssa_prop_init): Allocate new worklists, do not dump
1390 (ssa_prop_fini): Free new worklists.
1392 2018-10-05 Richard Biener <rguenther@suse.de>
1394 * tree-core.h (tree_block::abstract_flag): Remove.
1395 (tree_block::block_num): Make full 32bits.
1396 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
1397 * tree.h (BLOCK_ABSTRACT): Remove.
1398 * dwarf2out.c (gen_lexical_block_die): Remove dead code
1399 resulting from BLOCK_ABSTRACT being always false.
1400 (gen_inlined_subroutine_die): Likewise.
1401 (gen_block_die): Likewise.
1402 * tree.c (block_ultimate_origin): Likewise.
1403 * tree-pretty-print.c (dump_block_node): Remove code dealing
1404 with BLOCK_ABSTRACT.
1405 * tree-ssa-live.c (dump_scope_block): Likewise.
1406 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
1407 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
1409 2018-10-05 Richard Biener <rguenther@suse.de>
1411 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
1412 is asked for initialize mode to the component mode of the
1415 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
1418 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
1419 assembler for -mavx.
1420 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
1422 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
1425 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
1427 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
1428 to be DImode. When using mffscrn, force the operand to a register.
1430 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
1432 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
1433 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
1434 X87MODEF mode iterator.
1435 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
1436 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
1437 X87MODEF mode iterator.
1439 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
1441 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
1442 -Wno-prio-ctor-dtor.
1444 2018-10-04 David Malcolm <dmalcolm@redhat.com>
1446 * Makefile.in (OBJS): Add opt-problem.o.
1447 * dump-context.h: Include "selftest.h.
1448 (selftest::temp_dump_context): New forward decl.
1449 (class dump_context): Make friend of class
1450 selftest::temp_dump_context.
1451 (dump_context::dump_loc_immediate): New decl.
1452 (class dump_pretty_printer): Move here from dumpfile.c.
1453 (class temp_dump_context): Move to namespace selftest.
1454 (temp_dump_context::temp_dump_context): Add param
1455 "forcibly_enable_dumping".
1456 (selftest::verify_dumped_text):
1457 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
1458 (selftest::verify_item):
1459 (ASSERT_IS_TEXT): Move here from dumpfile.c.
1460 (ASSERT_IS_TREE): Likewise.
1461 (ASSERT_IS_GIMPLE): Likewise.
1462 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
1464 (dump_context::dump_loc_immediate): ...this new function.
1465 (class dump_pretty_printer): Move to dump-context.h.
1466 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
1467 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
1468 (temp_dump_context::temp_dump_context): Move to "selftest"
1469 namespace. Add param "forcibly_enable_dumping", and use it to
1470 conditionalize the use of m_pp;
1471 (selftest::verify_dumped_text): Make non-static.
1472 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
1473 (selftest::verify_item): Make non-static.
1474 (ASSERT_IS_TEXT): Move to dump-context.h.
1475 (ASSERT_IS_TREE): Likewise.
1476 (ASSERT_IS_GIMPLE): Likewise.
1477 (selftest::test_capture_of_dump_calls): Pass "true" for new
1478 param of temp_dump_context.
1479 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
1480 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
1482 * opt-problem.cc: New file.
1483 * opt-problem.h: New file.
1484 * optinfo-emit-json.cc
1485 (selftest::test_building_json_from_dump_calls): Pass "true" for
1486 new param of temp_dump_context.
1487 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
1488 (optinfo::emit_for_opt_problem): New function.
1489 (optinfo::emit): Clarity which emit_item is used.
1490 * optinfo.h (optinfo::get_dump_location): New accessor.
1491 (optinfo::emit_for_opt_problem): New decl.
1492 (optinfo::emit): Make const.
1493 * selftest-run-tests.c (selftest::run_tests): Call
1494 selftest::opt_problem_cc_tests.
1495 * selftest.h (selftest::opt_problem_cc_tests): New decl.
1496 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
1497 bool to opt_result, converting fprintf messages to
1498 opt_result::failure_at calls. Add "stmt" param for use by the
1500 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
1501 (runtime_alias_check_p): Convert return type from bool to
1502 opt_result, converting dump_printf calls to
1503 opt_result::failure_at, using the statement DDR_A for their
1505 (find_data_references_in_stmt): Convert return type from bool to
1506 opt_result, converting "return false" to opt_result::failure_at
1508 * tree-data-ref.h: Include "opt-problem.h".
1509 (dr_analyze_innermost): Convert return type from bool to opt_result,
1510 and add a const gimple * param.
1511 (find_data_references_in_stmt): Convert return type from bool to
1513 (runtime_alias_check_p): Likewise.
1514 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
1515 dr_analyze_innermost.
1516 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
1517 Convert return type from bool to opt_result, adding a message for
1518 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
1519 (vect_analyze_data_ref_dependence): Convert return type from bool
1520 to opt_result. Change sense of return type from "false"
1521 effectively meaning "no problems" to "false" meaning a problem,
1522 so that "return false" becomes "return opt_result::success".
1523 Convert "return true" calls to opt_result::failure_at, using
1524 the location of statement A rather than vect_location.
1525 (vect_analyze_data_ref_dependences): Convert return type from bool
1527 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
1528 calls to opt_result::failure_at, using the stmt location rather
1530 (vect_verify_datarefs_alignment): Convert return type from bool
1532 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
1533 into multiple more-tightly-scoped copies.
1534 (vect_analyze_data_refs_alignment): Convert return type from bool
1536 (vect_analyze_data_ref_accesses): Likewise, converting a
1537 "return false" to a "return opt_result::failure_at", adding a
1539 (vect_prune_runtime_alias_test_list): Convert return type from
1540 bool to opt_result, converting dump_printf_loc to
1541 opt_result::failure_at. Add a %G to show the pertinent statement,
1542 and use the stmt's location rather than vect_location.
1543 (vect_find_stmt_data_reference): Convert return type from
1544 bool to opt_result, converting dump_printf_loc to
1545 opt_result::failure_at, using stmt's location.
1546 (vect_analyze_data_refs): Convert return type from bool to
1547 opt_result. Convert "return false" to "return
1548 opt_result::failure_at", adding messages as needed.
1549 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
1550 type from bool to opt_result.
1551 (vect_determine_vf_for_stmt): Likewise.
1552 (vect_determine_vectorization_factor): Likewise, converting
1553 dump_printf_loc to opt_result::failure_at, using location of phi
1554 rather than vect_location.
1555 (vect_analyze_loop_form_1): Convert return type from bool to
1556 opt_result, converting dump_printf_loc calls, retaining the use of
1558 (vect_analyze_loop_form): Convert return type from loop_vec_info
1559 to opt_loop_vec_info.
1560 (vect_analyze_loop_operations): Convert return type from bool to
1561 opt_result, converting dump_printf_loc calls, using the location
1562 of phi/stmt rather than vect_location where available. Convert
1563 various "return false" to "return opt_result::failure_at" with
1564 "unsupported phi" messages.
1565 (vect_get_datarefs_in_loop): Convert return type from bool to
1566 opt_result. Add a message for the
1567 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
1568 (vect_analyze_loop_2): Convert return type from bool to
1569 opt_result. Ensure "ok" is set to a opt_result::failure_at before
1570 each "goto again;", adding new messages where needed.
1571 Add "unsupported grouped {store|load}" messages.
1572 (vect_analyze_loop): Convert return type from loop_vec_info to
1574 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
1576 * tree-vect-stmts.c (process_use): Likewise, converting
1577 dump_printf_loc call and using stmt location, rather than
1579 (vect_mark_stmts_to_be_vectorized): Likeise.
1580 (vect_analyze_stmt): Likewise, adding a %G.
1581 (vect_get_vector_types_for_stmt): Convert return type from bool to
1582 opt_result, converting dump_printf_loc calls and using stmt
1583 location, rather than vect_location.
1584 (vect_get_mask_type_for_stmt): Convert return type from tree to
1585 opt_tree, converting dump_printf_loc calls and using stmt location.
1586 * tree-vectorizer.c: Include "opt-problem.h.
1587 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
1588 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
1589 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
1590 enabled, use it to report at the top level "couldn't vectorize
1591 loop" followed by the problem.
1592 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
1593 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
1595 (vect_analyze_stmt): Likewise.
1596 (vect_get_vector_types_for_stmt): Likewise.
1597 (tree vect_get_mask_type_for_stmt): Likewise.
1598 (vect_analyze_data_ref_dependences): Likewise.
1599 (vect_enhance_data_refs_alignment): Likewise.
1600 (vect_analyze_data_refs_alignment): Likewise.
1601 (vect_verify_datarefs_alignment): Likewise.
1602 (vect_analyze_data_ref_accesses): Likewise.
1603 (vect_prune_runtime_alias_test_list): Likewise.
1604 (vect_find_stmt_data_reference): Likewise.
1605 (vect_analyze_data_refs): Likewise.
1606 (vect_analyze_loop): Convert return type from loop_vec_info to
1608 (vect_analyze_loop_form): Likewise.
1609 (vect_analyze_slp): Convert return type from bool to opt_result.
1611 2018-10-04 David Malcolm <dmalcolm@redhat.com>
1613 * doc/invoke.texi (-fopt-info): Document new "internals"
1615 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
1616 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
1618 (optinfo_verbosity_options): Add "internals".
1619 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
1620 (dump_context::apply_dump_filter_p): New member function.
1621 (dump_context::dump_loc): Use apply_dump_filter_p rather than
1622 explicitly masking the dump_kind.
1623 (dump_context::begin_scope): Increment the scope depth first. Use
1624 apply_dump_filter_p rather than explicitly masking the dump_kind.
1625 (dump_context::emit_item): Use apply_dump_filter_p rather than
1626 explicitly masking the dump_kind.
1627 (dump_dec): Likewise.
1628 (dump_hex): Likewise.
1629 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
1630 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
1631 (opt_info_switch_p): Update handling of default
1632 MSG_OPTIMIZED_LOCATIONS to cope with default of
1633 MSG_PRIORITY_USER_FACING.
1634 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
1635 masking the dump_kind.
1636 (selftest::test_capture_of_dump_calls): Update test_dump_context
1637 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
1638 than MSG_ALL. Generalize scope test to be run at all four
1639 combinations of with/without MSG_PRIORITY_USER_FACING and
1640 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
1641 for each of the two values.
1642 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
1643 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
1644 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
1645 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
1646 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
1647 with MSG_PRIORITY_*.
1648 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
1649 dump messages as MSG_PRIORITY_USER_FACING.
1650 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
1651 about the interaction with MSG_PRIORITY_*.
1653 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
1655 * varasm.c (output_constant): Add new parameter merge_strings.
1656 Make strings properly zero terminated in merge string sections.
1657 (mergeable_string_section): Don't fail if the last char is non-zero.
1658 (assemble_variable_contents): Handle merge string sections.
1659 (assemble_variable): Likewise.
1660 (assemble_constant_contents): Likewise.
1661 (output_constant_def_contents): Likewise.
1662 (output_constructor_array_range,
1663 output_constructor_regular_field): Adjust call to output_constant.
1664 (output_object_block): Adjust call to assemble_constant_contents
1665 and assemble_variable_contents.
1667 2018-10-04 Martin Liska <mliska@suse.cz>
1670 * cgraphunit.c (process_function_and_variable_attributes):
1671 Warn about a function with alias attribute and a body.
1673 2018-10-04 Martin Liska <mliska@suse.cz>
1676 * multiple_target.c (redirect_to_specific_clone): New function.
1677 (ipa_target_clone): Use it.
1678 * tree-inline.c: Fix comment.
1680 2018-10-04 David Malcolm <dmalcolm@redhat.com>
1682 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
1684 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
1685 (gcc::dump_manager::register_pass): New member function, adapted
1686 from loop body in gcc::pass_manager::register_pass, adding a
1687 call to update_dfi_for_opt_info.
1688 (gcc::dump_manager::opt_info_enable_passes): Store the
1689 -fopt-info options into the new fields. Move the loop
1691 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
1693 * dumpfile.h (struct opt_pass): New forward decl.
1694 (gcc::dump_manager::register_pass): New decl.
1695 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
1696 (class gcc::dump_manager): Add fields "m_optgroup_flags",
1697 "m_optinfo_flags", and "m_optinfo_filename".
1698 * passes.c (gcc::pass_manager::register_pass): Move all of the
1699 dump-handling code to gcc::dump_manager::register_pass.
1701 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
1703 PR rtl-optimization/87466
1704 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
1705 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
1706 * doc/tm.texi: Regenerate.
1707 * ira-lives.c (process_bb_node_lives): Use the new target hook.
1708 * lra-lives.c (process_bb_lives): Likewise.
1709 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
1712 2018-10-04 Tamar Christina <tamar.christina@arm.com>
1714 * params.c (add_params): Fix initialization.
1716 2018-10-04 Martin Liska <mliska@suse.cz>
1718 PR gcov-profile/84107
1719 * tree-profile.c (init_ic_make_global_vars):
1720 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
1721 Come up with new ic_tuple* variables. Emit
1722 __gcov_indirect_call{,_topn} variables.
1723 (gimple_gen_ic_profiler): Access the variable
1725 (gimple_gen_ic_func_profiler): Access
1726 __gcov_indirect_call.callee field.
1727 (gimple_init_gcov_profiler): Use ptr_type_node.
1728 * value-prof.c (gimple_ic): Use ptr_type_node.
1730 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1732 PR tree-optimization/85787
1733 * ipa-pure-const.c (malloc_candidate_p_1): Move most of malloc_candidate_p
1734 into this function and add support for detecting multiple phis.
1735 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
1737 2018-10-04 Martin Liska <mliska@suse.cz>
1740 * ipa-inline.c (inline_to_all_callers_1):
1741 Call ultimate_alias_target for node being inlined.
1743 2018-10-03 Jeff Law <law@redhat.com>
1745 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
1747 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
1748 * tree.h (get_typenode_from_name): Prototype.
1750 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
1752 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
1753 Change operand 2 predicate to nonimmediate_operand.
1754 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
1756 2018-10-03 Martin Sebor <msebor@redhat.com>
1757 Jeff Law <law@redhat.com>
1759 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
1761 (get_string_length): Detect unterminated arrays.
1762 (format_string): Same.
1763 (format_directive): Warn about unterminated arrays.
1764 (handle_gimple_call): Mark statements with no_warning as needed.
1766 2018-10-03 Jim Wilson <jimw@sifive.com>
1768 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
1769 also define __riscv_abi_rve. Delete trailing white space.
1771 2018-10-03 Paul Koning <ni1d@arrl.net>
1773 Enable LRA register allocator for PDP11.
1774 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
1777 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
1778 * config/pdp11/pdp11.opt (-mlra): New option.
1779 * doc/invoke.texi (PDP-11 Options): Document -mlra.
1781 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
1783 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
1784 (*<absneg:code>extend<mode>xf2): Ditto.
1786 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
1788 PR tree-optimization/87415
1789 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
1792 2018-10-02 Jeff Law <law@redhat.com>
1794 * gimple-fold.c (get_range_strlen): Only set *nonstr when
1795 an unterminated string is discovered. Bubble up range
1796 even for unterminated strings.
1797 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
1798 indicates the string was not terminated via NONSTR.
1800 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
1802 * tree-vrp.c (extract_range_from_unary_expr): Special case all
1803 pointer conversions.
1804 Do not do anything special for anti-ranges.
1806 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
1808 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
1809 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
1811 2018-10-03 Martin Liska <mliska@suse.cz>
1813 PR gcov-profile/86109
1814 * coverage.c (coverage_begin_function): Do not
1815 mark lambdas as artificial.
1816 * tree-core.h (struct GTY): Remove tm_clone_flag
1817 and introduce new lambda_function.
1818 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
1820 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
1823 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
1824 P8_VECTOR and VSX are enabled.
1826 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
1828 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
1829 0x3907 as CPU model number.
1831 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
1833 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
1834 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
1835 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
1836 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
1837 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
1838 * config/s390/s390.md: Likewise. Rename also the cpu attribute
1839 value from arch12 to z14.
1841 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
1843 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
1845 (isinf<mode>2): Ditto.
1847 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
1849 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
1850 before emitting fxam. Perform calculations in XFmode.
1852 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
1854 * match.pd (((X /[ex] A) +- B) * A): New transformation.
1856 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
1859 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
1860 * tree.c (signed_or_unsigned_type_for): Handle complex.
1862 2018-10-02 Jeff Law <law@redhat.com>
1864 * gimple-fold.c (get_range_strlen): Remove dead code.
1866 2018-10-02 Martin Sebor <msebor@redhat.com>
1867 Jeff Law <law@redhat.com>
1869 * builtins.c (unterminated_array): Add new arguments.
1870 If argument is not terminated, bubble up size and exact
1872 (expand_builtin_strnlen): Detect, avoid expanding
1873 and diagnose unterminated arrays.
1874 (c_strlen): Fill in offset of start of unterminated strings.
1875 * builtins.h (unterminated_array): Update prototype.
1877 2018-10-02 Richard Biener <rguenther@suse.de>
1879 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
1880 of haddv4df, first reduce to SSE width and exploit the fact
1881 that we only need element zero with the reduction result.
1882 (reduc_plus_scal_v2df): Likewise.
1884 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
1886 * dojump.h (do_jump): Delete.
1887 (do_jump_1): Likewise.
1888 (split_comparison): Move around.
1889 * dojump.c (do_jump): Make static.
1890 (do_jump_1): Likewise.
1891 (jumpifnot): Move around.
1892 (jumpifnot_1): Likewise.
1894 (jumpif_1): Likewise.
1895 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
1897 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
1899 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
1900 insns in the delay slot and add_insn_after for the jump insn.
1902 2018-10-02 Richard Biener <rguenther@suse.de>
1904 * tree-inline.c (expand_call_inline): Use the location of
1905 the callee declaration for the inline-entry marker.
1906 * final.c (notice_source_line): Remove special-casing of
1907 NOTE_INSN_INLINE_ENTRY.
1909 2018-10-01 Carl Love <cel@us.ibm.com>
1912 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
1913 (__builtin_mtfsb0): New.
1914 (__builtin_mtfsb1): New.
1915 ( __builtin_set_fpscr_rn): New.
1916 (__builtin_set_fpscr_drn): New.
1917 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
1918 (rs6000_expand_set_fpscr_rn_builtin): Add.
1919 (rs6000_expand_set_fpscr_drn_builtin): Add.
1920 (rs6000_expand_builtin): Add case statement entries for
1921 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
1922 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
1923 RS6000_BUILTIN_MFFSL.
1924 (rs6000_init_builtins): Add ftype initialization and def_builtin
1925 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
1926 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
1927 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
1928 rs6000_mffscdrn): Add define_insn.
1929 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
1930 * doc/extend.texi: Add documentation for the builtins.
1932 2018-10-01 Richard Biener <rguenther@suse.de>
1934 PR tree-optimization/87465
1935 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
1936 causing branch miscounts.
1938 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1940 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
1941 aarch64_option_default_param): New.
1942 (params.h): Include.
1943 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
1944 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
1945 stack-clash protection validation code.
1947 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1949 * params.c (validate_param): New.
1950 (add_params): Use it.
1951 (set_param_value): Refactor param validation into validate_param.
1952 (diagnostic.h): Include.
1953 * diagnostic.h (diagnostic_ready_p): New.
1955 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1957 * params.c (set_param_value):
1958 Add index of parameter being validated.
1959 * common/common-target.def (option_validate_param): New.
1960 * common/common-targhooks.h (default_option_validate_param): New.
1961 * common/common-targhooks.c (default_option_validate_param): New.
1962 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
1963 * doc/tm.texi: Regenerate.
1965 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1968 * config/aarch64/aarch64.c (aarch64_override_options_internal):
1969 Add validation for stack-clash parameters and set defaults.
1971 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1974 * configure.ac: Add stack-clash-protection-guard-size.
1975 * doc/install.texi: Document it.
1976 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
1977 * params.def: Update comment for guard-size.
1978 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
1979 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
1980 * configure: Regenerate.
1982 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1985 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
1986 STACK_DYNAMIC_OFFSET): New.
1987 * config/aarch64/aarch64.c (aarch64_layout_frame):
1988 Update outgoing args size.
1989 (aarch64_stack_clash_protection_alloca_probe_range,
1990 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
1992 2018-10-01 Tamar Christina <tamar.christina@arm.com>
1995 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
1997 * target.def (stack_clash_protection_alloca_probe_range): New.
1998 (stack_clash_protection_final_dynamic_probe): Remove.
1999 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
2000 (default_stack_clash_protection_final_dynamic_probe): Remove.
2001 * targhooks.c: Likewise.
2002 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
2003 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
2004 * doc/tm.texi: Regenerate.
2006 2018-10-01 Tamar Christina <tamar.christina@arm.com>
2009 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
2010 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
2011 aarch64_clamp_to_uimm12_shift): New.
2012 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
2013 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
2015 2018-10-01 Tamar Christina <tamar.christina@arm.com>
2018 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
2020 2018-10-01 Jeff Law <law@redhat.com>
2021 Richard Sandiford <richard.sandiford@linaro.org>
2022 Tamar Christina <tamar.christina@arm.com>
2025 * config/aarch64/aarch64.md
2026 (probe_stack_range): Add k (SP) constraint.
2027 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
2028 STACK_CLASH_MAX_UNROLL_PAGES): New.
2029 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
2030 stack probes for stack clash.
2031 (aarch64_allocate_and_probe_stack_space): New.
2032 (aarch64_expand_prologue): Use it.
2033 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
2034 (aarch64_sub_sp): Add emit_move_imm optional param.
2036 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
2038 PR tree-optimization/87261
2039 * match.pd: Remove trailing whitespace.
2040 Add (x & y) | ~(x | y) -> ~(x ^ y),
2041 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
2043 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
2045 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
2047 (ashlsi3_insn): Update instruction constraints.
2048 (ashrsi3_insn): Likewise.
2049 (rotrsi3): Likewise.
2050 (add_shift): Likewise.
2051 * config/arc/constraints.md (Csz): New 32 bit constraint. It
2052 avoids placing in the limm field small constants which, otherwise,
2053 could end into a small instruction.
2055 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
2057 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
2058 destination register is not odd-even.
2059 (umaddsidi4_split): Likewise.
2061 2018-10-01 Richard Biener <rguenther@suse.de>
2063 * tree-inline.c (expand_call_inline): Store origin of fn
2064 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
2065 * tree.c (block_ultimate_origin): Simplify and do some
2068 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
2070 * config/i386/mmx.md (EMMS): New int iterator.
2071 (emms): New int attribute.
2072 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
2073 EMMS int iterator. Explicitly declare clobbers.
2074 (mmx_emms): Remove expander.
2076 * config/i386/predicates.md (emms_operation): Remove predicate.
2077 (vzeroall_pattern): New predicate.
2078 (vzeroupper_pattern): Rename from vzeroupper_operation.
2079 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
2080 vzeroupper_pattern and vzeroall_pattern predicates.
2082 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
2084 PR rtl-optimization/86939
2085 * ira-lives.c (make_hard_regno_born): Rename from this...
2086 (make_hard_regno_live): ... to this. Remove update to conflict
2087 information. Update function comment.
2088 (make_hard_regno_dead): Add conflict information update. Update
2090 (make_object_born): Rename from this...
2091 (make_object_live): ... to this. Remove update to conflict information.
2092 Update function comment.
2093 (make_object_dead): Add conflict information update. Update function
2095 (mark_pseudo_regno_live): Call make_object_live.
2096 (mark_pseudo_regno_subword_live): Likewise.
2097 (mark_hard_reg_dead): Update function comment.
2098 (mark_hard_reg_live): Call make_hard_regno_live.
2099 (process_bb_node_lives): Likewise.
2100 * lra-lives.c (make_hard_regno_born): Rename from this...
2101 (make_hard_regno_live): ... to this. Remove update to conflict
2102 information. Remove now uneeded check_pic_pseudo_p argument.
2103 Update function comment.
2104 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
2105 to conflict information. Update function comment.
2106 (mark_pseudo_live): Remove update to conflict information. Update
2108 (mark_pseudo_dead): Add conflict information update.
2109 (mark_regno_live): Call make_hard_regno_live.
2110 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
2111 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
2113 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
2116 * config/i386/i386.c (construct_container): Use TImode for
2117 BLKmode values in 2 integer registers.
2119 2018-09-29 Jeff Law <law@redhat.com>
2121 * builtins.c (unterminated_array): Pass in c_strlen_data * to
2122 c_strlen rather than just a tree *.
2123 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
2124 Update recursive calls appropriately. If caller did not provide a
2125 suitable data pointer, create a local one. When a non-terminated
2126 string is discovered, bubble up information about the string via the
2127 c_strlen_data object.
2128 * builtins.h (c_strlen): Update prototype.
2129 (c_strlen_data): New structure.
2130 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
2131 For a type 2 call, if c_strlen indicates a non-terminated string
2132 use the length of the non-terminated string.
2133 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
2135 2018-09-29 Jakub Jelinek <jakub@redhat.com>
2138 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
2139 __m512d type for __A argument rather than __m512.
2141 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
2143 * match.pd (simple_comparison): Don't optimize if either operand is
2144 a function pointer when target needs function pointer canonicalization.
2146 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
2148 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
2149 power5 .. power9 to remove indirection.
2150 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
2151 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
2152 ASM_CPU_476_SPEC): Delete.
2153 (ASM_CPU_SPEC): Adjust.
2154 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
2155 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
2157 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
2159 * config.in: Delete HAVE_AS_DCI.
2160 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
2161 * config/rs6000/rs6000.h: Ditto.
2162 * configure.ac: Delete HAVE_AS_DCI.
2163 * configure: Regenerate.
2165 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
2167 * config.in (HAVE_AS_LWSYNC): Delete.
2168 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
2169 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
2171 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
2172 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
2174 * configure.ac: Delete HAVE_AS_LWSYNC.
2175 * configure: Regenerate.
2177 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
2178 Pierre-Marie de Rodat <derodat@adacore.com>
2180 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
2181 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
2182 (cgraph_node::create_thunk): Add indirect_offset parameter.
2183 (thunk_adjust): Likewise.
2184 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
2185 and initialize the corresponding field with it.
2186 (cgraph_node::dump): Dump indirect_offset field.
2187 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
2188 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
2189 (thunk_adjust): Add indirect_offset parameter and deal with it.
2190 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
2191 pass it to thunk_adjust. Do not call the target hook if it's non-zero
2192 or if the thunk is external or local. Fix formatting. Do not chain
2193 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
2194 if any, in the GIMPLE representation.
2195 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
2196 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
2197 (input_node): Read indirect_offset field.
2198 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
2199 call to thunk_adjust.
2200 * tree-nested.c (struct nesting_info): Add thunk_p field.
2201 (create_nesting_tree): Set it.
2202 (convert_all_function_calls): Copy static chain from targets to thunks.
2203 (finalize_nesting_tree_1): Return early for thunks.
2204 (unnest_nesting_tree_1): Do not finalize thunks.
2205 (gimplify_all_functions): Do not gimplify thunks.
2207 2018-09-28 David Malcolm <dmalcolm@redhat.com>
2209 * opt-suggestions.c (option_proposer::build_option_suggestions):
2210 Release "option_values".
2212 2018-09-28 David Malcolm <dmalcolm@redhat.com>
2214 * coverage.c (get_coverage_counts): Convert problem-reporting dump
2215 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
2216 * dumpfile.c (kind_as_string): New function.
2217 (dump_loc): Rather than a hardcoded prefix of "note: ", use
2218 kind_as_string to vary the prefix based on dump_kind.
2219 (selftest::test_capture_of_dump_calls): Update for above.
2221 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
2223 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
2224 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
2226 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
2228 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
2229 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
2230 INVALID_REGNUM instead of FPSR_REG.
2231 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
2232 * config/i386/i386.md: Update comment of FP compares.
2233 (fldenv): Do not clobber FPSR_REG.
2235 2018-09-28 Richard Biener <rguenther@suse.de>
2237 * tree.h (BLOCK_ORIGIN): New.
2238 * omp-expand.c (grid_expand_target_grid_body): Assign
2239 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
2240 * tree-inline.c (remap_block): Likewise.
2241 * auto-profile.c (get_function_decl_from_block): Simplify
2242 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
2243 * langhooks.c (lhd_print_error_function): Likewise.
2244 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
2246 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
2247 * tree.c (block_nonartificial_location): Likewise.
2248 (block_ultimate_origin): Likewise.
2249 * tree-pretty-print.c (percent_K_format): Likewise. Remove
2250 no longer needed LTO case.
2252 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
2253 Jan Hubicka <jh@suse.cz>
2254 Martin Jambor <mjambor@suse.cz>
2256 * simplify-rtx.c (simplify_merge_mask): New function.
2257 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
2258 same masks are used in op1 or op2.
2259 (test_vec_merge): New function.
2260 (test_vector_ops): Call test_vec_merge.
2262 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
2264 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
2265 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
2266 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
2267 (cypress_costs): Set it.
2268 (supersparc_costs): Likewise.
2269 (hypersparc_costs): Likewise.
2270 (leon_cost): Likewise.
2271 (leon3_costs): Likewise.
2272 (sparclet_costs): Likewise.
2273 (ultrasparc_costs): Likewise.
2274 (ultrasparc_costs): Likewise.
2275 (niagara_costs): Likewise.
2276 (niagara2_costs): Likewise.
2277 (niagara3_costs): Likewise.
2278 (niagara4_costs): Likewise.
2279 (niagara7_costs): Likewise.
2280 (m8_costs): Likewise.
2281 (TARGET_CAN_FOLLOW_JUMP): Define.
2282 (pass_work_around_errata::gate): Minor tweak.
2283 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
2284 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
2285 Automaitcally clear MASK_FSMULD mask for V7 processors.
2286 (sparc_can_follow_jump): New static function.
2287 (output_ubranch): Deal with CROSSING_JUMP_P.
2288 (sparc_use_sched_lookahead): Rewrite using switch statement.
2289 (sparc_issue_rate): Reorder.
2290 (sparc_branch_cost): New function.
2292 2018-09-27 Martin Sebor <msebor@redhat.com>
2294 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
2295 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
2296 (int_fits_type_p): Same.
2298 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
2300 * config/i386/i386.md (FPCR_REG): Remove.
2301 (UNSPEC_FLDCW): Remove.
2302 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
2303 (x86_fldcw_1): Remove insn pattern.
2304 (fnstenv): Do not clobber FPCR_REG.
2306 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
2307 (CALL_USED_REGISTERS): Ditto.
2308 (REG_ALLOC_ORDER): Ditto.
2309 (REG_CLASS_CONTENTS): Ditto.
2310 (HI_REGISTER_NAMES): Ditto.
2311 (ADDITIONAL_REGISTER_NAMES): Use defines instead
2312 of numerical constants.
2313 * config/i386/i386.c (regclass_map): Remove fpsr register.
2314 (dbx_register_map): Ditto.
2315 (dbx64_register_map): Ditto.
2316 (svr4_dbx_register_map): Ditto.
2317 (print_reg): Do not handle FPCR_REG.
2319 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
2322 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
2323 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
2324 Delete, always treat as true.
2325 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
2326 Ditto. Simplify remaining code.
2327 * config/powerpcspe/powerpcspe.h: Ditto.
2328 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
2329 Simplify remaining code.
2330 (rs6000_expand_builtin): Ditto.
2331 * config/rs6000/rs6000.h: Ditto.
2332 * configure.ac: Ditto.
2333 * configure: Regenerate.
2335 2018-09-27 Martin Liska <mliska@suse.cz>
2337 * coverage.c (get_coverage_counts): Revert the formatting
2338 of missing profile opt info.
2340 2018-09-27 Richard Biener <rguenther@suse.de>
2344 * dwarf2out.c (set_block_origin_self): Do not mark outermost
2345 block as we do not output that.
2346 (gen_inlined_subroutine_die): Elide the originally outermost
2347 block, matching what we do for concrete instances.
2348 (decls_for_scope): Add parameter specifying whether to recurse
2351 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
2352 Tom de Vries <tom@codesourcery.com>
2356 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
2357 STORE_FLAG_VALUE == 1.
2359 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
2361 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
2362 constant definitions.
2363 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
2364 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
2365 ("speculation_barrier"): New expander definition.
2367 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
2369 PR gcov-profile/86957
2370 * common.opt: New warning option -Wmissing-profile.
2371 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
2372 * doc/invoke.texi: Document -Wmissing-profile.
2374 2018-09-26 Jim Wilson <jimw@sifive.com>
2376 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
2377 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
2379 2018-09-26 Martin Sebor <msebor@redhat.com>
2381 * tree.c (zerop): Change return type to bool.
2382 (integer_zerop, integer_onep, integer_each_onep): Same.
2383 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
2384 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
2385 (real_onep, real_minus_onep, chain_index): Same.
2386 (print_type_hash_statistics, type_list_equal): Same.
2387 * tree.h (zerop): Same.
2388 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
2389 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
2390 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
2391 (real_onep, real_minus_onep, chain_index): Same.
2392 (print_type_hash_statistics, type_list_equal): Same.
2394 2018-09-26 Jim Wilson <jimw@sifive.com>
2396 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
2398 2018-09-26 Jakub Jelinek <jakub@redhat.com>
2401 * config/i386/i386.c: Include debug.h and dwarf2out.h.
2402 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
2405 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
2407 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
2409 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
2411 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
2412 and FP_SECOND_SSE_REGS.
2413 (REG_CLASS_NAMES): Ditto.
2414 (REG_CLASS_CONTENTS): Ditto.
2415 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
2416 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
2417 (ix86_preferred_output_reload_class): Ditto.
2418 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
2419 clobber constraint to "=&f".
2420 (fix_truncdi_i387): Ditto.
2421 (lrintxfdi2): Ditto.
2422 (fistdi2_<rounding>): Ditto.
2423 (fpremxf4_i387): Change "=u" constraint to "=f".
2424 (fprem1xf4_i387): Ditto.
2426 (fptanxf4_i387): Ditto.
2427 (fxtractxf3_i387): Ditto.
2428 (fscalexf4_i387): Ditto.
2429 (atan2xf3): Change "u" constraint to "f".
2430 (fyl2xxf3_i387): Ditto.
2431 (fyl2xp1xf3_i387): Ditto.
2433 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
2436 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
2437 for removed I387_MASK_PM entity.
2440 2018-09-26 Jeff Law <law@redhat.com>
2442 2018-09-26 Alexey Neyman <stilor@att.net>
2444 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
2445 headers are no longer pulled in by <isl/val.h>.
2447 2018-09-26 Richard Biener <rguenther@suse.de>
2450 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
2451 or concrete instance DIE to the tree. Create abstract origin
2452 attributes also for concrete instances.
2454 2018-09-26 Alexey Neyman <stilor@att.net>
2456 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
2457 headers are no longer pulled in by <isl/val.h>.
2459 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
2461 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
2462 Use new helper functions.
2463 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
2464 Use new helper functions.
2465 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
2466 aarch_mm_needs_release): New declarations.
2467 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
2468 aarch_mm_needs_release): New.
2470 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
2472 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
2473 (arm32_output_mi_thunk): Deal with long calls.
2475 2018-09-26 Richard Biener <rguenther@suse.de>
2479 * tree-inline.c (expand_call_inline): When the location
2480 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
2481 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
2482 the inserted BLOCK to make inlined_function_outer_scope_p
2484 * dwarf2out.c (add_call_src_coords_attributes): Do not add
2485 coords for reserved locations.
2487 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
2489 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
2490 (*call_indirect_nonlocal_sysv<mode>): Ditto.
2491 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
2492 (*sibcall_nonlocal_sysv<mode>): Ditto.
2493 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
2494 (<bd>_<mode>): Ditto.
2495 (<bd>tf_<mode>): Ditto.
2497 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
2499 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
2500 control string as a list of templates instead of as C code.
2501 (*altivec_movti): Ditto.
2502 * config/rs6000/darwin.md (movdf_low_di): Ditto.
2504 2018-09-25 Jim Wilson <jimw@sifive.com>
2506 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
2507 when target symbol is weak.
2509 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
2512 * builtins.c (unterminated_array): Simplify.
2513 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
2514 where pointer arithmetic is safe.
2516 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
2519 * config/rs6000/altivec.md (altivec_vspltb): Use
2520 const_0_to_15_operand instead of u5bit_cint_operand.
2521 (*altivec_vspltb_internal): Ditto.
2522 (altivec_vspltb_direct): Ditto.
2523 (altivec_vsplth): Use const_0_to_7_operand instead of
2525 (*altivec_vsplth_internal): Ditto.
2526 (altivec_vsplth_direct): Ditto.
2527 (altivec_vspltw): Use const_0_to_3_operand instead of
2529 (*altivec_vspltw_internal): Ditto.
2530 (altivec_vspltw_direct): Ditto.
2531 (altivec_vspltsf): Ditto.
2532 (*altivec_vspltsf_internal): Ditto.
2533 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
2534 various splats with the proper size immediate. Reorder the various
2535 cases by ascending size of immediate, and put all such together.
2537 2018-09-25 Richard Biener <rguenther@suse.de>
2540 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
2542 (maybe_create_die_with_external_ref): Do not create
2543 DW_TAG_imported_unit here.
2544 (add_abstract_origin_attribute): Handle external BLOCK refs.
2545 (dwarf2out_abstract_function): Simplify LTO case.
2546 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
2547 rather than using maybe_create_die_with_external_ref.
2549 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
2552 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
2553 (frndintxf2_mask_pm_i387): Ditto.
2554 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
2555 Enable for !flag_trapping_math.
2556 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
2557 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
2558 Change operand 1 predicate to nonimmediate_operand.
2559 (attr "i387_cw"): Remove mask_pm.
2560 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
2561 (enum ix86_entity): Remove I387_MASK_PM.
2562 * config/i386/i386.c (ix86_i387_mode_needed): Do not
2563 handle I387_MASK_PM.
2564 (ix86_mode_needed): Ditto.
2565 (ix86_mode_after): Ditto.
2566 (ix86_mode_entry): Ditto.
2567 (ix86_mode_exit): Ditto.
2568 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
2570 2018-09-25 Jakub Jelinek <jakub@redhat.com>
2572 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
2573 to_update_switch_stmts to vNULL instead of calling create on them
2576 2018-09-25 Richard Biener <rguenther@suse.de>
2578 PR tree-optimization/87402
2579 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
2580 (visit_phi): Re-instantiate handling of supposed to be VARYING
2581 but non-VARYING backedge value.
2583 2018-09-25 Richard Biener <rguenther@suse.de>
2586 * dwarf2out.c (struct sym_off_pair): New.
2587 (external_die_map): New global.
2588 (lookup_decl_die): When in LTO create DIEs lazily from the
2590 (lookup_block_die): New function, create DIEs lazily in LTO.
2591 (equate_block_to_die): New function.
2592 (dwarf2out_die_ref_for_decl): During WPA get the association
2593 from the external DIE map.
2594 (dwarf2out_register_external_die): Record mapping into the
2596 (maybe_create_die_with_external_ref): New function split out from
2597 DIE generation part of old dwarf2out_register_external_die.
2598 (add_abstract_origin_attribute): Do not return the DIE. When
2599 in LTO reference externals directly.
2600 (dwarf2out_abstract_function): When in LTO ignore calls for
2601 decls with external DIEs (already present abstract instances).
2602 (gen_call_site_die): Adjust.
2603 (add_high_low_attributes): Likewise.
2604 (gen_lexical_block_die): Likewise.
2605 (gen_inlined_subroutine_die): Likewie.
2606 (gen_block_die): Likewise.
2607 (dwarf2out_inline_entry): Likewise.
2608 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
2611 2018-09-25 Martin Liska <mliska@suse.cz>
2613 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
2614 integers and not by a float value.
2616 2018-09-25 Martin Liska <mliska@suse.cz>
2619 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
2621 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
2622 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
2623 * godump.c (go_format_type): Remove extra parenthesis.
2625 2018-09-25 Martin Liska <mliska@suse.cz>
2627 * alias.c (set_dest_equal_p): Remove unused function.
2628 * config/i386/i386.c (def_builtin_pure2): Likewise.
2629 * diagnostic-show-locus.c (class layout): Remove
2631 (layout::layout): Likewise here.
2632 * dump-context.h (class temp_dump_context): Likewise.
2633 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
2634 (add_AT_loclistsptr): Likewise.
2635 (add_AT_offset): Likewise.
2636 (get_AT_hi_pc): Likewise.
2637 (is_comdat_die): Likewise.
2638 (type_is_enum): Likewise.
2639 (ceiling): Likewise.
2640 (add_AT_vms_delta): Likewise.
2641 (is_class_die): Likewise.
2642 * edit-context.c (class line_event): Remove unused field.
2643 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
2645 * ipa-cp.c (ipa_get_vr_lat): Likewise.
2646 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
2647 (ok_for_base_p_nonstrict): Likewise.
2648 * tree-chrec.c (is_not_constant_evolution): Likewise.
2649 (chrec_fold_poly_cst): Likewise.
2650 * tree-if-conv.c (has_pred_critical_p): Likewise.
2651 * tree-ssa-coalesce.c (print_exprs): Likewise.
2652 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
2653 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
2654 * tree-vrp.c (value_ranges_intersect_p): Likewise.
2655 (value_range_nonnegative_p): Likewise.
2657 2018-09-25 Martin Liska <mliska@suse.cz>
2659 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
2660 Do not handle "GNU Pascal".
2661 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
2663 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
2664 from documentation. Likewise.
2665 * dbxout.c (dbxout_range_type): Likewise.
2666 * doc/cpp.texi: Likewise.
2667 * doc/extend.texi: Likewise.
2668 * doc/frontends.texi: Likewise.
2669 * doc/invoke.texi: Remove Pascal entry.
2670 * tree.def (CLEANUP_POINT_EXPR): Likewise.
2671 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
2673 2018-09-25 Martin Liska <mliska@suse.cz>
2676 * doc/invoke.texi: Document all parameters and remove default
2679 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
2682 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
2683 contains HOST_WIDE_INTs when computing its size.
2685 2018-09-24 Jim Wilson <jimw@sifive.com>
2688 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
2690 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
2692 2018-09-24 Andrew Pinski <apinski@marvell.com>
2694 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
2695 access prev before checking it for NULLness in the
2696 AARCH64_FUSE_CMP_BRANCH case.
2698 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
2701 * config/i386/i386.c (rest_of_insert_endbranch): Set
2702 endbr_queued_at_entrance to true and don't insert ENDBR if
2703 x86_function_profiler will be called.
2704 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
2706 * config/i386/i386.h (machine_function): Add
2707 endbr_queued_at_entrance.
2709 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
2711 * genattrtab.c (mk_attr_alt): Use alternative_mask.
2712 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
2714 (check_attr_test): Use alternative_mask.
2715 (get_attr_value): Likewise.
2716 (compute_alternative_mask): Use alternative_mask and XWINT.
2717 (make_alternative_compare): Use alternative_mask.
2718 (attr_alt_subset_p): Use XWINT.
2719 (attr_alt_subset_of_compl_p): Likewise.
2720 (attr_alt_intersection): Use alternative_mask and XWINT.
2721 (attr_alt_union): Likewise.
2722 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
2723 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
2724 (simplify_test_exp): Use alternative_mask and XWINT.
2725 (write_test_expr): Use alternative_mask and XWINT, adjust bit
2726 number calculation to support 64 bits. Generate code that
2727 checks 64-bit masks.
2728 (main): Use alternative_mask.
2729 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
2731 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
2734 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
2735 RETURN+USE when returning via %r14.
2737 2018-09-24 Martin Liska <mliska@suse.cz>
2739 * gcov.c (output_lines): Print colorization legend
2740 for both flag_use_colors and flag_use_hotness_colors.
2743 2018-09-24 Martin Liska <mliska@suse.cz>
2745 * coverage.c (get_coverage_counts): Use warning_at
2746 with current_function_decl location. Use %qD in warning
2749 2018-09-24 Martin Liska <mliska@suse.cz>
2751 * memory-block.h (memory_block_pool::release): Annotate with
2752 valgrind that the memory is not accessible.
2754 2018-09-24 Martin Liska <mliska@suse.cz>
2757 * asan.c: Make asan_handled_variables extern.
2759 * cfgexpand.c (expand_stack_vars): Make sure
2760 a representative is unpoison if another
2761 variable in the partition is handled by
2762 use-after-scope sanitization.
2764 2018-09-24 Richard Biener <rguenther@suse.de>
2766 PR tree-optimization/63155
2767 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
2768 the worklist when the edge of the respective argument isn't
2771 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
2773 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
2774 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
2775 (MASK_CLASS_P): Update for rename.
2776 (MAYBE_MASK_CLASS_P): Ditto.
2777 (REG_CLASS_NAMES): Update.
2778 (REG_CLASS_CONTENT): Update.
2779 * config/i386/i386.c (regclass_map): Update for MASK_REG
2780 and ALL_MASK_REGS rename.
2781 * config/i386/constraints.md (Yk): Update for rename.
2784 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
2786 * config/i386/i386.h (enum reg_class): Remove
2787 EVEX_SSE_REGS and MOD4_SSE_REGS.
2788 (REG_CLASS_NAMES): Update.
2789 (REG_CLASS_CONTENT): Update.
2790 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
2791 registers as ALL_SSE_REGS.
2792 (ix86_additional_allocno_class_p): Remove.
2793 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
2794 (ix86_register_priority): Lower priority of EVEX SSE registers.
2795 Use IN_RANGE macro where appropriate.
2796 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
2797 AVX-5124VNNIW checks.
2798 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
2799 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
2800 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
2801 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
2802 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
2803 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
2804 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
2805 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
2806 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
2807 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
2808 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
2809 * config/i386/constraints.md (Yh): Remove.
2811 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
2813 * config/i386/i386.c (regclass_map): Declare integer REX registers
2816 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
2818 * doc/service.texi (Service): Switch the fsf.org link to https.
2820 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
2823 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
2824 Define to speculation_safe_value_not_needed.
2826 2018-09-21 Florian Weimer <fweimer@redhat.com>
2829 * doc/extend.texi (Common Function Attributes): Mention that
2830 noreturn suppresses tail call optimization.
2832 2018-09-21 Jeff Law <law@redhat.com>
2834 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
2835 vr_values::cleanup_edges_and_switches.
2836 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
2838 (identify_jump_threads): Remove EDGE_IGNORE handling.
2839 (execute_vrp): Move handling of to_remove_edges and
2840 to_update_switch_stmts into vr_values class member functions.
2841 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
2842 (to_update_switch_stmts): Likewise.
2843 * vr-values.c: Include cfghooks.h.
2844 (vr_values::vr_values): Initialize to_remove_edges and
2845 to_update_switch_stmts.
2846 (vr_values::~vr_values): Verify to_remove_edges and
2847 to_update_switch_stmts are empty.
2848 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
2849 (vr_values::cleanup_edges_and_switches): New member function.
2850 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
2851 function. Add new data members.
2853 2018-09-21 David Malcolm <dmalcolm@redhat.com>
2855 PR tree-optimization/87309
2856 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
2857 calls with pflags and alt_flags.
2858 (selftest::test_capture_of_dump_calls): Add test of interaction of
2859 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
2861 2018-09-21 Olivier Hainque <hainque@adacore.com>
2863 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
2865 2018-09-21 Olivier Hainque <hainque@adacore.com>
2867 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
2869 2018-09-21 Olivier Hainque <hainque@adacore.com>
2871 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
2872 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
2873 (VXWORKS_LIBS_RTP): Minor reordering.
2875 2018-09-21 Olivier Hainque <hainque@adacore.com>
2877 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
2878 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
2880 2018-09-21 Olivier Hainque <hainque@adacore.com>
2882 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
2883 (PTRDIFF_TYPE): Likewise.
2885 2018-09-21 Olivier Hainque <hainque@adacore.com>
2887 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
2888 triplet, similar to support for VxWorks7.
2889 * config/vxworks-dummy.h: Provide a default definition
2890 of TARGET_VXWORKS64 to 0.
2892 2018-09-21 Olivier Hainque <hainque@adacore.com>
2894 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
2895 * config/vxworks-dummy.h: here.
2897 2018-09-21 Olivier Hainque <hainque@adacore.com>
2899 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
2901 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
2902 Bo Zhou <zbo.zhou@hisilicon.com>
2904 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
2905 * config/aarch64/aarch64-tune.md: Regenerated.
2906 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
2907 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
2908 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
2910 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
2911 Julian Brown <julian@codesourcery.com>
2913 * builtins.c (get_builtin_sync_mem): Handle address spaces.
2915 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2917 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
2918 if the call takes a static chain.
2920 2018-09-21 Martin Liska <mliska@suse.cz>
2922 * auto-profile.c (autofdo_source_profile::read): Do not
2924 (read_profile): Do not add working sets.
2925 (read_autofdo_file): Remove sum_all.
2926 (afdo_callsite_hot_enough_for_early_inline): Remove const
2928 * coverage.c (struct counts_entry): Remove gcov_summary.
2929 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
2930 do not support GCOV_TAG_PROGRAM_SUMMARY.
2931 (get_coverage_counts): Remove summary and expected
2933 * coverage.h (get_coverage_counts): Likewise.
2934 * doc/gcov-dump.texi: Remove -w option.
2935 * gcov-dump.c (dump_working_sets): Remove.
2936 (main): Do not support '-w' option.
2937 (print_usage): Likewise.
2938 (tag_summary): Likewise.
2939 * gcov-io.c (gcov_write_summary): Do not dump
2941 (gcov_read_summary): Likewise.
2942 (gcov_histo_index): Remove.
2943 (gcov_histogram_merge): Likewise.
2944 (compute_working_sets): Likewise.
2945 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
2947 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
2948 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
2949 (GCOV_HISTOGRAM_SIZE): Remove.
2950 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
2951 (struct gcov_summary): Simplify rapidly just
2952 to runs and sum_max fields.
2953 (gcov_histo_index): Remove.
2954 (NUM_GCOV_WORKING_SETS): Likewise.
2955 (compute_working_sets): Likewise.
2956 * gcov-tool.c (print_overlap_usage_message): Remove
2957 trailing empty line.
2958 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
2959 (output_lines): Remove program related line.
2960 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
2961 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
2963 (input_profile_summary): Do not read it.
2964 (merge_profile_summaries): And do not merge it.
2965 (input_symtab): Do not call removed function.
2966 * modulo-sched.c (sms_schedule): Do not print sum_max.
2967 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
2968 removed when histogram method was invented.
2969 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
2971 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
2973 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
2974 and dump selected value.
2975 * profile.c (add_working_set): Remove.
2976 (get_working_sets): Likewise.
2977 (find_working_set): Likewise.
2978 (get_exec_counts): Do not work with working sets.
2979 (read_profile_edge_counts): Do not inform as sum_max is removed.
2980 (compute_branch_probabilities): Likewise.
2981 (compute_value_histograms): Remove argument for call of
2982 get_coverage_counts.
2983 * profile.h: Do not make gcov_summary const.
2985 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
2987 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
2989 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2991 PR tree-optimization/86990
2992 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
2993 Check that the entire merged store group is made of constants only for
2996 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
2998 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
2999 (VTABLE_VERIFICATION_SPEC): Likewise.
3000 (SANITIZER_EARLY_SPEC): Likewise.
3001 (SANITIZER_SPEC): Likewise.
3002 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
3003 * doc/invoke.texi (Link Options): Document -r.
3005 2018-09-20 Richard Biener <rguenther@suse.de>
3008 * gimplify.c (gimplify_expr): Retain alignment of
3009 addressable lvalue in dereference.
3011 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
3014 * configure.ac: Check for .loc is_stmt support.
3015 * configure, config.in: Rebuilt.
3016 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
3019 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
3021 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
3022 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
3025 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
3027 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
3029 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
3032 2018-09-20 Marek Polacek <polacek@redhat.com>
3034 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
3036 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
3038 PR tree-optimization/87288
3039 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
3040 into account when determining PEELING_FOR_NITERS.
3042 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
3044 PR tree-optimization/86877
3045 * tree-vect-loop.c (vect_analyze_loop_2): Call
3046 vect_verify_datarefs_alignment.
3048 2018-09-19 Marek Polacek <polacek@redhat.com>
3050 * doc/invoke.texi: Document -Wclass-conversion.
3052 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
3054 * config/pa/pa.c (pa_adjust_priority): Delete.
3055 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
3057 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
3058 (atomic_storehi): Likewise.
3059 (atomic_storesi): Likewise.
3060 (atomic_loaddi): Restore compare and swap exchange loop code.
3062 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
3064 PR rtl-optimization/86902
3065 * combine.c (try_combine): When changing the CC mode used, don't change
3066 an unrelated mode in other_insn to that new CC mode.
3068 2018-09-19 David Malcolm <dmalcolm@redhat.com>
3070 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
3071 with %T in place of calls to dump_generic_expr.
3072 (prune_runtime_alias_test_list): Likewise.
3073 (create_runtime_alias_checks): Likewise.
3074 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
3075 (vect_analyze_data_ref_dependence): Likewise.
3076 (vect_slp_analyze_data_ref_dependence): Likewise.
3077 (vect_record_base_alignment): Likewise. Use %G in place of call
3078 to dump_gimple_stmt.
3079 (vect_compute_data_ref_alignment): Likewise.
3080 (verify_data_ref_alignment): Likewise.
3081 (vect_find_same_alignment_drs): Likewise.
3082 (vect_analyze_group_access_1): Likewise.
3083 (vect_analyze_data_ref_accesses): Likewise.
3084 (dependence_distance_ge_vf): Likewise.
3085 (dump_lower_bound): Likewise.
3086 (vect_prune_runtime_alias_test_list): Likewise.
3087 (vect_find_stmt_data_reference): Likewise.
3088 (vect_analyze_data_refs): Likewise.
3089 (vect_create_addr_base_for_vector_ref): Likewise.
3090 (vect_create_data_ref_ptr): Likewise.
3091 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
3092 (vect_can_advance_ivs_p): Likewise.
3093 (vect_update_ivs_after_vectorizer): Likewise.
3094 (vect_gen_prolog_loop_niters): Likewise.
3095 (vect_prepare_for_masked_peels): Likewise.
3096 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
3097 (vect_determine_vectorization_factor): Likewise.
3098 (vect_is_simple_iv_evolution): Likewise.
3099 (vect_analyze_scalar_cycles_1): Likewise.
3100 (vect_analyze_loop_operations): Likewise.
3101 (report_vect_op): Likewise.
3102 (vect_is_slp_reduction): Likewise.
3103 (check_reduction_path): Likewise.
3104 (vect_is_simple_reduction): Likewise.
3105 (vect_create_epilog_for_reduction): Likewise.
3106 (vect_finalize_reduction:): Likewise.
3107 (vectorizable_induction): Likewise.
3108 (vect_transform_loop_stmt): Likewise.
3109 (vect_transform_loop): Likewise.
3110 (optimize_mask_stores): Likewise.
3111 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
3112 (vect_split_statement): Likewise.
3113 (vect_recog_over_widening_pattern): Likewise.
3114 (vect_recog_average_pattern): Likewise.
3115 (vect_determine_min_output_precision_1): Likewise.
3116 (vect_determine_precisions_from_range): Likewise.
3117 (vect_determine_precisions_from_users): Likewise.
3118 (vect_mark_pattern_stmts): Likewise.
3119 (vect_pattern_recog_1): Likewise.
3120 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
3121 (vect_record_max_nunits): Likewise.
3122 (vect_build_slp_tree_1): Likewise.
3123 (vect_build_slp_tree_2): Likewise.
3124 (vect_print_slp_tree): Likewise.
3125 (vect_analyze_slp_instance): Likewise.
3126 (vect_detect_hybrid_slp_stmts): Likewise.
3127 (vect_detect_hybrid_slp_1): Likewise.
3128 (vect_slp_analyze_operations): Likewise.
3129 (vect_slp_analyze_bb_1): Likewise.
3130 (vect_transform_slp_perm_load): Likewise.
3131 (vect_schedule_slp_instance): Likewise.
3132 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
3133 (vect_mark_stmts_to_be_vectorized): Likewise.
3134 (vect_init_vector_1): Likewise.
3135 (vect_get_vec_def_for_operand): Likewise.
3136 (vect_finish_stmt_generation_1): Likewise.
3137 (vect_check_load_store_mask): Likewise.
3138 (vectorizable_call): Likewise.
3139 (vectorizable_conversion): Likewise.
3140 (vectorizable_operation): Likewise.
3141 (vectorizable_load): Likewise.
3142 (vect_analyze_stmt): Likewise.
3143 (vect_is_simple_use): Likewise.
3144 (vect_get_vector_types_for_stmt): Likewise.
3145 (vect_get_mask_type_for_stmt): Likewise.
3146 * tree-vectorizer.c (increase_alignment): Likewise.
3148 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
3150 * doc/rtl.texi: Adjust vec_select description.
3151 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
3152 non-constant selectors.
3154 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
3156 * config/aarch64/aarch64-protos.h
3157 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
3158 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
3159 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
3160 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
3161 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
3162 (AARCH64_FL_PROFILE): Move index so flags are ordered.
3163 (AARCH64_ISA_RCPC8_4): New flag.
3164 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
3165 to aarch64_offset_9bit_signed_unscaled_p.
3166 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
3168 * config/aarch64/constraints.md (Ust): New constraint.
3169 * config/aarch64/predicates.md.
3170 (aarch64_9bit_offset_memory_operand): New predicate.
3171 (aarch64_rcpc_memory_operand): New predicate.
3173 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
3175 PR rtl-optimization/87361
3176 * rtlanal.c (nonzero_bits1): Revert accidental change.
3178 2018-09-19 Richard Biener <rguenther@suse.de>
3180 PR tree-optimization/87349
3181 PR tree-optimization/87342
3182 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
3184 2018-09-18 Marek Polacek <polacek@redhat.com>
3186 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
3187 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
3189 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
3191 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
3193 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
3195 PR rtl-optimization/86882
3196 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
3198 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
3200 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
3201 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
3203 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
3206 * doc/invoke.texi (Link Options): Fix formatting and grammar.
3208 2018-09-18 Richard Biener <rguenther@suse.de>
3211 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
3212 (compute_samebase_partition_bases): Likewise.
3213 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
3214 (gimple_can_coalesce_p): Simplify.
3216 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
3218 Handle a library implementation of ffs calling __builtin_ffs.
3219 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
3220 (mmix_init_libfuncs): New function: make __builtin_ffs expand
3223 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3225 * diagnostic-show-locus.c (class layout_range): Add field
3227 (layout_range::layout_range): Add "original_idx" param and use it
3228 to initialize new field.
3229 (make_range): Use 0 for original_idx.
3230 (layout::layout): Pass in index to calls to
3231 maybe_add_location_range.
3232 (layout::maybe_add_location_range): Add param "original_idx" and
3233 pass it on to layout_range.
3234 (layout::print_any_labels): Pass on range->m_original_idx to
3236 (gcc_rich_location::add_location_if_nearby): Use 0 for
3238 * gcc-rich-location.h (text_range_label::get_text): Update for new
3240 (range_label_for_type_mismatch::get_text): Likewise.
3242 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
3244 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
3246 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3248 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
3249 format_string_diagnostic_t.
3250 (fmtwarn_n): Likewise.
3251 * substring-locations.c
3252 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
3253 (format_warning_n_va): Convert to...
3254 (format_string_diagnostic_t::emit_warning_n_va): ...this.
3255 (format_warning_va): Convert to...
3256 (format_string_diagnostic_t::emit_warning_va): ...this.
3257 (format_warning_at_substring): Convert to...
3258 (format_string_diagnostic_t::emit_warning): ...this.
3259 (format_warning_at_substring_n): Convert to...
3260 (format_string_diagnostic_t::emit_warning_n): ...this.
3261 * substring-locations.h (class format_string_diagnostic_t): New
3263 (format_warning_va): Convert to
3264 format_string_diagnostic_t::emit_warning_va.
3265 (format_warning_n_va): Convert to
3266 format_string_diagnostic_t::emit_warning_n_va.
3267 (format_warning_at_substring): Convert to
3268 format_string_diagnostic_t::emit_warning.
3269 (format_warning_at_substring_n): Convert to
3270 format_string_diagnostic_t::emit_warning_n.
3272 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
3273 Bernd Schmidt <bernds_cb1@t-online.de>
3275 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
3278 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
3280 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
3281 operand 0 predicate to nonimmediate operand.
3282 (rint<mode>2_frndint): Remove insn pattern.
3283 (rint<mode>2): Change operand 1 predicate to general_operand.
3284 Extend operand 1 to XFmode and generate rintxf2 insn.
3285 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
3286 Do not use X87MODEF mode macro.
3287 (frndintxf2_<rounding>_i387): Rename from
3288 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
3289 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
3290 to XFmode and generate significandxf3 insn.
3292 2018-09-17 Richard Biener <rguenther@suse.de>
3294 PR tree-optimization/87328
3295 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
3296 visiting unexecutable backedges when not iterating.
3297 (do_rpo_vn): Mark all edges not executable even when not
3300 2018-09-17 Martin Jambor <mjambor@suse.cz>
3303 * doc/invoke.texi (Warning Options): Likewise.
3305 2018-09-17 Richard Biener <rguenther@suse.de>
3307 PR tree-optimization/87301
3308 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
3309 clean EH info from leftover copy assignments.
3311 2018-09-17 Martin Liska <mliska@suse.cz>
3313 PR gcov-profile/85871
3314 * gcov.c (output_intermediate_file): Fix out of bounds
3317 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
3319 * config/arc/arc.c: Object attributes for core4 not reflected
3321 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
3324 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
3326 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
3328 2018-09-17 Martin Liska <mliska@suse.cz>
3330 * doc/gcov.texi: Document new option --use-hotness-colors.
3331 * gcov.c (struct source_info): Declare new field.
3332 (source_info::source_info): Set default for maximum_count.
3333 (print_usage): Add new -q option.
3334 (process_args): Process it.
3335 (accumulate_line_info): Save src->maximum_count.
3336 (output_line_beginning): Make color line number if
3337 flag_use_hotness_colors is set.
3338 (output_line_details): Pass default argument value.
3339 (output_lines): Pass src->maximum_count.
3341 2018-09-17 Martin Liska <mliska@suse.cz>
3343 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
3344 Use processor_names table.
3345 * config/i386/i386.c (ix86_default_align): Use
3346 processor_cost_table for alignment values.
3347 (ix86_option_override_internal): Use processor_names.
3348 (ix86_function_specific_print): Likewise.
3349 * config/i386/i386.h (struct processor_costs):
3350 Add alignment values.
3351 (struct ptt): Remove and replace with const char *.
3352 * config/i386/x86-tune-costs.h (struct processor_costs):
3353 Declare default alignments for all costs.
3355 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
3357 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
3358 symbolics or VR_VARYING ranges for ABS_EXPR.
3359 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
3360 when range will wrap.
3362 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
3365 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
3366 before and after a JUMP_TABLE_DATA.
3368 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
3371 * dojump.c (do_compare_and_jump): Canonicalize function pointers
3372 when one operand is a function pointer. Use POINTER_TYPE_P and
3373 FUNC_OR_METHOD_TYPE_P.
3374 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
3375 * fold-const.c (build_range_check): Likewise.
3376 * match.pd (simple_comparison): Likewise.
3378 2018-09-14 David Malcolm <dmalcolm@redhat.com>
3381 * spellcheck.c (get_edit_distance_cutoff): New function.
3382 (selftest::test_edit_distance_unit_test_oneway): Rename to...
3383 (selftest::test_get_edit_distance_one_way): ...this.
3384 (selftest::test_get_edit_distance_unit): Rename to...
3385 (selftest::test_get_edit_distance_both_ways): ...this.
3386 (selftest::test_edit_distances): Move tests to this new function,
3387 and test some more pairs of strings. Update for above renaming.
3388 (selftest::get_old_cutoff): New function.
3389 (selftest::test_get_edit_distance_cutoff): New function.
3390 (selftest::assert_suggested_for): New function.
3391 (ASSERT_SUGGESTED_FOR): New macro.
3392 (selftest::assert_not_suggested_for): New function.
3393 (ASSERT_NOT_SUGGESTED_FOR): New macro.
3394 (selftest::test_suggestions): New function.
3395 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
3396 tests to selftest::test_edit_distances and call it. Add calls to
3397 selftest::test_get_edit_distance_cutoff and
3398 selftest::test_suggestions.
3399 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
3400 (best_match::consider): Replace hard-coded cutoff calculation with
3402 (best_match::get_cutoff): New declaration.
3403 (best_match::get_best_meaningful_candidate): Likewise.
3405 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
3407 * builtins.c (fold_builtin_strlen): Remove TODO comment.
3409 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
3412 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
3414 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
3415 terminated string literal.
3417 2018-09-14 Martin Sebor <msebor@redhat.com>
3419 * builtins.c (unterminated_array): Handle ARRAY_REF.
3420 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
3421 * builtins.h (unterminated_array): Declare extern.
3422 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
3424 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
3427 2018-09-14 Martin Sebor <msebor@redhat.com>
3428 Jeff Law <law@redhat.com>
3430 * builtins.c (unterminated_array): New.
3431 (expand_builtin_strcpy): Adjust.
3432 (expand_builtin_strcpy_args): Detect unterminated arrays.
3433 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
3434 unterminated arrays.
3435 * gimple-fold.h (get_maxval_strlen): Add argument.
3436 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
3438 * gimple-fold.c (get_range_strlen): Add argument.
3439 (get_maxval_strlen): Adjust.
3440 * gimple-fold.h (get_range_strlen): Add argument.
3442 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
3444 * config/i386/movdirintrin.h: Fix copyright year.
3446 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
3448 * reg-stack.c: Include regs.h.
3449 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
3450 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
3451 FIRST_STACK_REG, not DFmode.
3452 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
3453 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
3454 (change stack): Default register mode to the reg_raw_mode of
3455 FIRST_STACK_REG, not DFmode.
3456 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
3457 (*swapxf): Rename from swapxf.
3459 2018-09-14 Carl Love <cel@us.ibm.com>
3461 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
3462 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
3464 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
3467 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
3470 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
3473 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
3475 2018-09-14 Jason Merrill <jason@redhat.com>
3477 Fix --enable-gather-detailed-mem-stats.
3478 * hash-table.c (hash_table_usage): Change from variable to function.
3479 * hash-table.h: Adjust.
3480 * Makefile.in: Add missing dependencies on hash-table.h.
3482 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3484 PR tree-optimization/87259
3486 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
3487 execute_cse_reciprocals_1 has tried transforming.
3489 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
3491 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
3492 VR_VARYING for PLUS/MINUS_EXPR.
3494 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
3496 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
3499 2018-09-14 Richard Biener <rguenther@suse.de>
3502 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
3503 bits for the merged partition.
3505 2018-09-13 Martin Sebor <msebor@redhat.com>
3506 Bernd Edlinger <bernd.edlinger@hotmail.de>
3508 * builtins.h (c_srlen): Add argument.
3509 * builtins.c (warn_string_no_nul): New function.
3510 (c_strlen): Add argument and use it. Update recursive calls.
3511 Pass DECL argument to string_constant to get info on non
3512 terminated strings. Update *NONSTR as needed.
3513 (fold_builtin_strlen): Add argument to calls to c_strlen.
3514 Warn for unterminated arrays.
3515 (warn_string_no_null): Add prototype.
3516 * expr.c (string_constant): Update arguments. Update recursive
3517 calls appropriately. Detect missing NUL terminator and outermost
3518 declaration its missing in.
3519 Improve checks for arrays with nonzero lower bound or elements
3520 that are not a single byte. Simplify offset computation.
3521 Simplify checks for non-NUL terminated strings.
3522 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
3523 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
3525 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
3527 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
3529 * fold-const.c (c_getstr): Fix function comment. Remove unused third
3530 argument. Fix range checks.
3531 * fold-const.h (c_getstr): Adjust protoype.
3532 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
3533 string is constant but contains no NUL byte.
3535 * expr.c (string_constant): Adjust function comment.
3536 Remove bogus check for zero termination.
3538 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
3540 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
3541 (get_constant_size): Don't make STRING_CSTs larger than they are.
3542 (check_string_literal): New check function for STRING_CSTs.
3543 (output_constant): Use it.
3545 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
3548 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
3550 2018-09-13 Richard Biener <rguenther@suse.de>
3552 PR tree-optimization/87263
3553 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
3554 (struct unwind_state): Add max_rpo field.
3555 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
3556 Compute max_rpo, the max RPO number a block can be backwards reached
3557 from. Re-write non-iterating mode to a RPO ordered worklist approach,
3558 separating it from the iterating mode.
3560 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
3562 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
3563 (rfs_decision): New scheduling decision.
3565 2018-09-13 Richard Biener <rguenther@suse.de>
3568 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
3569 (vn_nary_op_insert_pieces_predicated): Do not write useless
3570 valid_dominated_by_p entry outside of the allocated storage.
3572 2018-09-13 Omar Sandoval <osandov@osandov.com>
3573 Tom de Vries <tdevries@suse.de>
3576 * dwarf2out.c (is_c): New function.
3577 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
3579 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
3582 * config/aarch64/aarch64.md (*aarch64_bfxil):
3584 * config/aarch64/constraints.md (Ulc): Define.
3585 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
3587 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
3590 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
3592 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
3593 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
3594 aarch64_layout_frame call.
3595 (aarch64_expand_epilogue): Likewise.
3596 (aarch64_initial_elimination_offset): Likewise.
3597 (aarch64_get_separate_components): Likewise.
3598 (aarch64_use_return_insn_p): Likewise.
3599 (aarch64_layout_frame): Remove unneeded check.
3601 2018-09-13 Jakub Jelinek <jakub@redhat.com>
3603 * configure.ac: Only append
3604 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
3605 gcc_config_arguments if it was never reconfigured or last reconfigure
3606 was with different arguments.
3607 * configure: Regenerated.
3609 2018-09-13 Jakub Jelinek <jakub@redhat.com>
3610 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3613 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
3614 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
3616 2018-09-13 Jakub Jelinek <jakub@redhat.com>
3618 PR tree-optimization/87287
3619 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
3620 X % C == 0 to X % (unsigned) C == 0 optimization to ...
3621 * match.pd (X % C == 0): ... here. New optimization.
3623 2018-09-12 Jakub Jelinek <jakub@redhat.com>
3626 * expr.h (maybe_optimize_mod_cmp): Declare.
3627 * expr.c (mod_inv): New function.
3628 (maybe_optimize_mod_cmp): New function.
3629 (do_store_flag): Use it.
3630 * cfgexpand.c (expand_gimple_cond): Likewise.
3632 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
3633 Julian Brown <julian@codesourcery.com>
3636 * gimplify.c (gimplify_scan_omp_clauses): Set
3637 target_firstprivatize_array_bases in OpenACC parallel and kernels
3638 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
3639 OpenACC data regions.
3641 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
3643 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
3644 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
3646 2018-09-12 Richard Biener <rguenther@suse.de>
3648 PR tree-optimization/87280
3649 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
3650 edge but unreachable target.
3651 (do_rpo_vn): For conservatively handling a PHI only mark
3652 the backedge executable but not the block reachable.
3654 2018-09-12 Richard Biener <rguenther@suse.de>
3656 PR tree-optimization/87266
3657 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
3660 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
3662 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
3664 ("trunc<BFP:mode><DFP_ALL:mode>2")
3665 ("trunc<DFP_ALL:mode><BFP:mode>2")
3666 ("extend<BFP:mode><DFP_ALL:mode>2")
3667 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
3668 according to the target operand type.
3670 2018-09-12 Jakub Jelinek <jakub@redhat.com>
3671 Andreas Krebbel <krebbel@linux.ibm.com>
3673 PR tree-optimization/86844
3674 * gimple-ssa-store-merging.c
3675 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
3676 there are any overlapping stores in between them, make sure they are
3677 also coalesced or we give up completely.
3679 2018-09-12 Jakub Jelinek <jakub@redhat.com>
3682 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
3683 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
3685 2018-09-12 Tom de Vries <tdevries@suse.de>
3687 * common.opt (gdescribe-dies): Add option.
3688 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
3689 attribute for artifical and nameless decls.
3690 (dwarf2out_register_external_die): Add description attribute to
3691 external reference die.
3692 (add_desc_attribute): New functions.
3693 (gen_subprogram_die): Add description attribute to
3694 DW_TAG_call_site_parameter.
3695 * tree-pretty-print.c (print_generic_expr_to_str): New function.
3696 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
3697 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
3699 (@item -gdescribe-dies): Add.
3701 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
3703 * tree-vrp.c (vrp_shift_undefined_p): Remove.
3704 (extract_range_from_binary_expr_1: Call
3705 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
3706 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
3709 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
3711 * gimple-ssa-warn-alloca.c
3712 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
3713 field for ALLOCA_BOUND_*_LARGE.
3715 2018-09-11 Nathan Sidwell <nathan@acm.org>
3717 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
3719 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
3721 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
3722 for clobbers. Remove obsolete comment.
3724 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
3726 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
3727 mpxchk, mpxld and mpxst types.
3728 (define_attr length_immediate): Remove all processing of mpx types.
3729 (define_attr prefix_0f): Ditto.
3730 (define_attr memory): Ditto.
3732 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
3734 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
3735 (log<mode>2): Change operand 1 predicate to general_operand.
3736 Extend operand 1 to XFmode and generate logxf3 insn.
3737 (log10<mode>2): Change operand 1 predicate to general_operand.
3738 Extend operand 1 to XFmode and generate log10xf3 insn.
3739 (log2<mode>2): Change operand 1 predicate to general_operand.
3740 Extend operand 1 to XFmode and generate log2xf3 insn.
3741 (fyl2xp1_extend<mode>xf3_i387): Remove.
3742 (log1p<mode>2): Change operand 1 predicate to general_operand.
3743 Extend operand 1 to XFmode and generate log1pxf3 insn.
3744 (fxtract_extend<mode>xf3_i387): Remove.
3745 (logb<mode>2): Change operand 1 predicate to general_operand.
3746 Extend operand 1 to XFmode and generate logbxf3 insn.
3747 (ilogb<mode>2): Change operand 1 predicate to general_operand.
3748 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
3749 (significand<mode>2): Change operand 1 predicate to general_operand.
3750 Extend operand 1 to XFmode and generate significandxf3 insn.
3752 2018-09-11 Nathan Sidwell <nathan@acm.org>
3754 * gcc.c (perror_with_name, pfatal_with_name): Delete.
3755 (load_specs): Use fatal_error.
3756 (DELETE_IF_ORDINARY, process_command): Use error.
3757 (execute, run_attempt): Use fatal_error.
3759 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
3761 * diagnostic-core.h (sorry_at): New prototype.
3762 * diagnostic.c (sorry_at): New function.
3764 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
3766 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
3767 by zero as VR_UNDEFINED.
3769 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
3771 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
3772 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
3773 (<sincos>mode2): New expander.
3774 (sincos_extend<mode>xf3_i387): Remove insn pattern.
3775 (sincos -> sin, cos splitters): Remove splitter patterns.
3776 (sincos<mode>3): Change operand 2 predicate to general_operand.
3777 Extend operand 2 to XFmode and generate sincosxf3 insn.
3778 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
3779 Change operand 3 predicate to const1_operand.
3780 (fptan_extend<mode>xf4_i387): Remove insn pattern.
3781 (tanxf2): Update operands in the call to fptanxf4_i387.
3782 (tan<mode>2): Change operand 1 predicate to general_operand.
3783 Extend operand 1 to XFmode and generate tanxf3 insn.
3784 (atan2xf3): Rename from *fpatanxf3_i387.
3785 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
3786 (atan2xf3): Remove expander.
3787 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
3788 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
3789 (atan<mode>2): Change operand 1 predicate to general_operand.
3790 Extend operand 1 to XFmode and generate atanxf3 insn.
3792 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
3794 * config/i386/i386.md (x87/SSE constant load splitter): Use
3795 memory_operand instead of nonimmediate_operand for input operand
3798 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
3800 * config/i386/i386.md (float partial SSE register stall splitter): Move
3801 splitter near its instruction pattern.
3802 (float_extend partial SSE register stall splitter): Ditto.
3803 (float_truncate partial SSE register stall splitter): Ditto.
3805 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
3808 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
3809 to speculation_safe_value_not_needed.
3812 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
3813 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
3814 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
3815 leaf_function_p, instead use has_hard_reg_initial_val.
3817 2018-09-09 Nathan Sidwell <nathan@acm.org>
3819 * gcc.h (pfatal_with_name): Don't declare here.
3820 * gcc.c (pfatal_with_name): Make static.
3822 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
3824 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
3827 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
3829 PR rtl-optimization/85458
3830 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
3831 priority hook to reduce the priority of EXPR.
3833 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
3835 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
3836 DImode for x87 on 32bit targets. Conditionally disable x87 modes
3837 with X87_ENABLE_FLOAT. Remove preparation code.
3838 (*float<SWI48:mode><MODEF:mode>2): Rename from
3839 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
3840 math using "enabled" attribute.
3841 (*floatdi<MODEF:mode>2_i387): Rename from
3842 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
3843 enable for 32bit targets only.
3844 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
3846 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
3847 as operand 1 predicate. Rewrite as define_insn_and_split.
3848 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
3850 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
3852 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
3853 to fallthru to FLOAT case.
3855 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
3858 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
3859 around folding of vec_sl to handle out of range shift values.
3861 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
3863 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
3864 Update callers to gen_fix_trunc<mode>_i387_fisttp
3865 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
3866 nonimmediate_operand.
3867 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
3868 and corresponding splitters.
3869 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
3870 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
3871 (fix_truncdi_i387_with_temp): Remove insn pattern
3872 and corresponding splitters.
3873 (fix_trunc<mode>_i387): Change operand 0 predicate to
3874 nonimmediate_operand.
3875 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
3876 and corresponding splitters.
3877 (*fistdi2_1): Remove.
3879 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
3880 (lrintxfdi2): Remove expander. Reimplement as define_insn.
3881 (*fist<mode>2_1): Remove.
3882 (fist<mode>2): Ditto.
3883 (fist<mode>2_with_temp): Remove insn pattern and corresponding
3885 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
3886 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
3887 (fistdi2_<rounding>): Change operand 0 predicate to
3888 nonimmediate_operand.
3889 (fistdi2_<rounding>_with_temp): Remove insn pattern
3890 and corresponding splitters.
3891 (fist<mode>2_<rounding>): Change operand 0 predicate to
3892 nonimmediate_operand.
3893 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
3894 and corresponding splitters.
3896 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
3898 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
3900 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
3903 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
3905 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
3906 early gimple folding of vec_splat().
3907 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
3908 * gimple-fold.h: Add an extern define for tree_vec_extract().
3910 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
3912 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
3913 wrappers around TREE_TYPE comparisons.
3915 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
3918 * config/s390/predicates.md: Add nonsym_memory_operand.
3919 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
3920 contains a SYMBOL_REF, load it into an intermediate pseudo.
3921 (s390_emit_compare_and_swap): Legitimize operand.
3922 * config/s390/s390.md: Use the new nonsym_memory_operand
3923 with UNSPECV_CAS patterns.
3925 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
3928 * config/s390/s390-passes.def: New file.
3929 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
3931 (make_pass_s390_early_mach): Add declaration.
3932 * config/s390/s390.c (make_pass_s390_early_mach):
3933 (s390_option_override): Remove dynamic registration.
3934 * config/s390/t-s390: Add s390-passes.def.
3936 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
3938 * config/s390/s390.c (s390_decompose_constant_pool_ref):
3939 Remove UNSPEC_LTREL_BASE check.
3940 (annotate_constant_pool_refs): Likewise.
3941 (find_constant_pool_ref): Likewise.
3942 (find_ltrel_base): Removed.
3943 (replace_ltrel_base): Removed.
3944 (s390_mainpool_finish): Remove replace_ltrel_base call.
3945 (s390_chunkify_start): Remove pending LTREL_BASE logic.
3946 (s390_chunkify_finish): Remove replace_ltrel_base call.
3947 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
3949 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
3952 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
3953 to speculation_safe_value_not_needed.
3955 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
3956 Bernd Schmidt <bernds_cb1@t-online.de>
3958 * config/nvptx/nvptx-opts.h: New file.
3959 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
3960 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
3962 (TARGET_SM35): New macro.
3963 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
3965 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
3967 (misa=): New option.
3968 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
3970 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
3972 * config/i386/i386.md (truncdfsf2): Remove expander.
3973 (truncdfsf2_with_temp): Ditto.
3974 (truncxf<mode>2): Ditto.
3975 (*truncdfsf_fast_mixed): Remove insn pattern.
3976 (*truncdfsf_fast_i387): Ditto.
3977 (*truncdfsf_mixed): Ditto.
3978 (*truncdfsf_i387): Ditto.
3979 (*truncdfsf2_i387_1): Ditto.
3980 (*truncxfsf2_mixed): Ditto.
3981 (*truncxfdf2_mixed): Ditto.
3982 (*truncxf<mode>2_i387_noop): Ditto. Update callers
3983 to call gen_truncxf<mode>2 instead.
3984 (*truncxf<mode>2_i387): Remove.
3985 (reg->reg splitters): Remove splitter pattern.
3986 (reg->mem splitters): Ditto.
3988 (truncdfsf2): New insn pattern.
3989 (truncxf<mode>2): Ditto.
3991 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3993 * tree-ssa-math-opts.c (is_mult_by): New function.
3994 (is_square_of): Use the above.
3995 (optimize_recip_sqrt): New function.
3996 (pass_cse_reciprocals::execute): Use the above.
3998 2018-09-05 Richard Biener <rguenther@suse.de>
4001 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
4002 to zero-init the emplaced vec.
4004 2018-09-05 Martin Liska <mliska@suse.cz>
4006 PR tree-optimization/87205
4007 * tree-switch-conversion.c (pass_lower_switch::execute):
4008 Group cases for switch statements.
4010 2018-09-05 Richard Biener <rguenther@suse.de>
4012 PR tree-optimization/87217
4013 * tree-ssa-sccvn.c (vuse_valueize): New.
4014 (vn_reference_lookup_pieces): Use it.
4015 (vn_reference_lookup): Likewise.
4017 2018-09-05 Nathan Sidwell <nathan@acm.org>
4020 * stor-layout.c (place_field): Scan forwards to check last
4021 bitfield when ms_bitfield_placement is in effect.
4023 2018-09-05 Richard Biener <rguenther@suse.de>
4026 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
4029 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
4030 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
4032 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
4033 * config.gcc (extra_objs): Build it.
4034 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
4036 * config/aarch64/aarch64-passes.def
4037 (pass_tag_collision_avoidance): New pass.
4038 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
4039 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
4040 (aarch64_classify_address): Remove static qualifier.
4041 (aarch64_address_info, aarch64_address_type): Move to...
4042 * config/aarch64/aarch64-protos.h: ... here.
4043 (make_pass_tag_collision_avoidance): New function.
4044 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
4047 2018-09-05 Martin Liska <mliska@suse.cz>
4049 * doc/gcov.texi: Update documentation of humar
4051 * gcov.c (format_count): Print one decimal place, it provides
4052 more fine number of situations like '1G' vs. '1.4G'.
4054 2018-09-05 Martin Liska <mliska@suse.cz>
4057 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
4058 * optc-gen.awk: Allow 'Var' for Deprecated options in order
4059 to generate a MASK value.
4061 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
4064 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
4065 if frame pointer isn't used.
4066 (compute_frame_pointer_to_fb_displacement): Likewise.
4068 2018-09-04 Jakub Jelinek <jakub@redhat.com>
4071 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
4072 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
4073 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
4074 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
4075 and OPTION_MASK_ISA_XSAVEC_UNSET.
4077 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
4079 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
4080 XOR operations in NAND case.
4082 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
4084 * wide-int-range.cc (wide_int_range_convert): New.
4085 * wide-int-range.h (wide_int_range_convert): New.
4086 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
4087 code into wide_int_range_convert.
4088 (extract_range_into_wide_ints): Do not munge anti range constants
4089 into the entire domain. Just return the range back.
4091 2018-09-04 Martin Liska <mliska@suse.cz>
4093 * genmatch.c (output_line_directive): Add new argument
4095 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
4097 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
4099 * doc/invoke.texi (Option Summary): Add whitespace.
4101 * doc/invoke.texi (Option Summary): Add -Waligned-new.
4103 2018-09-04 Richard Biener <rguenther@suse.de>
4105 PR tree-optimization/87211
4106 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
4107 backedge value we're supposed to treat as VARYING also number
4108 the PHI to VARYING in case it got a different value-number already.
4110 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
4112 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
4113 (extract_range_from_binary_expr_1): Do not call
4114 vrp_can_optimize_bit_op.
4115 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
4117 (wide_int_range_get_mask_and_bounds): New.
4118 (wide_int_range_optimize_bit_op): New.
4119 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
4120 (wide_int_range_bit_and): Same.
4121 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
4122 (wide_int_range_optimize_bit_op): New.
4123 (wide_int_range_get_mask_and_bounds): New.
4125 2018-09-04 Richard Biener <rguenther@suse.de>
4127 PR tree-optimization/87176
4128 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
4129 variable. When value-numbering a virtual PHI node make sure
4130 to not value-number to the backedge value.
4132 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
4134 * doc/extend.texi (Long Long, Hex Floats): Document support for
4135 long long and hex floats in more recent versions of ISO C++.
4137 2018-09-03 Richard Biener <rguenther@suse.de>
4139 PR tree-optimization/87177
4140 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
4143 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
4145 * bb-reorder.c (edge_order): Convert to C-qsort-style
4146 tri-state comparator.
4147 (reorder_basic_blocks_simple): Change std::stable_sort to
4150 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
4152 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
4153 tri-state comparator.
4154 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
4156 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
4158 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
4159 (mergesort): ... here as maximum count for using netsort.
4160 (gcc_qsort): Set nlim to 3 if stable sort is requested.
4161 (gcc_stablesort): New.
4162 * system.h (gcc_stablesort): Declare.
4164 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
4166 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
4167 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
4168 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
4170 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
4172 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
4173 lxsdx and stxsdx alternatives.
4174 (*mov<mode>_hardfloat64): Ditto.
4175 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
4177 2018-09-03 Richard Biener <rguenther@suse.de>
4179 PR tree-optimization/87200
4180 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
4183 2018-09-03 Martin Liska <mliska@suse.cz>
4185 PR tree-optimization/87201
4186 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
4187 Fix parenthesis in an expression.
4189 2018-09-03 Richard Biener <rguenther@suse.de>
4191 PR tree-optimization/87197
4192 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
4193 visited. CSE the VN_INFO hashtable lookup.
4195 PR tree-optimization/87169
4196 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
4197 iterating make sure there's no extra backedges from irreducible
4198 regions feeding the header. Mark the destination block
4201 2018-09-03 Martin Liska <mliska@suse.cz>
4204 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
4205 * common/common-targhooks.c (default_get_valid_option_values):
4207 * common/common-targhooks.h (default_get_valid_option_values):
4209 * common/config/i386/i386-common.c: Move processor_target_table
4211 (ix86_get_valid_option_values): New function.
4212 (TARGET_GET_VALID_OPTION_VALUES): New macro.
4213 * config/i386/i386.c (struct ptt): Move to i386-common.c.
4214 (PTA_*): Move all defined masks into i386-common.c.
4215 (ix86_function_specific_restore): Use new processor_cost_table.
4216 * config/i386/i386.h (struct ptt): Moved from i386.c.
4217 (struct pta): Likewise.
4218 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
4219 * doc/tm.texi.in: Likewise.
4220 * opt-suggestions.c (option_proposer::suggest_option):
4221 Pass prefix to build_option_suggestions.
4222 (option_proposer::get_completions): Likewise.
4223 (option_proposer::build_option_suggestions): Use the new target
4225 * opts.c (struct option_help_tuple): New struct.
4226 (print_filtered_help): Use the new target hook.
4228 2018-09-03 Martin Liska <mliska@suse.cz>
4231 * predict.c (set_even_probabilities): Add likely_edges
4232 argument and handle cases where we have precisely one
4234 (combine_predictions_for_bb): Catch also likely_edges.
4235 (tree_predict_by_opcode): Handle gswitch statements.
4236 * tree-cfg.h (find_case_label_for_value): New declaration.
4237 (find_taken_edge_switch_expr): Likewise.
4238 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
4239 Find pivot in decision tree based on probabily, not by number of
4242 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
4244 * doc/standards.texi (Standards): Update Objective-C reference.
4246 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
4248 * doc/install.texi (Prerequisites): Update link for MPC.
4250 2018-09-01 Michael Matz <matz@suse.de>
4252 PR tree-optimization/87074
4253 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
4254 PHIs for outer-loop uses.
4256 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
4258 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
4259 * doc/invoke.texi (C Dialect Options): Ditto.
4261 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
4263 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
4265 2018-08-31 Richard Biener <rguenther@suse.de>
4267 PR tree-optimization/87168
4268 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
4269 (rpo_elim::eliminate_avail): When OP was not visited it must
4272 2018-08-31 David Malcolm <dmalcolm@redhat.com>
4274 * tree-vrp.c (copy_value_range): Convert param "from" from
4275 "value_range *" to "const value_range *".
4276 (range_is_null): Likewise for param "vr".
4277 (range_int_cst_p): Likewise.
4278 (range_int_cst_singleton_p): Likewise.
4279 (symbolic_range_p): Likewise.
4280 (value_ranges_intersect_p): Likewise for both params.
4281 (value_range_nonnegative_p): Likewise for param "vr".
4282 (value_range_constant_singleton): Likewise.
4283 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
4284 (extract_range_into_wide_ints): Likewise for param "vr".
4285 (extract_range_from_multiplicative_op): Likewise for params "vr0"
4287 (vrp_can_optimize_bit_op): Likewise.
4288 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
4290 (extract_range_from_unary_expr): Likewise.
4291 (debug_value_range): Likewise for param "vr".
4292 (value_range::dump): Add "const" qualifier.
4293 (vrp_prop::check_array_ref): Convert local "vr" from
4294 "value_range *" to "const value_range *".
4295 (vrp_prop::check_mem_ref): Likewise.
4296 (vrp_prop::visit_stmt): Likewise for local "old_vr".
4297 (vrp_intersect_ranges_1): Likewise for param "vr_1".
4298 (vrp_intersect_ranges): Likewise.
4299 (simplify_stmt_for_jump_threading): Likewise for local "vr".
4300 (vrp_prop::vrp_finalize): Likewise.
4301 * tree-vrp.h (value_range::dump): Add "const" qualifier.
4302 (vrp_intersect_ranges): Add "const" qualifier to params as above.
4303 (extract_range_from_unary_expr): Likewise.
4304 (value_range_constant_singleton): Likewise.
4305 (symbolic_range_p): Likewise.
4306 (copy_value_range): Likewise.
4307 (extract_range_from_binary_expr_1): Likewise.
4308 (range_int_cst_p): Likewise.
4309 (vrp_set_zero_nonzero_bits): Likewise.
4310 (range_int_cst_singleton_p): Likewise.
4312 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
4314 * config/aarch64/arm_neon.h (vabsd_s64): New.
4315 (vnegd_s64): Likewise.
4317 2018-08-31 Martin Jambor <mjambor@suse.cz>
4319 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
4321 2018-08-31 Martin Liska <mliska@suse.cz>
4323 * ipa-icf.c (sem_item::add_type): Use
4324 sem_item::m_type_hash_cache.
4325 * ipa-icf.h: Move the cache from sem_item_optimizer
4328 2018-08-31 Nathan Sidwell <nathan@acm.org>
4330 * doc/extend.texi (Backwards Compatibility): Remove implicit
4331 extern C leeway of () being (...).
4333 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4335 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
4337 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
4341 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
4343 2018-08-31 Jakub Jelinek <jakub@redhat.com>
4346 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
4347 gen_int_mode. Formatting fixes.
4349 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
4351 * target.def (custom_function_descriptors): Improve documentation.
4352 * doc/tm.texi.in (Trampolines): Expand discussion of function
4353 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
4354 beginning of the section.
4355 * doc/tm.texi: Regenerated.
4357 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
4359 * cfg.h (class auto_edge_flag): Spell out the template-id of the
4360 base class in the initializer list. This is a workaround for
4361 building with older GCC.
4362 (class auto_bb_flag): Likewise.
4364 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
4366 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
4367 (altivec_vcmpequ<VI_char>_p): Remove star.
4368 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
4370 (expand_strncmp_vec_sequence): New function.
4371 (emit_final_str_compare_vec): New function.
4372 (expand_strn_compare): Add support for vector strncmp.
4373 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
4374 length specification to bytes.
4375 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
4376 (vcmpnezb_p): New pattern.
4377 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
4378 for option -mstring-compare-inline-limit.
4380 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
4382 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
4383 (PTA_SKYLAKE): Add PTA_AES.
4384 (PTA_GOLDMONT): Likewise.
4386 2018-08-29 Jan Hubicka <jh@suse.cz>
4389 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
4390 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
4392 2018-08-29 Jan Hubicka <jh@suse.cz>
4394 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
4396 (hash_tree): Do not visit TYPE_STUB_DECL.
4397 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
4398 stream TYPE_STUB_DECL.
4399 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
4400 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
4401 after free_lang_data.
4402 (type_in_anonymous_namespace_p): Likewise.
4404 2018-08-29 Jan Hubicka <jh@suse.cz>
4406 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
4407 comment that it has to be even number.
4408 (class sreal): Change m_sig type to int32_t.
4409 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
4410 int64_t for temporary calculations.
4411 (sreal_verify_basics): Drop one bit from minimum and maximum.
4413 2018-08-30 Richard Biener <rguenther@suse.de>
4415 PR tree-optimization/87147
4416 * tree-ssa-sccvn.c (SSA_VISITED): New function.
4417 (visit_phi): When the degenerate result is from the backedge and
4418 we didn't visit its definition yet drop to VARYING.
4419 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
4421 2018-08-29 Jan Hubicka <jh@suse.cz>
4423 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
4425 (hash_tree): Likewise.
4427 2018-08-29 Jan Hubicka <jh@suse.cz>
4429 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
4430 and TYPE_NEXT_REF_TO.
4432 2018-08-29 Jan Hubicka <jh@suse.cz>
4434 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
4435 comment that it has to be even number.
4436 (class sreal): Change m_sig type to int32_t.
4437 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
4438 int64_t for temporary calculations.
4439 (sreal_verify_basics): Drop one bit from minimum and maximum.
4441 2018-08-30 Tamar Christina <tamar.christina@arm.com>
4443 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
4445 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
4448 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
4449 if to_add is negative.
4451 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
4454 * builtins.c (c_strlen): Improve range checks.
4456 2018-08-29 Martin Sebor <msebor@redhat.com>
4457 Jeff Law <law@redhat.com>
4459 PR tree-optimization/86714
4460 PR tree-optimization/86711
4461 * builtins.c (c_strlen): Add arguments to call to string_constant.
4462 * expr.c (string_constant): Add argument. Detect missing nul
4463 terminator and outermost declaration it's missing in.
4464 * expr.h (string_constant): Add argument.
4465 * fold-const.c (read_from_constant_string): Add arguments to call to
4467 (c_getstr): Likewise.
4468 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
4470 * tree-ssa-strlen.c (get_stridx): Likewise.
4472 2018-08-29 Jan Hubicka <jh@suse.cz>
4474 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
4475 Do not stream DECL_VINDEX.
4476 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
4477 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
4478 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
4480 2018-08-29 Richard Biener <rguenther@suse.de>
4482 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
4483 virtual operands that are not default defs to honor region
4485 (rpo_vn_valueize): Remove ineffective code here.
4487 2018-08-29 Richard Biener <rguenther@suse.de>
4489 PR tree-optimization/87132
4490 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
4491 when skipping defs reachable over backedges.
4493 2018-08-29 Richard Biener <rguenther@suse.de>
4495 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
4496 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
4497 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
4498 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
4499 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
4500 (vn_reference_lookup_3): Remove use of const_parms.
4501 (free_rpo_vn): Do not free const_parms.
4502 (do_rpo_vn): Do not call init_const_parms.
4503 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
4504 SSA_NAME_POINTS_TO_READONLY_MEMORY.
4505 (call_may_clobber_ref_p_1): Likewise.
4507 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
4510 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
4512 (-ftree-scev-cprop): Document.
4514 2018-08-29 Jan Hubicka <jh@suse.cz>
4516 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
4518 (sreal constructor): Update.
4519 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
4520 sreal:operator/): Update.
4522 2018-08-29 Martin Liska <mliska@suse.cz>
4524 * tree-switch-conversion.c (switch_conversion::expand):
4525 Strenghten assumption about gswitch statements.
4527 2018-08-29 Richard Biener <rguenther@suse.de>
4529 PR tree-optimization/87117
4530 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
4531 re-value-number released SSA VDEFs.
4533 2018-08-29 Richard Biener <rguenther@suse.de>
4535 PR tree-optimization/87126
4536 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
4538 2018-08-28 Jim Wilson <jimw@sifive.com>
4540 * config/riscv/pic.md: Rewrite.
4541 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
4543 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
4544 (SOFTF, default_load, softload, softstore): New.
4546 2018-08-28 Jeff Law <law@redhat.com>
4548 * fold-const.c (fold_binary_loc): Remove recently added assert.
4550 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
4552 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
4553 to OP parmeter of generated function.
4555 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
4557 PR tree-optimization/87009
4558 * match.pd: Add boolean optimizations.
4560 2018-08-28 Martin Sebor <msebor@redhat.com>
4563 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
4564 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
4565 (pass_walloca::gate): Use it.
4566 (alloca_call_type): Same.
4567 (pass_walloca::execute): Same.
4568 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
4570 2018-08-28 David Malcolm <dmalcolm@redhat.com>
4572 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
4573 GCC_VERSION for usage of "__gcc_dump_printf__" format from
4576 2018-08-28 Richard Biener <rguenther@suse.de>
4578 PR tree-optimization/87124
4579 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
4580 constants before looking up avail.
4582 2018-08-28 Jakub Jelinek <jakub@redhat.com>
4585 * calls.c (maybe_warn_nonstring_arg): Punt early if
4586 warn_stringop_overflow is zero. Don't call get_range_strlen
4587 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
4588 Swap comparison operands to have constants on rhs. Only use
4589 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
4590 increment lenrng[0].
4592 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
4594 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
4595 use of tree_to_shwi. Remove duplicated test for the size being
4596 a whole number of bytes.
4598 2018-08-28 Richard Biener <rguenther@suse.de>
4600 PR tree-optimization/87117
4601 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
4602 Handle removed stmt without LHS (GIMPLE_NOP).
4604 2018-08-28 Richard Biener <rguenther@suse.de>
4606 PR tree-optimization/87117
4607 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
4608 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
4610 2018-08-28 Richard Biener <rguenther@suse.de>
4612 PR tree-optimization/87117
4613 * tree-ssa-pre.c (compute_avail): Do not make expressions
4614 with predicated values available.
4615 (get_expr_value_id): Assert we do not run into predicated value
4618 2018-08-28 Richard Biener <rguenther@suse.de>
4620 PR tree-optimization/87117
4621 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
4622 get virtual operands.
4623 (get_expr_operands): Handle STRING_CST like other decls.
4625 2018-08-28 Martin Liska <mliska@suse.cz>
4627 * tree.h: Update documentation of fndecl_built_in_p
4631 2018-08-27 Jeff Law <law@redhat.com>
4632 PR tree-optimization/87110
4633 * tree-ssa-dse.c (compute_trims): Handle non-constant
4636 2018-08-27 Martin Sebor <msebor@redhat.com>
4638 PR tree-optimization/86914
4639 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
4641 2018-08-27 Martin Sebor <msebor@redhat.com>
4643 PR tree-optimization/87112
4644 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
4645 the type of the bound argument.
4647 2018-08-27 Jeff Law <law@redhat.com>
4649 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
4650 type does not have a TYPE_SIZE_UNIT.
4652 2018-08-27 Steve Ellcey <sellcey@cavium.com>
4654 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
4655 with include of backend.h.
4657 2018-08-27 Richard Biener <rguenther@suse.de>
4659 PR tree-optimization/86927
4660 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
4661 use const cond reduction code.
4663 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
4665 PR tree-optimization/85758
4666 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
4668 2018-08-27 David Malcolm <dmalcolm@redhat.com>
4671 * diagnostic-show-locus.c (class layout_range): Update for
4672 conversion of show_caret_p to a tri-state.
4673 (layout_range::layout_range): Likewise.
4674 (make_range): Likewise.
4675 (layout::maybe_add_location_range): Likewise.
4676 (layout::should_print_annotation_line_p): Don't show annotation
4677 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
4678 (layout::get_state_at_point): Update for conversion of
4679 show_caret_p to a tri-state. Bail out early for
4680 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
4681 underlining or source colorization.
4682 (gcc_rich_location::add_location_if_nearby): Update for conversion
4683 of show_caret_p to a tri-state.
4684 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
4685 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
4687 (selftest::test_one_liner_labels): Likewise.
4688 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
4689 conversion of show_caret_p to a tri-state.
4690 * pretty-print.c (text_info::set_location): Likewise.
4691 * pretty-print.h (text_info::set_location): Likewise.
4692 * substring-locations.c (format_warning_n_va): Likewise.
4693 * tree-diagnostic.c (default_tree_printer): Likewise.
4694 * tree-pretty-print.c (newline_and_indent): Likewise.
4696 2018-08-27 David Malcolm <dmalcolm@redhat.com>
4699 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
4700 line above for line-insertion fix-it hints.
4701 (selftest::test_fixit_insert_containing_newline): Update the
4702 expected results, and add a test with line-numbering enabled.
4704 2018-08-27 Martin Liska <mliska@suse.cz>
4707 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
4708 params with DECL_HAS_VALUE_EXPR_P.
4710 2018-08-27 Martin Liska <mliska@suse.cz>
4712 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
4713 selected expansion strategy.
4715 2018-08-27 Martin Liska <mliska@suse.cz>
4717 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
4718 * builtins.c (is_builtin_fn): Likewise.
4719 * attribs.c (diag_attr_exclusions): Use new function
4720 fndecl_built_in_p and remove check for FUNCTION_DECL if
4722 (builtin_mathfn_code): Likewise.
4723 (fold_builtin_expect): Likewise.
4724 (fold_call_expr): Likewise.
4725 (fold_builtin_call_array): Likewise.
4726 (fold_call_stmt): Likewise.
4727 (set_builtin_user_assembler_name): Likewise.
4728 (is_simple_builtin): Likewise.
4729 * calls.c (gimple_alloca_call_p): Likewise.
4730 (maybe_warn_nonstring_arg): Likewise.
4731 * cfgexpand.c (expand_call_stmt): Likewise.
4732 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
4733 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
4734 (cgraph_node::verify_node): Likewise.
4735 * cgraphclones.c (build_function_decl_skip_args): Likewise.
4736 (cgraph_node::create_clone): Likewise.
4737 * config/arm/arm.c (arm_insert_attributes): Likewise.
4738 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
4739 * dse.c (scan_insn): Likewise.
4740 * expr.c (expand_expr_real_1): Likewise.
4741 * fold-const.c (operand_equal_p): Likewise.
4742 (fold_binary_loc): Likewise.
4743 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
4744 * gimple-low.c (lower_stmt): Likewise.
4745 * gimple-pretty-print.c (dump_gimple_call): Likewise.
4746 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
4748 * gimple.c (gimple_build_call_from_tree): Likewise.
4749 (gimple_call_builtin_p): Likewise.
4750 (gimple_call_combined_fn): Likewise.
4751 * gimplify.c (gimplify_call_expr): Likewise.
4752 (gimple_boolify): Likewise.
4753 (gimplify_modify_expr): Likewise.
4754 (gimplify_addr_expr): Likewise.
4755 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
4756 * ipa-cp.c (determine_versionability): Likewise.
4757 * ipa-fnsummary.c (compute_fn_summary): Likewise.
4758 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
4759 * ipa-split.c (visit_bb): Likewise.
4760 (split_function): Likewise.
4761 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
4762 * lto-cgraph.c (input_node): Likewise.
4763 * lto-streamer-out.c (write_symbol): Likewise.
4764 * omp-low.c (setjmp_or_longjmp_p): Likewise.
4765 (lower_omp_1): Likewise.
4766 * predict.c (strip_predict_hints): Likewise.
4767 * print-tree.c (print_node): Likewise.
4768 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
4769 * trans-mem.c (is_tm_irrevocable): Likewise.
4770 (is_tm_load): Likewise.
4771 (is_tm_simple_load): Likewise.
4772 (is_tm_store): Likewise.
4773 (is_tm_simple_store): Likewise.
4774 (is_tm_abort): Likewise.
4775 (tm_region_init_1): Likewise.
4776 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
4777 * tree-cfg.c (verify_gimple_call): Likewise.
4778 (move_stmt_r): Likewise.
4779 (stmt_can_terminate_bb_p): Likewise.
4780 * tree-eh.c (lower_eh_constructs_2): Likewise.
4781 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
4782 * tree-inline.c (remap_gimple_stmt): Likewise.
4783 (copy_bb): Likewise.
4784 (estimate_num_insns): Likewise.
4785 (fold_marked_statements): Likewise.
4786 * tree-sra.c (scan_function): Likewise.
4787 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
4788 (optimize_stack_restore): Likewise.
4789 (pass_fold_builtins::execute): Likewise.
4790 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
4791 (mark_all_reaching_defs_necessary_1): Likewise.
4792 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
4793 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
4794 (pass_forwprop::execute): Likewise.
4795 * tree-ssa-loop-im.c (stmt_cost): Likewise.
4796 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
4797 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
4798 * tree-ssa-strlen.c (get_string_length): Likewise.
4799 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
4800 (find_func_aliases_for_call): Likewise.
4801 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
4802 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
4803 * tree-tailcall.c (find_tail_calls): Likewise.
4804 * tree.c (need_assembler_name_p): Likewise.
4805 (free_lang_data_in_decl): Likewise.
4806 (get_call_combined_fn): Likewise.
4807 * ubsan.c (is_ubsan_builtin_p): Likewise.
4808 * varasm.c (incorporeal_function_p): Likewise.
4809 * tree.h (DECL_BUILT_IN): Remove and replace with
4811 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
4812 (fndecl_built_in_p): New.
4814 2018-08-27 Martin Liska <mliska@suse.cz>
4816 PR tree-optimization/86847
4817 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
4818 Dump also subtree probability.
4819 (switch_decision_tree::do_jump_if_equal): New function.
4820 (switch_decision_tree::emit_case_nodes): Handle special
4821 situations in balanced tree that can be emitted much simpler.
4822 Fix calculation of probabilities that happen in tree expansion.
4823 * tree-switch-conversion.h (struct cluster): Add
4825 (struct simple_cluster): Likewise.
4826 (struct case_tree_node): Add new function has_child.
4827 (do_jump_if_equal): New.
4829 2018-08-27 Martin Liska <mliska@suse.cz>
4831 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
4832 Add new argument to bit_test_cluster constructor.
4833 (bit_test_cluster::emit): Set bits really number of values
4835 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
4836 probability argument.
4837 * tree-switch-conversion.h (struct bit_test_cluster):
4838 Add m_handles_entire_switch.
4840 2018-08-27 Martin Liska <mliska@suse.cz>
4842 PR tree-optimization/86702
4843 * tree-switch-conversion.c (jump_table_cluster::emit):
4844 Make probabilities even for values in jump table
4845 according to number of cases handled.
4846 (switch_decision_tree::compute_cases_per_edge): Pass
4847 argument to reset_out_edges_aux function.
4848 (switch_decision_tree::analyze_switch_statement): Likewise.
4849 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
4852 2018-08-27 Martin Liska <mliska@suse.cz>
4854 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
4855 cfun argument explicitly.
4856 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
4857 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
4858 function gimple_switch_default_bb.
4859 (convert_switch_statements):
4861 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
4862 * stmt.c (label_to_block_fn): Use label_to_block and pass
4863 cfun argument explicitly and use gimple_switch_label_bb.
4864 (expand_case): Likewise.
4865 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
4866 cfun argument explicitly. Likewise.
4867 (make_edges_bb): Likewise.
4868 (make_cond_expr_edges): Likewise.
4869 (get_cases_for_edge): Likewise.
4870 (make_gimple_switch_edges): Likewise.
4871 (label_to_block_fn): Likewise.
4872 (label_to_block): Likewise.
4873 (make_goto_expr_edges): Likewise.
4874 (make_gimple_asm_edges): Likewise.
4875 (main_block_label): Likewise.
4876 (group_case_labels_stmt): Likewise.
4877 (find_taken_edge_computed_goto): Likewise.
4878 (find_taken_edge_switch_expr): Likewise.
4879 (gimple_verify_flow_info): Likewise.
4880 (gimple_redirect_edge_and_branch): Likewise.
4881 (gimple_switch_label_bb): New function.
4882 (gimple_switch_default_bb): Likewise.
4883 (gimple_switch_edge): Likewise.
4884 (gimple_switch_default_edge): Likewise.
4885 * tree-cfg.h (label_to_block_fn): Remove and replace ...
4886 (label_to_block): ... with this.
4887 (gimple_switch_label_bb): New.
4888 (gimple_switch_default_bb): Likewise.
4889 (gimple_switch_edge): Likewise.
4890 (gimple_switch_default_edge): Likewise.
4891 * tree-cfgcleanup.c (convert_single_case_switch): Use
4892 new gimple functions and pass new argument to label_to_block.
4893 (cleanup_control_flow_bb):
4894 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
4895 cfun argument explicitly.
4896 (make_eh_edges): Likewise.
4897 (redirect_eh_dispatch_edge): Likewise.
4898 (lower_resx): Likewise.
4899 (lower_eh_dispatch): Likewise.
4900 (maybe_remove_unreachable_handlers): Likewise.
4901 (unsplit_eh): Likewise.
4902 (cleanup_empty_eh): Likewise.
4903 (verify_eh_edges): Likewise.
4904 (verify_eh_dispatch_edge): Likewise.
4905 * tree-ssa-dom.c (record_edge_info): Likewise.
4906 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
4907 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
4908 (thread_through_normal_block): Likewise.
4909 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
4910 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
4911 * tree-switch-conversion.c (switch_conversion::collect): Use new
4913 (switch_conversion::check_final_bb): Likewise.
4914 (switch_conversion::gather_default_values): Pass new argument
4916 (switch_conversion::build_constructors): Likewise.
4917 (switch_decision_tree::compute_cases_per_edge): Use new
4918 gimple_switch_edge function.
4919 (switch_decision_tree::analyze_switch_statement): Pass new argument
4921 (switch_decision_tree::try_switch_expansion): Use
4922 gimple_switch_default_edge.
4923 * tree-vrp.c (find_switch_asserts): Pass new argument
4925 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
4926 (vr_values::simplify_switch_using_ranges): Likewise.
4928 2018-08-27 Richard Biener <rguenther@suse.de>
4930 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
4931 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
4933 * tree-ssa-sccvn.h (struct vn_pval): New structure.
4934 (struct vn_nary_op_s): Add unwind_to member. Add
4935 predicated_values flag and put result into a union together
4936 with a linked list of vn_pval.
4937 (struct vn_ssa_aux): Add name member to make maintaining
4938 a map of SSA name to vn_ssa_aux possible. Remove no longer
4939 needed info, dfsnum, low, visited, on_sccstack, use_processed
4940 and range_info_anti_range_p members.
4941 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
4942 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
4944 (vn_valueize): New global.
4945 (vn_context_bb): Likewise.
4946 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
4947 VN_INFO_PTR_INFO): Remove.
4948 * tree-ssa-sccvn.c: ... (rewrite)
4949 (pass_fre::execute): For -O2+ initialize loops and run
4950 RPO VN in optimistic mode (iterating). For -O1 and -Og
4951 run RPO VN in non-optimistic mode.
4952 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
4953 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
4954 * doc/invoke.texi (sccvn-max-scc-size): Remove.
4955 (rpo-vn-max-loop-depth): Document.
4956 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
4957 when valuezing the VUSE signals we walked out of the region.
4958 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
4959 (phi_translate): Set VN context block to use for availability
4961 (compute_avail): Likewise.
4962 (pre_valueize): New function.
4963 (pass_pre::execute): Adjust to the RPO VN API.
4965 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
4966 (propagate_constants_for_unrolling): Remove.
4967 (tree_unroll_loops_completely): Perform value-numbering
4968 on the unrolled bodies loop parent.
4970 2018-08-27 Richard Biener <rguenther@suse.de>
4972 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
4973 for partial antic compute.
4975 2018-08-27 Jakub Jelinek <jakub@redhat.com>
4977 PR rtl-optimization/87065
4978 * combine.c (simplify_if_then_else): Formatting fix.
4979 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
4981 (known_cond): Don't return const_true_rtx for vector modes. Use
4982 CONST0_RTX instead of const0_rtx. Formatting fixes.
4984 2018-08-27 Martin Liska <mliska@suse.cz>
4986 PR gcov-profile/87069
4987 * gcov.c (process_file): Record files already processed
4988 and warn about a file being processed multiple times.
4990 2018-08-27 Martin Liska <mliska@suse.cz>
4993 * config/aarch64/aarch64.c (aarch64_override_options_internal):
4994 Set default values for x_aarch64_*_string strings.
4995 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
4996 prefix. For -mabi do not print '=ABI' in help and use
4997 <option_value> format for -msve-vector-bits and -moverride
5000 2018-08-26 Jeff Law <law@redhat.com>
5002 * config/mips/frame-header-opt.c: Include "backend.h" rather than
5005 2018-08-26 Marek Polacek <polacek@redhat.com>
5007 PR c++/87029, Implement -Wredundant-move.
5008 * doc/invoke.texi: Document -Wredundant-move.
5010 2018-08-25 Martin Sebor <msebor@redhat.com>
5012 PR tree-optimization/87059
5013 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
5014 to the same type as the other.
5015 * fold-const.c (fold_binary_loc): Assert expectation.
5017 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
5019 * config/darwin.c (machopic_legitimize_pic_address): Clean up
5020 extraneous parentheses, dead code section and formatting.
5022 2018-08-24 David Malcolm <dmalcolm@redhat.com>
5025 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
5026 wide enough for jumps in the line-numbering to be visible.
5027 (layout::print_gap_in_line_numbering): New member function.
5028 (layout::calculate_line_spans): When using line numbering, merge
5029 line spans that are only 1 line apart.
5030 (diagnostic_show_locus): When printing line numbers, show gaps in
5031 line numbering directly, rather than printing headers.
5032 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
5033 line-numbering with multiple line spans.
5034 (selftest::test_fixit_insert_containing_newline_2): Add test of
5035 line-numbering, in which the spans are close enough to be merged.
5037 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
5039 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
5040 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
5041 * tree-vrp.c (range_is_nonnull): Remove.
5042 (range_includes_zero_p): Accept value_range instead of min/max.
5043 (extract_range_from_binary_expr_1): Do not early bail on
5045 Use range_includes_zero_p instead of range_is_nonnull.
5046 (extract_range_from_unary_expr): Use range_includes_zero_p instead
5047 of range_is_nonnull.
5048 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
5049 special case VR_ANTI_RANGE.
5050 (vrp_finalize): Same.
5051 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
5053 (range_is_nonnull): Remove.
5054 * vr-values.c (vrp_stmt_computes_nonzero): Use
5055 range_includes_zero_p instead of range_is_nonnull.
5056 (extract_range_basic): Pass value_range to range_includes_zero_p
5057 instead of range_is_nonnull.
5059 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
5061 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
5062 * emit-rtl.h (rtl_data): Remove return_bnd.
5063 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
5064 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
5065 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
5066 (POINTER_BOUNDS_MODE): Remove definition.
5067 (make_pointer_bounds_mode): Remove.
5068 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
5069 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
5070 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
5071 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
5072 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
5073 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
5074 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
5076 * config/i386/i386-modes.def (BND32, BND64): Remove.
5077 * config/i386/i386.c (dbx_register_map): Remove bound registers.
5078 (dbx64_register_map): Ditto.
5079 (svr4_dbx_register_map): Ditto.
5080 (indirect_thunk_bnd_needed): Remove.
5081 (indirect_thunks_bnd_used): Ditto.
5082 (indirect_return_bnd_needed): Ditto.
5083 (indirect_return_via_cx_bnd): Ditto.
5084 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
5085 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
5086 (output_indirect_thunk): Ditto. Remove need_prefix argument.
5087 (output_indirect_thunk_function): Remove handling of
5088 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
5089 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
5090 (ix86_save_reg): Remove handling of crtl->return_bnd.
5091 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
5092 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
5093 and UNSPEC_BNDLX_ADDR.
5094 (ix86_output_indirect_branch_via_reg): Remove handling of
5095 indirect_thunk_prefix_bnd.
5096 (ix86_output_indirect_branch_via_push): Ditto.
5097 (ix86_output_function_return): Ditto.
5098 (ix86_output_indirect_function_return): Ditto.
5099 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
5100 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
5101 (CALL_USED_REGISTERS): Ditto.
5102 (REG_ALLOC_ORDER): Update for removal of bound registers.
5103 (HI_REGISTER_NAMES): Ditto.
5104 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
5105 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
5106 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
5107 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
5108 (FIRST_PSEUDO_REG): Update.
5109 (BND): Remove mode iterator.
5110 * config/i386/predicates.md (bnd_mem_operator): Remove.
5112 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
5114 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
5117 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
5119 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
5120 the case in which the permute needs only a single element and
5121 repeats for every vector of the result. Extend that case to
5122 handle variable-length vectors.
5123 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
5125 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
5128 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
5129 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
5131 2018-08-24 Richard Biener <rguenther@suse.de>
5133 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
5134 bb_flags_allocated members.
5135 (auto_flag): New RAII class for allocating flags.
5136 (auto_edge_flag): New RAII class for allocating edge flags.
5137 (auto_bb_flag): New RAII class for allocating bb flags.
5138 * cfgloop.c (verify_loop_structure): Allocate temporary edge
5140 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
5141 in favor of temporarily allocated BB flag.
5142 * hsa-brig.c: Re-order includes.
5143 * hsa-dump.c: Likewise.
5144 * hsa-regalloc.c: Likewise.
5145 * print-rtl.c: Likewise.
5146 * profile-count.c: Likewise.
5148 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
5151 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
5154 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
5157 * wide-int-range.cc (wide_int_range_div): Do not ignore result
5158 from wide_int_range_multiplicative_op.
5160 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
5162 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
5165 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
5167 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
5170 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
5172 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
5173 full GENERIC expression used for replacement.
5175 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
5177 * tree-vrp.c (abs_extent_range): Remove.
5178 (extract_range_into_wide_ints): Pass wide ints by reference.
5179 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
5180 Pass wide ints by reference in all calls to
5181 extract_range_into_wide_ints.
5182 * wide-int-range.cc (wide_int_range_div): New.
5183 * wide-int-range.h (wide_int_range_div): New.
5184 (wide_int_range_includes_zero_p): New.
5185 (wide_int_range_zero_p): New.
5187 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
5189 * config/aarch64/aarch64.md (arches): New enum.
5190 (arch): New enum attr.
5191 (arch_enabled): New attr.
5192 (enabled): Now uses arch_enabled only.
5193 (simd, sve, fp16): Removed attribute.
5194 (fp): Attr now defined in terms of 'arch'.
5195 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
5196 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
5197 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
5198 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
5199 attributes into 'arch'.
5200 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
5201 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
5202 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
5203 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
5204 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
5205 'simd' attribute into 'arch'.
5206 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
5207 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
5208 Convert use of 'fp' attribute to 'arch'.
5209 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
5210 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
5212 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
5213 (different modes) Merge 'fp' and 'simd' into 'arch'.
5214 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
5217 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
5219 PR rtl-optimization/87026
5220 * expmed.c (canonicalize_comparison): If we can no longer create
5221 pseudoregisters, don't.
5223 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
5226 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
5228 * config/arm/arm.c (speculation_barrier_libfunc): New static
5230 (arm_init_libfuncs): Initialize it.
5231 (arm_emit_speculation_barrier): New function.
5232 * config/arm/arm.md (speculation_barrier): Call
5233 arm_emit_speculation_barrier for architectures that do not have
5235 (speculation_barrier_insn): Only match on Armv7 or later.
5237 2018-08-23 Richard Biener <rguenther@suse.de>
5240 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
5243 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
5245 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
5246 of single-vector TBLs.
5247 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
5250 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
5253 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
5254 aarch64_evpc_tbl guard.
5256 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
5258 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
5261 2018-08-22 Martin Sebor <msebor@redhat.com>
5264 * tree-pretty-print.c (pretty_print_string): Add argument.
5265 (dump_generic_node): Call to pretty_print_string with string size.
5267 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
5269 PR rtl-optimization/86771
5270 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
5271 of two SETs into those two SETs, one to be placed at i2, if that SETs
5272 destination is modified between i2 and i3.
5274 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
5276 PR tree-optimization/86725
5277 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
5279 (vect_analyze_scalar_cycles_1): Check it.
5281 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
5283 PR tree-optimization/86725
5284 * tree-vect-loop.c (vect_is_simple_reduction): When treating
5285 an outer loop phi as a double reduction, make sure that the
5286 single user of the phi result is an inner loop phi.
5288 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
5290 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
5291 grouped stores with gaps to a strided group.
5293 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
5295 * tree-vect-stmts.c (get_group_load_store_type)
5296 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
5297 first statement in a group.
5299 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
5301 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
5302 the sequence used in gcc/gcc.c.
5304 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
5307 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
5310 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
5312 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
5313 Darwin10-specific unwinder-shim.
5314 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
5315 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
5316 New to cater for Darwin10 Rosetta.
5318 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
5320 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
5321 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
5323 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
5328 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
5329 (dwarf2out_switch_text_section): Generate a local label for the
5330 second function sub-section and apply it as the second FDE start
5332 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
5333 second sub-section start.
5335 2018-08-22 Richard Biener <rguenther@suse.de>
5337 PR tree-optimization/86988
5338 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
5340 2018-08-22 Richard Biener <rguenther@suse.de>
5342 PR tree-optimization/86945
5343 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
5345 2018-08-22 Alexandre Oliva <oliva@adacore.com>
5347 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
5348 a comment about how uses of r2 for .sdata2 come about.
5350 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
5352 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
5354 2018-08-21 Marek Polacek <polacek@redhat.com>
5356 PR c++/86981, Implement -Wpessimizing-move.
5357 * doc/invoke.texi: Document -Wpessimizing-move.
5359 2018-08-21 Jan Hubicka <jh@suse.cz>
5361 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
5362 * tree.h (is_redundant_typedef): Remove.
5363 * dwarf2out.c (is_redundant_typedef): Turn into static function.
5365 2018-08-21 Jan Hubicka <jh@suse.cz>
5367 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
5370 2018-08-21 Tamar Christina <tamar.christina@arm.com>
5372 * expmed.c (extract_low_bits): Reject invalid subregs early.
5374 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5377 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
5380 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
5382 * config/vxworks.h: Guard vxworks_asm_out_constructor and
5383 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
5384 * config/vxworks.c: Likewise.
5386 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
5388 * config/vxworks.c: Set targetm.have_ctors_dtors
5389 if HAVE_INITFINI_ARRAY_SUPPORT.
5390 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
5391 if HAVE_INITFINI_ARRAY_SUPPORT.
5393 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
5395 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
5396 default search path for VxWorks < 7.
5398 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5400 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
5401 (get_format_string): Refer to c_getstr.
5403 2018-08-21 Tom de Vries <tdevries@suse.de>
5405 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
5406 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
5407 (debuginfo_early_stop): Declare.
5408 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
5409 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
5410 (debuginfo_early_stop): New function.
5411 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
5412 and debuginfo_early_stop.
5413 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
5414 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
5415 (general_init): Call debuginfo_early_init.
5416 (finalize): Call debuginfo_fini.
5417 (do_compile): Call debuginfo_init.
5418 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
5420 (@item -fdump-debug, @item -fdump-earlydebug): Add.
5422 2018-08-21 Tom de Vries <tdevries@suse.de>
5424 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
5425 flag_dump_noaddr and flag_dump_unnumbered.
5427 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
5429 * wide-int-range.cc (wide_int_range_abs): New.
5430 (wide_int_range_order_set): Rename from wide_int_range_min_max.
5431 * wide-int-range.h (wide_int_range_abs): New.
5432 (wide_int_range_min_max): New.
5433 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
5434 case to call wide_int_range_abs.
5435 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
5436 (extract_range_from_abs_expr): Delete.
5438 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
5441 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
5442 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
5445 2018-08-20 Nathan Sidwell <nathan@acm.org>
5446 Jeff Law <law@redhat.com>
5448 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
5449 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
5451 2018-08-20 David Malcolm <dmalcolm@redhat.com>
5454 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
5455 (decl_attributes): Likewise.
5456 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
5458 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
5459 * diagnostic-core.h (class auto_diagnostic_group): New class.
5460 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
5461 (diagnostic_report_diagnostic): Handle the first diagnostics within
5463 (emit_diagnostic): Add auto_diagnostic_group instance.
5465 (inform_n): Likewise.
5466 (warning): Likewise.
5467 (warning_at): Likewise.
5468 (warning_n): Likewise.
5469 (pedwarn): Likewise.
5470 (permerror): Likewise.
5472 (error_n): Likewise.
5473 (error_at): Likewise.
5475 (fatal_error): Likewise.
5476 (internal_error): Likewise.
5477 (internal_error_no_backtrace): Likewise.
5478 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
5479 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
5480 * diagnostic.h (struct diagnostic_context): Add fields
5481 "diagnostic_group_nesting_depth",
5482 "diagnostic_group_emission_count", "begin_group_cb",
5484 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
5485 Add auto_diagnostic_group instance(s).
5486 (find_explicit_erroneous_behavior): Likewise.
5487 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
5488 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
5489 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
5490 (gimplify_va_arg_expr): Likewise.
5491 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
5492 (HSA_SORRY_AT): Likewise.
5493 * ipa-devirt.c (compare_virtual_tables): Likewise.
5494 (warn_odr): Likewise.
5495 * multiple_target.c (expand_target_clones): Likewise.
5496 * opts-common.c (cmdline_handle_error): Likewise.
5497 * reginfo.c (globalize_reg): Likewise.
5498 * substring-locations.c (format_warning_n_va): Likewise.
5499 * tree-inline.c (expand_call_inline): Likewise.
5500 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
5501 * tree-ssa-loop-niter.c
5502 (do_warn_aggressive_loop_optimizations): Likewise.
5503 * tree-ssa-uninit.c (warn_uninit): Likewise.
5504 * tree.c (warn_deprecated_use): Likewise.
5506 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
5509 * config/i386/i386.md (eh_return): Always update EH return
5510 address in word_mode.
5512 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
5514 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
5515 TARGET_SPLIT_COMPLEX_ARG is defined.
5517 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
5519 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
5521 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
5524 * expr.c (expand_assignment): Assert that bitpos is positive.
5525 (store_field): Likewise
5526 (expand_expr_real_1): Make sure that bitpos is positive.
5527 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
5530 2018-08-20 Nathan Sidwell <nathan@acm.org>
5532 * Makefile.in (CPP_ID_DATA_H): Delete.
5533 (CPP_INTERNAL_H): Don't add it.
5534 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
5535 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
5537 2018-08-20 Richard Biener <rguenther@suse.de>
5539 PR tree-optimization/78655
5540 * tree-vrp.c (extract_range_from_binary_expr_1): Make
5541 pointer + offset nonnull if either operand is nonnull work.
5543 2018-08-20 Tom de Vries <tdevries@suse.de>
5545 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
5546 unless the referenced die describes the added property using
5547 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
5548 Otherwise, add a DW_AT_location to the referenced die.
5550 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
5553 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
5554 register_operand when calling ix86_set_reg_reg_cost.
5555 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
5556 Set *total to 0 for operands that satisfy x86_64_immediate_operand
5557 predicate and to 1 otherwise.
5559 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
5561 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
5562 emit a diagnostic that it is not supported and reset the option.
5563 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
5564 supported and consume the option. (ASM_FINAL_SPEC): New.
5566 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
5568 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
5571 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
5573 C-SKY port: Documentation
5575 * doc/extend.texi (C-SKY Function Attributes): New section.
5576 * doc/invoke.texi (Option Summary): Add C-SKY options.
5577 (C-SKY Options): New section.
5578 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
5580 2018-08-17 Jojo <jijie_rong@c-sky.com>
5581 Huibin Wang <huibin_wang@c-sky.com>
5582 Sandra Loosemore <sandra@codesourcery.com>
5583 Chung-Lin Tang <cltang@codesourcery.com>
5585 C-SKY port: Backend implementation
5587 * config/csky/*: New.
5588 * common/config/csky/*: New.
5590 2018-08-17 Jojo <jijie_rong@c-sky.com>
5591 Huibin Wang <huibin_wang@c-sky.com>
5592 Sandra Loosemore <sandra@codesourcery.com>
5593 Chung-Lin Tang <cltang@codesourcery.com>
5594 Andrew Jenner <andrew@codesourcery.com>
5596 C-SKY port: Configury
5598 * config.gcc (csky-*-*): New.
5599 * configure.ac: Add csky to targets for dwarf2 debug_line support.
5600 * configure: Regenerated.
5602 2018-08-17 David Malcolm <dmalcolm@redhat.com>
5604 * dump-context.h: Include "dumpfile.h".
5605 (dump_context::dump_printf_va): Convert final param from va_list
5606 to va_list *. Convert from ATTRIBUTE_PRINTF to
5607 ATTRIBUTE_GCC_DUMP_PRINTF.
5608 (dump_context::dump_printf_loc_va): Likewise.
5609 * dumpfile.c: Include "stringpool.h".
5610 (make_item_for_dump_printf_va): Delete.
5611 (make_item_for_dump_printf): Delete.
5612 (class dump_pretty_printer): New class.
5613 (dump_pretty_printer::dump_pretty_printer): New ctor.
5614 (dump_pretty_printer::emit_items): New member function.
5615 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
5617 (dump_pretty_printer::emit_item): New member function.
5618 (dump_pretty_printer::stash_item): New member function.
5619 (dump_pretty_printer::format_decoder_cb): New member function.
5620 (dump_pretty_printer::decode_format): New member function.
5621 (dump_context::dump_printf_va): Reimplement in terms of
5622 dump_pretty_printer.
5623 (dump_context::dump_printf_loc_va): Convert final param from va_list
5625 (dump_context::begin_scope): Reimplement call to
5626 make_item_for_dump_printf.
5627 (dump_printf): Update for change to dump_printf_va.
5628 (dump_printf_loc): Likewise.
5629 (selftest::test_capture_of_dump_calls): Convert "stmt" from
5630 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
5631 with %T, %E, and %G.
5632 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
5633 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
5634 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
5635 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
5636 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
5637 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
5638 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
5639 within a dump_printf_loc call to "%wu".
5640 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
5641 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
5642 missing space after "=".
5643 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
5644 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
5645 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
5646 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
5647 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
5648 duplicate "vectorized" from message.
5650 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
5652 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
5653 polyNxK_t element's TYPE_STRING_FLAG.
5655 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
5657 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
5658 (they were unnamed before). Fix comments.
5660 2018-08-17 Nathan Sidwell <nathan@acm.org>
5662 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
5664 2018-08-17 Richard Biener <rguenther@suse.de>
5666 PR tree-optimization/86841
5667 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
5669 2018-08-17 Martin Liska <mliska@suse.cz>
5671 * common.opt: Remove Warn, Init and Report for options with
5672 Ignore/Deprecated flag. Warning is done automatically for
5674 * config/i386/i386.opt: Likewise.
5675 * config/ia64/ia64.opt: Likewise.
5676 * config/rs6000/rs6000.opt: Likewise.
5677 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
5678 Remove usage of flag_check_pointer_bounds.
5679 * lto-wrapper.c (merge_and_complain): Do not handle
5680 OPT_fcheck_pointer_bounds.
5681 (append_compiler_options): Likewise.
5682 * opt-functions.awk: Do not handle Deprecated.
5683 * optc-gen.awk: Check that Var, Report and Init are not
5684 used for an option with Ignore/Deprecated flag.
5685 * opts-common.c (decode_cmdline_option): Do not report
5687 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
5689 * opts.h (struct cl_option): Remove cl_deprecated flag.
5690 (CL_ERR_DEPRECATED): Remove error enum value.
5692 2018-08-17 Richard Biener <rguenther@suse.de>
5695 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
5696 across a va-arg-pack using call adjust its return value accordingly.
5698 2018-08-16 Martin Sebor <msebor@redhat.com>
5700 PR tree-optimization/86853
5701 * gimple-ssa-sprintf.c (struct format_result): Rename member.
5702 (struct fmtresult): Add member and initialize it in ctors.
5703 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
5704 (format_string): Handle %S the same as %ls. Set MAYFAIL.
5705 (format_directive): Set POSUNDER4K when MAYFAIL is set.
5706 (parse_directive): Handle %C same as %c.
5707 (sprintf_dom_walker::compute_format_length): Adjust.
5708 (is_call_safe): Adjust.
5710 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
5712 * builtins.c (c_strlen): Add new parameter eltsize. Use it
5713 for determining how to count the elements.
5714 * builtins.h (c_strlen): Adjust prototype.
5715 * expr.c (string_constant): Add new parameter mem_size.
5716 Set *mem_size appropriately.
5717 * expr.h (string_constant): Adjust protoype.
5718 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
5719 * gimple-fold.h (get_range_strlen): Adjust prototype.
5720 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
5721 (format_string): Call get_string_length with eltsize.
5723 2018-08-16 David Malcolm <dmalcolm@redhat.com>
5725 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
5726 to emit the span, rather than setting it as the prefix.
5728 2018-08-16 David Malcolm <dmalcolm@redhat.com>
5730 * diagnostic-show-locus.c (layout::start_annotation_line): Add
5731 "margin_char" parameter, defaulting to space. Use it in place
5732 of pp_space for the initial part of the margin.
5733 (layout::print_leading_fixits): Use '+' when filling the margin
5734 of line-insertion fix-it hints.
5736 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
5738 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
5741 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
5743 * config/rs6000/altivec.md: Don't set length attribute to the default
5745 * config/rs6000/darwin.md: Ditto.
5746 * config/rs6000/dfp.md: Ditto.
5747 * config/rs6000/htm.md: Ditto.
5748 * config/rs6000/rs6000.md: Ditto.
5749 * config/rs6000/sync.md: Ditto.
5750 * config/rs6000/vsx.md: Ditto.
5752 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
5754 * config/rs6000/altivec.md: Don't set length attribute to the default
5755 value, for branch instructions.
5756 * config/rs6000/darwin.md: Ditto.
5757 * config/rs6000/rs6000.md: Ditto.
5759 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
5761 * config/rs6000/rs6000.md (length): Always define as const_int 4.
5762 (unnamed conditional branch define_insn): Set length to 4 or 8
5763 depending on offset.
5764 (<bd>_<mode>): Similar, for alternative 0.
5765 (<bd>tf_<mode>): Ditto.
5767 2018-08-16 Tamar Christina <tamar.christina@arm.com>
5769 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
5771 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
5773 * doc/rtl.texi: Replace old RTX class names with new names.
5776 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
5778 * expmed.h (canonicalize_comparison): New declaration.
5779 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
5780 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
5781 * optabs.c (prepare_cmp_insn): Likewise.
5782 * rtl.h (unsigned_condition_p): New function which checks if a
5783 comparison operator is unsigned.
5785 2018-08-16 Nathan Sidwell <nathan@acm.org>
5787 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
5788 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
5790 2018-08-16 Tamar Christina <tamar.christina@arm.com>
5793 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
5794 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
5795 (mov<mov>): ..this and enable unconditionally.
5797 2018-08-16 Tamar Christina <tamar.christina@arm.com>
5799 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
5801 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
5803 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
5804 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
5805 "Common" with "Target".
5807 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
5809 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
5810 * doc/invoke.texi (mmitigate-rop): Remove.
5811 * config/i386/i386.c: Do not include "regrename.h".
5812 (ix86_rop_should_change_byte_p, reg_encoded_number)
5813 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
5815 (ix86_reorg): Remove call to ix86_mitigate_rop.
5816 * config/i386/i386.md (attr "modrm_class"): Remove.
5817 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
5818 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
5819 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
5821 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
5823 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
5824 allow folding of mergeh() and mergel() for the float and double types.
5825 (fold_mergehl_helper): Rework to handle building a permute tree
5828 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
5830 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
5833 2018-08-15 David Malcolm <dmalcolm@redhat.com>
5835 * common.opt (fdiagnostics-show-labels): New option.
5836 * diagnostic-show-locus.c (class layout_range): Add field
5838 (class layout): Add field "m_show_labels_p".
5839 (layout_range::layout_range): Add param "label" and use it to
5841 (make_range): Pass in NULL for new "label" param of layout_range's
5843 (layout::layout): Initialize m_show_labels_p.
5844 (layout::maybe_add_location_range): Pass in loc_range->m_label
5845 when constructing layout_range instances.
5846 (struct line_label): New struct.
5847 (layout::print_any_labels): New member function.
5848 (layout::print_line): Call it if label-printing is enabled.
5849 (selftest::test_one_liner_labels): New test.
5850 (selftest::test_diagnostic_show_locus_one_liner): Call it.
5851 * diagnostic.c (diagnostic_initialize): Initialize
5852 context->show_labels_p.
5853 * diagnostic.h (struct diagnostic_context): Add field
5855 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
5856 -fno-diagnostics-show-labels.
5857 * dwarf2out.c (gen_producer_string): Add
5858 OPT_fdiagnostics_show_labels to the ignored options.
5859 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
5861 (gcc_rich_location::maybe_add_expr): Likewise.
5862 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
5863 label" param, defaulting to NULL.
5864 (gcc_rich_location::add_expr): Add "label" param.
5865 (gcc_rich_location::maybe_add_expr): Likewise.
5866 (class text_range_label): New class.
5867 (class range_label_for_type_mismatch): New class.
5868 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
5869 of format_warning_va.
5870 (fmtwarn_n): Likewise for new params of format_warning_n_va.
5871 * lto-wrapper.c (merge_and_complain): Add
5872 OPT_fdiagnostics_show_labels to the "pick one setting" options.
5873 (append_compiler_options): Likewise to the dropped options.
5874 (append_diag_options): Likewise to the passed-on options.
5875 * opts.c (common_handle_option): Handle the new option.
5876 * selftest-diagnostic.c
5877 (test_diagnostic_context::test_diagnostic_context): Enable
5879 * substring-locations.c: Include "gcc-rich-location.h".
5880 (format_warning_n_va): Add "fmt_label" and "param_label" params
5881 and use them as appropriate.
5882 (format_warning_va): Add "fmt_label" and "param_label" params,
5883 passing them on to format_warning_n_va.
5884 (format_warning_at_substring): Likewise.
5885 (format_warning_at_substring_n): Likewise.
5886 * substring-locations.h (format_warning_va): Add "fmt_label" and
5887 "param_label" params.
5888 (format_warning_n_va): Likewise.
5889 (format_warning_at_substring): Likewise.
5890 (format_warning_at_substring_n): Likewise.
5891 * toplev.c (general_init): Initialize global_dc->show_labels_p.
5893 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
5896 * builtins.c (expand_builtin_memcmp): Do not expand the call
5897 when overflow is detected.
5899 2018-08-15 Martin Sebor <msebor@redhat.com>
5901 PR tree-optimization/71625
5902 * config/aarch64/aarch64-builtins.c
5903 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
5905 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
5907 * config/s390/s390.c (s390_reorg): Remove loop.
5909 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
5912 (darwin_function_switched_text_sections): Delete.
5913 * gcc/config/darwin.h
5914 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
5916 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
5919 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
5920 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
5921 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
5923 2018-08-15 Martin Liska <mliska@suse.cz>
5925 PR tree-optimization/86925
5926 * predict.c (expr_expected_value_1): When taking
5927 later predictor, assign also probability.
5928 Use fold_build2_initializer_loc in order to fold
5929 the expression in -frounding-math.
5931 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
5933 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
5935 (expand_vec_perm_1): Try the new method.
5937 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
5940 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
5941 Check whether lra_live_max_point is 0 before dividing.
5943 2018-08-14 Martin Sebor <msebor@redhat.com>
5945 PR tree-optimization/86650
5946 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
5947 (vrp_prop::check_mem_ref): Same.
5949 2018-08-13 Liu Hao <lh_mouse@126.com>
5951 * pretty-print.c (eat_esc_sequence): Swap the foreground and
5952 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
5953 and clear it thereafter, as it only works for DBCS.
5955 2018-08-13 Liu Hao <lh_mouse@126.com>
5957 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
5958 handle returned by _get_osf_handle().
5960 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
5962 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
5963 for folding vec_perm.
5965 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
5967 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
5968 Add support for gimple-folding of vec_pack() and vec_unpack()
5971 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
5973 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
5974 vec_xst variants to the list.
5975 (rs6000_gimple_fold_builtin): Add support for folding unaligned
5976 vector loads and stores.
5978 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
5980 * config.gcc (rs6000-ibm-aix4.x): Delete.
5981 (rs6000-ibm-aix5.1): Delete.
5982 (rs6000-ibm-aix5.2): Delete.
5983 (rs6000-ibm-aix5.3): Delete.
5984 * config/rs6000/aix43.h: Delete.
5985 * config/rs6000/aix51.h: Delete.
5986 * config/rs6000/aix52.h: Delete.
5987 * config/rs6000/t-aix43: Delete.
5989 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
5991 * config/s390/s390.c (s390_decompose_constant_pool_ref):
5993 (s390_decompose_address): Factor out constant pool ref
5996 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
5998 * config/nds32/nds32-predicates.c
5999 (nds32_can_use_bclr_p): Change return type as bool.
6000 (nds32_can_use_bset_p): Ditto.
6001 (nds32_can_use_btgl_p): Ditto.
6002 (nds32_can_use_bitci_p): Ditto.
6003 * config/nds32/nds32-protos.h
6004 (nds32_can_use_bclr_p): Change declaration.
6005 (nds32_can_use_bset_p): Ditto.
6006 (nds32_can_use_btgl_p): Ditto.
6007 (nds32_can_use_bitci_p): Ditto.
6009 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
6011 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
6012 Support -msched-prolog-epilog option.
6013 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
6015 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
6017 * common/config/nds32/nds32-common.c
6018 (nds32_option_optimization_table): Enalbe -malways-align.
6020 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
6022 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
6024 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
6025 OPT_misr_secure_ case.
6026 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
6027 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
6028 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
6030 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
6031 (nds32_isr_info): New field security_level.
6032 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
6033 * config/nds32/nds32.md (return_internal): Consider critical attribute.
6034 * config/nds32/nds32.opt (misr-secure): New option.
6035 * config/nds32/nds32_init.inc: New file.
6036 * config/nds32/nds32_isr.h: New file.
6038 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
6040 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
6041 Update comment for atomic instructions.
6042 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
6043 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
6045 (atomic_loaddi): Revise fence expansion to only emit fence prior to
6046 load for __ATOMIC_SEQ_CST model.
6047 (atomic_loaddi_1): Remove float register target.
6048 (atomic_storedi): Handle CONST_INT values.
6049 (atomic_storedi_1): Remove float register source. Add special case
6051 (memory_barrier): New expander and insn.
6053 2018-08-11 Jakub Jelinek <jakub@redhat.com>
6055 PR tree-optimization/86835
6056 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
6057 new_stmt after def_gsi, make sure to insert new_square_stmt after
6058 that stmt, not 2 stmts before it.
6060 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
6063 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
6066 2018-08-10 Martin Liska <mliska@suse.cz>
6069 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
6071 * builtins.c (expand_builtin_expect_with_probability):
6073 (expand_builtin_expect_with_probability): New function.
6074 (build_builtin_expect_predicate): Add new argumnet probability
6075 for BUILT_IN_EXPECT_WITH_PROBABILITY.
6076 (fold_builtin_expect):
6079 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
6080 * builtins.h (fold_builtin_expect): Set new argument.
6081 * doc/extend.texi: Document __builtin_expect_with_probability.
6082 * doc/invoke.texi: Likewise.
6083 * gimple-fold.c (gimple_fold_call): Pass new argument.
6084 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
6085 also BUILT_IN_EXPECT_WITH_PROBABILITY.
6086 * predict.c (get_predictor_value): New function.
6087 (expr_expected_value): Add new argument probability. Assume
6088 that predictor and probability are always non-null.
6089 (expr_expected_value_1): Likewise. For __builtin_expect and
6090 __builtin_expect_with_probability set probability. Handle
6091 combination in binary expressions.
6092 (tree_predict_by_opcode): Simplify code by simply calling
6093 get_predictor_value.
6094 (pass_strip_predict_hints::execute): Add handling of
6095 BUILT_IN_EXPECT_WITH_PROBABILITY.
6096 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
6098 * tree.h (DECL_BUILT_IN_P): New function.
6100 2018-08-10 Martin Liska <mliska@suse.cz>
6102 PR tree-optimization/85799
6103 * passes.def: Add argument for pass_strip_predict_hints.
6104 * predict.c (class pass_strip_predict_hints): Add new argument
6106 (strip_predictor_early): New function.
6107 (pass_strip_predict_hints::execute): Call the function to
6109 (strip_predict_hints): New function.
6110 * predict.def: Fix comment.
6112 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
6114 * Makefile.in: Clarify which tm.texi to copy over to assert the
6115 right to grant a GFDL license for all.
6117 2018-08-09 Jeff Law <law@redhat.com>
6119 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
6122 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
6124 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
6127 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
6129 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
6130 reductions for variable-length vectors.
6132 2018-08-09 David Malcolm <dmalcolm@redhat.com>
6135 * common.opt (fdiagnostics-show-line-numbers): New option.
6136 * diagnostic-show-locus.c (class layout): Add fields
6137 "m_show_line_numbers_p" and "m_linenum_width";
6138 (num_digits): New function.
6139 (test_num_digits): New function.
6140 (layout::layout): Initialize new fields. Update m_x_offset
6141 logic to handle any left margin.
6142 (layout::print_source_line): Print line number when requested.
6143 (layout::start_annotation_line): New member function.
6144 (layout::print_annotation_line): Call it.
6145 (layout::print_leading_fixits): Likewise.
6146 (layout::print_trailing_fixits): Likewise. Update calls to
6147 move_to_column for new parameter.
6148 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
6149 it to potentially call start_annotation_line.
6150 (layout::show_ruler): Call start_annotation_line.
6151 (selftest::test_line_numbers_multiline_range): New selftest.
6152 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
6153 and selftest::test_line_numbers_multiline_range.
6154 * diagnostic.c (diagnostic_initialize): Initialize
6155 show_line_numbers_p.
6156 * diagnostic.h (struct diagnostic_context): Add field
6157 "show_line_numbers_p".
6158 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
6159 -fno-diagnostics-show-line-numbers.
6160 * dwarf2out.c (gen_producer_string): Add
6161 OPT_fdiagnostics_show_line_numbers to the ignored options.
6162 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
6163 one setting" options.
6164 (append_compiler_options): Likewise to the dropped options.
6165 (append_diag_options): Likewise to the passed-on options.
6166 * opts.c (common_handle_option): Handle the new option.
6167 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
6169 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
6171 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
6172 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
6173 third argument of type "const signed char" to descriptions of
6174 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
6175 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
6176 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
6177 __builtin_bcdsub_ov functions.
6179 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
6181 PR tree-optimization/86858
6182 * tree-vect-loop.c (vect_is_simple_reduction): Restore
6183 flow_bb_inside_loop_p calls.
6185 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
6187 PR tree-optimization/86871
6188 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
6189 instead of gimple_assign_lhs.
6191 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
6194 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
6195 register constraint to operand 0.
6196 (add<mode>3_carryinC): Likewise.
6197 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
6199 2018-08-09 Martin Liska <mliska@suse.cz>
6202 * common.opt: Remove extra line.
6204 2018-08-09 Martin Liska <mliska@suse.cz>
6206 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
6207 at the end of a line, make first letter capital and end up
6208 a sentence with a dot.
6209 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
6210 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
6211 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
6212 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
6213 (PARAM_MAX_ISL_OPERATIONS): Likewise.
6214 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
6215 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
6216 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
6217 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
6218 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
6219 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
6220 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
6221 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
6222 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
6223 (PARAM_TREE_REASSOC_WIDTH): Likewise.
6224 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
6225 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
6226 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
6228 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
6231 * config/s390/s390.c (s390_option_override_internal): Reduce the
6232 stack-clash-protection-probe-interval param if it would be too big
6235 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
6238 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
6239 * config/m68k/m68k.c (handle_move_double): Don't call
6240 m68k_final_prescan_insn.
6241 (m68k_adjust_decorated_operand): Renamed from
6242 m68k_final_prescan_insn, remove first and third operand and
6244 (print_operand): Call it.
6245 (print_operand_address): Call it.
6247 2018-08-08 Nathan Sidwell <nathan@acm.org>
6249 * diagnostic.c (diagnostic_report_current_module): Use
6250 linemap_included_from & linemap_included_from_linemap.
6252 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
6254 * config/aarch64/aarch64-cores.def: Add phecda core.
6255 * config/aarch64/aarch64-tune.md: Regenerate.
6256 * doc/invoke.texi: Add phecda core.
6258 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
6261 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
6263 * config/s390/s390.md ("movti"): Add more alternatives for
6264 constant to GPR copies.
6266 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
6268 * config/s390/s390.c: Fix whitespace damage throughout the file.
6269 * config/s390/s390.h: Likewise.
6270 * config/s390/tpf.h: Likewise.
6272 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
6274 * config/s390/s390.c (s390_loadrelative_operand_p):
6275 Remove TARGET_CPU_ZARCH usages.
6276 (s390_rtx_costs): Likewise.
6277 (s390_legitimate_constant_p): Likewise.
6278 (s390_cannot_force_const_mem): Likewise.
6279 (legitimate_reload_constant_p): Likewise.
6280 (s390_preferred_reload_class): Likewise.
6281 (legitimize_pic_address): Likewise.
6282 (legitimize_tls_address): Likewise.
6283 (s390_split_branches): Removed.
6284 (s390_add_execute): Removed.
6285 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
6286 (s390_mainpool_start): Likewise.
6287 (s390_mainpool_finish): Likewise.
6288 (s390_mainpool_cancel): Removed.
6289 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
6290 (s390_chunkify_cancel): Likewise.
6291 (s390_return_addr_rtx): Likewise.
6292 (s390_register_info): Remove split_branches_pending_p uages.
6293 (s390_optimize_register_info): Likewise.
6294 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
6295 split_branches_pending_p usages.
6296 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
6297 (s390_load_got): Likewise.
6298 (s390_expand_split_stack_prologue): Likewise.
6299 (output_asm_nops): Likewise.
6300 (s390_function_profiler): Likewise.
6301 (s390_emit_call): Likewise.
6302 (s390_conditional_register_usage): Likewise.
6303 (s390_optimize_prologue): Likewise.
6304 (s390_reorg): Remove TARGET_CPU_ZARCH and
6305 split_branches_pending_p usages.
6306 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
6308 (s390_output_indirect_thunk_function): Likewise.
6309 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
6310 (TARGET_CPU_ZARCH_P): Removed.
6311 (struct machine_function): Remove split_branches_pending_p.
6312 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
6314 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
6316 * common/config/s390/s390-common.c (processor_flags_table):
6318 * config.gcc: Remove with_arch/with_tune support.
6319 * config/s390/2064.md: Remove cpu attribute comparisons.
6320 * config/s390/driver-native.c (s390_host_detect_local_cpu):
6322 * config/s390/linux.h (ASM_SPEC):
6323 Remove -march support.
6324 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
6325 Use a table to get an arch level.
6326 * config/s390/s390-opts.h (enum processor_type):
6328 * config/s390/s390.c
6329 (processor_table): Remove entries, add arch_level values.
6330 (s390_issue_rate): Remove cases.
6331 (s390_option_override): Adjust
6332 s390_option_override_internal() call.
6333 (s390_option_override_internal): Remove deprecation warning.
6334 (s390_valid_target_attribute_tree): Adjust
6335 s390_option_override_internal() call.
6336 * config/s390/s390.h (struct s390_processor):
6337 Share with s390-c.c, add arch_level field.
6338 * config/s390/s390.md:
6339 Remove occurrences in cpu attribute.
6340 * config/s390/s390.opt: Remove -march/-mtune support.
6341 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
6342 * doc/invoke.texi: Remove deprecation warning.
6344 2018-08-08 Luis Machado <luis.machado@linaro.org>
6346 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
6348 (qdf24xx_tunings): Set vector cost structure to
6349 qdf24xx_vector_cost.
6351 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
6352 <register_sextend>: Set to 3.
6354 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
6357 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
6358 * config/aarch64/aarch64-simd.md
6359 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
6360 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
6361 (aarch64_frecpx<mode>): ...this new pattern.
6362 * config/aarch64/aarch64-simd-builtins.def: Remove comment
6363 about aarch64_frecp<FRECP:frecp_suffix><mode>.
6365 2018-08-07 Martin Liska <mliska@suse.cz>
6368 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
6369 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
6370 * predict.def (PRED_MALLOC_NONNULL): New predictor.
6371 * doc/extend.texi: Document that malloc attribute adds
6374 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
6377 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6378 Define to speculation_safe_value_not_needed.
6380 2018-08-06 Jeff Law <law@redhat.com>
6382 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
6383 the vr_values instance to cprop_into_stmt.
6384 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
6385 (cprop_operand): Also query EVRP to determine if OP is a constant.
6387 2018-08-06 Nathan Sidwell <nathan@acm.org>
6389 * diagnostic.c (diagnostic_report_current_module): Reroll
6390 included-at loop. Translate text.
6392 2018-08-06 David Malcolm <dmalcolm@redhat.com>
6394 * function-tests.c (selftest::test_expansion_to_rtl): Call
6395 free_after_compilation.
6397 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6399 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
6401 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
6403 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
6404 loops with memory block operations from getting unrolled.
6406 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
6409 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6410 Define to speculation_safe_value_not_needed.
6412 2018-08-06 Jeff Law <law@redhat.com>
6414 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
6417 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
6420 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
6421 with all enabled __intN types.
6423 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
6425 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6427 * alias.c (record_set): Check for clobber high.
6428 * cfgexpand.c (expand_gimple_stmt): Likewise.
6429 * combine-stack-adj.c (single_set_for_csa): Likewise.
6430 * combine.c (find_single_use_1): Likewise.
6431 (set_nonzero_bits_and_sign_copies): Likewise.
6432 (get_combine_src_dest): Likewise.
6433 (is_parallel_of_n_reg_sets): Likewise.
6434 (try_combine): Likewise.
6435 (record_dead_and_set_regs_1): Likewise.
6436 (reg_dead_at_p_1): Likewise.
6437 (reg_dead_at_p): Likewise.
6438 * dce.c (deletable_insn_p): Likewise.
6439 (mark_nonreg_stores_1): Likewise.
6440 (mark_nonreg_stores_2): Likewise.
6441 * df-scan.c (df_find_hard_reg_defs): Likewise.
6442 (df_uses_record): Likewise.
6443 (df_get_call_refs): Likewise.
6444 * dwarf2out.c (mem_loc_descriptor): Likewise.
6445 * haifa-sched.c (haifa_classify_rtx): Likewise.
6446 * ira-build.c (create_insn_allocnos): Likewise.
6447 * ira-costs.c (scan_one_insn): Likewise.
6448 * ira.c (equiv_init_movable_p): Likewise.
6449 (rtx_moveable_p): Likewise.
6450 (interesting_dest_for_shprep): Likewise.
6451 * jump.c (mark_jump_label_1): Likewise.
6452 * postreload-gcse.c (record_opr_changes): Likewise.
6453 * postreload.c (reload_cse_simplify): Likewise.
6454 (struct reg_use): Add source expr.
6455 (reload_combine): Check for clobber high.
6456 (reload_combine_note_use): Likewise.
6457 (reload_cse_move2add): Likewise.
6458 (move2add_note_store): Likewise.
6459 * print-rtl.c (print_pattern): Likewise.
6460 * recog.c (decode_asm_operands): Likewise.
6461 (store_data_bypass_p): Likewise.
6462 (if_test_bypass_p): Likewise.
6463 * regcprop.c (kill_clobbered_value): Likewise.
6464 (kill_set_value): Likewise.
6465 * reginfo.c (reg_scan_mark_refs): Likewise.
6466 * reload1.c (maybe_fix_stack_asms): Likewise.
6467 (eliminate_regs_1): Likewise.
6468 (elimination_effects): Likewise.
6469 (mark_not_eliminable): Likewise.
6470 (scan_paradoxical_subregs): Likewise.
6471 (forget_old_reloads_1): Likewise.
6472 * reorg.c (find_end_label): Likewise.
6473 (try_merge_delay_insns): Likewise.
6474 (redundant_insn): Likewise.
6475 (own_thread_p): Likewise.
6476 (fill_simple_delay_slots): Likewise.
6477 (fill_slots_from_thread): Likewise.
6478 (dbr_schedule): Likewise.
6479 * resource.c (update_live_status): Likewise.
6480 (mark_referenced_resources): Likewise.
6481 (mark_set_resources): Likewise.
6482 * rtl.c (copy_rtx): Likewise.
6483 * rtlanal.c (reg_referenced_p): Likewise.
6484 (single_set_2): Likewise.
6485 (noop_move_p): Likewise.
6486 (note_stores): Likewise.
6487 * sched-deps.c (sched_analyze_reg): Likewise.
6488 (sched_analyze_insn): Likewise.
6490 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6492 * cse.c (invalidate_reg): New function extracted from...
6493 (invalidate): ...here.
6494 (canonicalize_insn): Check for clobber high.
6495 (invalidate_from_clobbers): invalidate clobber highs.
6496 (invalidate_from_sets_and_clobbers): Likewise.
6497 (count_reg_usage): Check for clobber high.
6498 (insn_live_p): Likewise.
6499 * cselib.c (cselib_expand_value_rtx_1):Likewise.
6500 (cselib_invalidate_regno): Check for clobber in setter.
6501 (cselib_invalidate_rtx): Pass through setter.
6502 (cselib_invalidate_rtx_note_stores):
6503 (cselib_process_insn): Check for clobber high.
6504 * cselib.h (cselib_invalidate_rtx): Add operand.
6506 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6508 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
6509 (mark_not_eliminable): Likewise.
6510 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
6511 * lra-lives.c (process_bb_lives): Check for clobber high.
6512 * lra.c (new_insn_reg): Remember clobber highs.
6513 (collect_non_operand_hard_regs): Check for clobber high.
6514 (lra_set_insn_recog_data): Likewise.
6515 (add_regs_to_insn_regno_info): Likewise.
6516 (lra_update_insn_regno_info): Likewise.
6518 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6520 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
6521 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
6523 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6525 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
6526 (copy_insn_1): Likewise.
6527 (gen_hard_reg_clobber_high): New gen function.
6528 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
6529 * genemit.c (gen_exp): Likewise.
6530 (gen_emit_seq): Pass through info.
6531 (gen_insn): Check for CLOBBER_HIGH.
6532 (gen_expand): Pass through info.
6533 (gen_split): Likewise.
6534 (output_add_clobbers): Likewise.
6535 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
6536 (remove_clobbers): Likewise.
6537 * rtl.h (gen_hard_reg_clobber_high): New declaration.
6539 2018-08-06 Alan Hayward <alan.hayward@arm.com>
6541 * doc/rtl.texi (clobber_high): Add.
6542 (parallel): Add in clobber high
6543 * rtl.c (rtl_check_failed_code3): Add function.
6544 * rtl.def (CLOBBER_HIGH): Add expression.
6545 * rtl.h (RTL_CHECKC3): Add macro.
6546 (rtl_check_failed_code3): Add declaration.
6547 (XC3EXP): Add macro.
6549 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
6552 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
6553 cfun->machine->max_used_stack_alignment if needed.
6555 2018-08-04 Martin Sebor <msebor@redhat.com>
6557 PR tree-optimization/86571
6558 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
6561 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
6564 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6567 2018-08-03 Jeff Law <law@redhat.com>
6570 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6571 Define to speculation_safe_value_not_needed.
6573 2018-08-03 David Malcolm <dmalcolm@redhat.com>
6575 * doc/gcov.texi (-x): Remove duplicate "to".
6576 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
6577 (-Wif-not-aligned): Remove duplicate "is".
6578 (-flto): Remove duplicate "the".
6579 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
6580 duplicate "v5.00.b".
6581 (MSP430 Options): Remove duplicate "and" from the description
6582 of "-mgprel-sec=regexp".
6583 (x86 Options): Remove duplicate copies of "vmldLog102" and
6584 vmlsLog104 from description of "-mveclibabi=type".
6586 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
6588 * internal-fn.h (first_commutative_argument): Declare.
6589 * internal-fn.c (first_commutative_argument): New function.
6590 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
6591 restrictions for pattern statements. Use first_commutative_argument
6592 to look for commutative operands in calls to internal functions.
6594 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
6596 * Makefile.in (wide-int-range.o): New.
6597 * tree-vrp.c: Move all the wide_int_* functions to...
6598 * wide-int-range.cc: ...here.
6599 * tree-vrp.h: Move all the wide_int_* prototypes to...
6600 * wide-int-range.h: ...here.
6602 2018-08-03 Tom de Vries <tdevries@suse.de>
6604 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
6606 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
6607 * except.c (output_function_exception_table): Do early exit if
6608 targetm_common.except_unwind_info (&global_options) == UI_NONE.
6610 2018-08-03 Martin Liska <mliska@suse.cz>
6612 * predict.c (dump_prediction): Change to 2 digits
6615 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
6617 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
6619 (falkor_am_1_gtov_gtov): ... a new insn reservation.
6621 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
6623 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
6624 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
6625 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
6626 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
6627 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
6629 2018-08-02 David Malcolm <dmalcolm@redhat.com>
6631 * diagnostic-show-locus.c (diagnostic_show_locus): Use
6632 pp_take_prefix when saving the existing prefix.
6633 * diagnostic.c (diagnostic_append_note): Likewise.
6634 * langhooks.c (lhd_print_error_function): Likewise.
6635 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
6636 param's type. Free the existing prefix.
6637 (pp_take_prefix): New function.
6638 (pretty_printer::pretty_printer): Drop the prefix parameter.
6639 Rename the length parameter to match the comment.
6640 (pretty_printer::~pretty_printer): Free the prefix.
6641 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
6643 (struct pretty_printer): Drop the "const" from "prefix" field's
6644 type and clarify memory management.
6645 (pp_set_prefix): Drop the "const" from the 2nd param.
6646 (pp_take_prefix): New decl.
6648 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
6650 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
6651 for word_mode_ok here instead of passing as argument.
6652 (expand_block_compare): Change select_block_compare_mode() call.
6653 (expand_strncmp_gpr_sequence): New function.
6654 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
6656 2018-08-02 Jeff Law <law@redhat.com>
6659 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6660 Define to speculation_safe_value_not_needed.
6663 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6664 Define to speculation_safe_value_not_needed.
6666 2018-08-02 Tom de Vries <tdevries@suse.de>
6669 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
6670 function. Return UI_TARGET unconditionally.
6671 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
6672 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
6674 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
6676 * genemit.c (print_overload_test): Fix typo.
6678 2018-08-02 Richard Biener <rguenther@suse.de>
6680 PR tree-optimization/86816
6681 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
6682 which checks for value availability before querying it.
6683 (gvn_uses_equal): Use it.
6684 (same_succ_hash): Likewise.
6685 (gimple_equal_p): Likewise.
6687 2018-08-02 Nick Clifton <nickc@redhat.com>
6690 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6691 Define to speculation_safe_value_not_needed.
6694 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6695 Define to speculation_safe_value_not_needed.
6698 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6699 Define to speculation_safe_value_not_needed.
6702 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6703 Define to speculation_safe_value_not_needed.
6706 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6707 Define to speculation_safe_value_not_needed.
6710 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6711 Define to speculation_safe_value_not_needed.
6714 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6715 Define to speculation_safe_value_not_needed.
6718 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
6719 Define to speculation_safe_value_not_needed.
6722 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
6723 speculation_safe_value_not_needed.
6726 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
6727 to speculation_safe_value_not_needed.
6729 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
6731 * doc/md.texi: Expand the documentation of instruction names
6732 to mention port-local uses. Document '@' in pattern names.
6733 * read-md.h (overloaded_instance, overloaded_name): New structs.
6735 (md_reader::handle_overloaded_name): New member function.
6736 (md_reader::get_overloads): Likewise.
6737 (md_reader::m_first_overload): New member variable.
6738 (md_reader::m_next_overload_ptr): Likewise.
6739 (md_reader::m_overloads_htab): Likewise.
6740 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
6741 m_next_overload_ptr and m_overloads_htab.
6742 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
6743 (get_mode_token, get_code_token, get_int_token): New functions.
6744 (map_attr_string): Add an optional argument that passes back
6745 the associated iterator.
6746 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
6747 (md_reader::handle_overloaded_name, add_overload_instance): New
6749 (apply_iterators): Handle '@' names. Report an error if '@'
6750 is used without iterators.
6751 (initialize_iterators): Initialize the new iterator_group fields.
6752 * genopinit.c (handle_overloaded_code_for)
6753 (handle_overloaded_gen): New functions.
6754 (main): Use them to print declarations of maybe_code_for_* and
6755 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
6756 * genemit.c (print_overload_arguments, print_overload_test)
6757 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
6758 (main): Use it to print definitions of maybe_code_for_* and
6759 maybe_gen_* functions.
6760 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
6761 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
6762 instead of explicit mode checks.
6763 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
6764 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
6765 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
6766 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
6767 (aarch64_expand_compare_and_swap): Likewise
6768 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
6769 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
6770 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
6771 (aarch64_constant_pool_reload_icode): Delete.
6772 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
6773 instead of aarch64_constant_pool_reload_icode. Use
6774 code_for_aarch64_reload_mov instead of explicit mode checks.
6775 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
6776 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
6777 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
6778 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
6779 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
6780 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
6781 (aarch64_atomic_load_op_code): Delete.
6782 (aarch64_emit_atomic_load_op): Likewise.
6783 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
6784 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
6785 instead of aarch64_emit_atomic_load_op.
6786 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
6787 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
6788 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
6789 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
6790 character before the pattern name.
6791 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
6792 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
6793 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
6794 (aarch64_frecps<mode>): Likewise.
6795 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
6796 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
6797 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
6798 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
6799 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
6801 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
6803 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
6804 Allow HFmode constants if TARGET_FP_F16INST.
6806 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
6809 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
6810 No longer check last store for clobber of address register.
6812 2018-08-02 Martin Liska <mliska@suse.cz>
6814 PR gcov-profile/86817
6815 * gcov.c (process_all_functions): New function.
6817 (process_file): Move functions processing to
6818 process_all_functions.
6820 2018-08-02 David Malcolm <dmalcolm@redhat.com>
6822 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
6823 "const" to the "gimple *" and "rtx_insn *" parameters.
6824 * dumpfile.h (dump_user_location_t::dump_user_location_t):
6826 (dump_location_t::dump_location_t): Likewise.
6828 2018-08-01 Martin Sebor <msebor@redhat.com>
6830 PR tree-optimization/86650
6831 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
6832 rather than a "gcall *". Directly pass the data of interest
6833 to percent_K_format, rather than building a temporary CALL_EXPR
6835 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
6836 (gimple_fold_builtin_strncat): Adjust.
6837 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
6838 gcall* argument with gimple*.
6839 * gimple-ssa-warn-restrict.c (check_call): Same.
6840 (wrestrict_dom_walker::before_dom_children): Same.
6841 (builtin_access::builtin_access): Same.
6842 (check_bounds_or_overlap): Same
6843 (maybe_diag_overlap): Same.
6844 (maybe_diag_offset_bounds): Same.
6845 * tree-diagnostic.c (default_tree_printer): Move usage of
6846 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
6848 * tree-pretty-print.c (percent_K_format): Add argument.
6849 * tree-pretty-print.h: Add argument.
6850 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
6851 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
6852 (maybe_diag_stxncpy_trunc): Same.
6853 (handle_builtin_stxncpy): Same.
6854 (handle_builtin_strcat): Same.
6856 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6858 * match.pd: Optimise pointer range checks.
6860 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6862 PR tree-optimization/86758
6863 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
6864 to remove pattern statements.
6866 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6868 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
6869 result of dfs_enumerate_from when constructing stmt_vec_infos,
6870 instead of additionally calling get_loop_body.
6872 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6874 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
6876 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
6877 When creating an iv, assert that the step is not known to be zero.
6878 (vect_setup_realignment): Update call accordingly.
6879 * tree-vect-stmts.c (vectorizable_store): Likewise.
6880 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
6882 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6884 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
6885 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
6886 (vectorizable_reduction): Likewise.
6887 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
6888 (vect_detect_hybrid_slp_stmts): Likewise.
6889 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
6891 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
6893 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
6894 (wide_int_set_zero_nonzero_bits): ...this.
6895 (zero_nonzero_bits_from_vr): Rename to...
6896 (vrp_set_zero_nonzero_bits): ...this.
6897 (extract_range_from_multiplicative_op_1): Abstract wide int
6899 (wide_int_range_multiplicative_op): ...here.
6900 (extract_range_from_binary_expr_1): Extract wide int binary
6901 operations into their own functions.
6902 (wide_int_range_lshift): New.
6903 (wide_int_range_can_optimize_bit_op): New.
6904 (wide_int_range_shift_undefined_p): New.
6905 (wide_int_range_bit_xor): New.
6906 (wide_int_range_bit_ior): New.
6907 (wide_int_range_bit_and): New.
6908 (wide_int_range_trunc_mod): New.
6909 (extract_range_into_wide_ints): New.
6910 (vrp_shift_undefined_p): New.
6911 (extract_range_from_multiplicative_op): New.
6912 (vrp_can_optimize_bit_op): New.
6913 * tree-vrp.h (value_range::dump): New.
6914 (wide_int_range_multiplicative_op): New.
6915 (wide_int_range_lshift):New.
6916 (wide_int_range_shift_undefined_p): New.
6917 (wide_int_range_bit_xor): New.
6918 (wide_int_range_bit_ior): New.
6919 (wide_int_range_bit_and): New.
6920 (wide_int_range_trunc_mod): New.
6921 (zero_nonzero_bits_from_bounds): Rename to...
6922 (wide_int_set_zero_nonzero_bits): ...this.
6923 (zero_nonzero_bits_from_vr): Rename to...
6924 (vrp_set_zero_nonzero_bits): ...this.
6925 (range_easy_mask_min_max): Rename to...
6926 (wide_int_range_can_optimize_bit_op): this.
6927 * vr-values.c (simplify_bit_ops_using_ranges): Rename
6928 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
6930 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6932 * tree-vectorizer.h (vect_orig_stmt): New function.
6933 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
6934 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
6935 (vect_create_epilog_for_reduction): Likewise.
6936 (vectorizable_live_operation): Likewise.
6937 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
6938 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
6939 * tree-vect-stmts.c (vectorizable_call): Likewise.
6940 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
6942 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6944 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
6946 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
6947 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
6948 (vect_transform_loop): Likewise.
6949 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
6951 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6953 * tree-vectorizer.h (vect_schedule_slp): Return void.
6954 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
6955 (vect_schedule_slp): Likewise.
6957 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6959 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
6961 (vect_transform_loop): Update calls accordingly. Schedule SLP
6962 instances before the main loop, if any exist.
6964 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
6966 PR tree-optimization/86749
6967 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
6968 If the lhs is used in a COND_EXPR, check that it is being used
6969 as the "then" or "else" value.
6971 2018-08-01 Tom de Vries <tdevries@suse.de>
6974 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
6975 speculation_safe_value_not_needed.
6977 2018-08-01 Richard Biener <rguenther@suse.de>
6979 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
6982 2018-08-01 Martin Liska <mliska@suse.cz>
6984 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
6985 format how successful transformation is dumped.
6986 (gimple_mod_pow2_value_transform): Likewise.
6987 (gimple_mod_subtract_transform): Likewise.
6988 (gimple_stringops_transform): Likewise.
6990 2018-08-01 Martin Liska <mliska@suse.cz>
6993 * value-prof.c (interesting_stringop_to_profile_p):
6994 Simplify the code and add BUILT_IN_MEMMOVE.
6995 (gimple_stringops_transform): Likewise.
6997 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
6999 * config/aarch64/aarch64-simd.md
7000 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
7001 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
7002 use GPI iterator instead of SI mode.
7004 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
7006 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
7007 rs6000_speculation_barrier.
7008 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
7009 new barrier pattern name.
7011 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
7013 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
7014 (speculation_barrier): New insn.
7016 2018-08-01 Richard Biener <rguenther@suse.de>
7019 * graphite.h: Include isl/id.h and isl/space.h to allow build
7022 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
7025 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
7026 mode for COFF targets.
7027 * defaults.h (TARGET_COFF): Define.
7028 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
7029 TARGET_COFF): Define.
7030 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
7031 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
7032 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
7034 2018-07-31 Alexandre Oliva <oliva@adacore.com>
7036 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
7037 * gimple-streamer-out.c (output_bb): Save it.
7038 * lto-streamer-in.c (input_struct_function_base): Restore
7039 instance discriminator if available. Create map on demand.
7040 * lto-streamer-out.c (output_struct_function_base): Save it if
7042 * final.c (decl_to_instance_map): Document LTO strategy.
7044 2018-07-31 Alexandre Oliva <oliva@adacore.com>
7045 Olivier Hainque <hainque@adacore.com>
7047 * debug.h (decl_to_instance_map_t): New type.
7048 (decl_to_instance_map): Declare.
7049 (maybe_create_decl_to_instance_map): New inline function.
7050 * final.c (bb_discriminator, last_bb_discriminator): New statics,
7051 to track basic block discriminators.
7052 (final_start_function_1): Initialize them.
7053 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
7055 (decl_to_instance_map): New variable.
7056 (map_decl_to_instance, maybe_set_discriminator): New functions.
7057 (notice_source_line): Set discriminator.
7059 2018-07-31 Ian Lance Taylor <iant@golang.org>
7061 * targhooks.c (default_have_speculation_safe_value): Add
7064 2018-07-31 David Malcolm <dmalcolm@redhat.com>
7066 * dump-context.h: Include "pretty-print.h".
7067 (dump_context::refresh_dumps_are_enabled): New decl.
7068 (dump_context::emit_item): New decl.
7069 (class dump_context): Add fields "m_test_pp" and
7071 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
7072 (temp_dump_context::get_dumped_text): New decl.
7073 (class temp_dump_context): Add field "m_pp".
7074 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
7075 (dump_context::refresh_dumps_are_enabled): ...and add a test for
7077 (set_dump_file): Update for above change.
7078 (set_alt_dump_file): Likewise.
7079 (dump_loc): New overload, taking a pretty_printer *.
7080 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
7081 to any test pretty-printer.
7082 (make_item_for_dump_gimple_stmt): New function, adapted from
7083 optinfo::add_gimple_stmt.
7084 (dump_context::dump_gimple_stmt): Call it, and use the result,
7085 eliminating the direct usage of dump_file and alt_dump_file in
7086 favor of indirectly using them via emit_item.
7087 (make_item_for_dump_gimple_expr): New function, adapted from
7088 optinfo::add_gimple_expr.
7089 (dump_context::dump_gimple_expr): Call it, and use the result,
7090 eliminating the direct usage of dump_file and alt_dump_file in
7091 favor of indirectly using them via emit_item.
7092 (make_item_for_dump_generic_expr): New function, adapted from
7094 (dump_context::dump_generic_expr): Call it, and use the result,
7095 eliminating the direct usage of dump_file and alt_dump_file in
7096 favor of indirectly using them via emit_item.
7097 (make_item_for_dump_printf_va): New function, adapted from
7098 optinfo::add_printf_va.
7099 (make_item_for_dump_printf): New function.
7100 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
7101 and use the result, eliminating the direct usage of dump_file and
7102 alt_dump_file in favor of indirectly using them via emit_item.
7103 (make_item_for_dump_dec): New function.
7104 (dump_context::dump_dec): Call it, and use the result,
7105 eliminating the direct usage of dump_file and alt_dump_file in
7106 favor of indirectly using them via emit_item.
7107 (make_item_for_dump_symtab_node): New function, adapted from
7108 optinfo::add_symtab_node.
7109 (dump_context::dump_symtab_node): Call it, and use the result,
7110 eliminating the direct usage of dump_file and alt_dump_file in
7111 favor of indirectly using them via emit_item.
7112 (dump_context::begin_scope): Reimplement, avoiding direct usage
7113 of dump_file and alt_dump_file in favor of indirectly using them
7115 (dump_context::emit_item): New member function.
7116 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
7117 Set up test pretty-printer on the underlying context. Call
7118 refresh_dumps_are_enabled.
7119 (temp_dump_context::~temp_dump_context): Call
7120 refresh_dumps_are_enabled.
7121 (temp_dump_context::get_dumped_text): New member function.
7122 (selftest::verify_dumped_text): New function.
7123 (ASSERT_DUMPED_TEXT_EQ): New macro.
7124 (selftest::test_capture_of_dump_calls): Run all tests twice, with
7125 and then without optinfo enabled. Add uses of
7126 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
7127 * dumpfile.h: Update comment for the dump_* API.
7128 * optinfo-emit-json.cc
7129 (selftest::test_building_json_from_dump_calls): Update for new
7130 param for temp_dump_context ctor.
7131 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
7132 and "m_owned" field.
7133 (optinfo_item::~optinfo_item): Likewise.
7134 (optinfo::add_item): New member function.
7135 (optinfo::emit): Update comment.
7136 (optinfo::add_string): Delete.
7137 (optinfo::add_printf): Delete.
7138 (optinfo::add_printf_va): Delete.
7139 (optinfo::add_gimple_stmt): Delete.
7140 (optinfo::add_gimple_expr): Delete.
7141 (optinfo::add_tree): Delete.
7142 (optinfo::add_symtab_node): Delete.
7143 (optinfo::add_dec): Delete.
7144 * optinfo.h (class dump_context): New forward decl.
7145 (optinfo::add_item): New decl.
7146 (optinfo::add_string): Delete.
7147 (optinfo::add_printf): Delete.
7148 (optinfo::add_printf_va): Delete.
7149 (optinfo::add_gimple_stmt): Delete.
7150 (optinfo::add_gimple_expr): Delete.
7151 (optinfo::add_tree): Delete.
7152 (optinfo::add_symtab_node): Delete.
7153 (optinfo::add_dec): Delete.
7154 (optinfo::add_poly_int): Delete.
7155 (optinfo_item::optinfo_item): Remove "owned" param.
7156 (class optinfo_item): Remove field "m_owned".
7158 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
7161 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
7162 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
7163 requested variable alignment.
7164 (expand_one_ssa_partition): Likewise.
7165 (expand_one_var): Likewise.
7167 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7169 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
7170 to speculation_safe_value_not_needed.
7172 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7174 * targhooks.h (speculation_safe_value_not_needed): New prototype.
7175 * targhooks.c (speculation_safe_value_not_needed): New function.
7176 * target.def (have_speculation_safe_value): Update documentation.
7177 * doc/tm.texi: Regenerated.
7179 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7181 * config/aarch64/iterators.md (ALLI_TI): New iterator.
7182 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
7184 (despeculate_copy<ALLI:mode>_insn): New insn.
7185 (despeculate_copyti_insn): New insn.
7186 (despeculate_simple<ALLI:mode>): New insn
7187 (despeculate_simpleti): New insn.
7188 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
7190 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
7191 aarch64_speculation_safe_value.
7192 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
7194 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7196 * config/aarch64/aarch64-speculation.cc: New file.
7197 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
7198 before pass_reorder_blocks.
7199 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
7201 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
7202 X14 and X15 when tracking speculation.
7203 * config/aarch64/aarch64.md (register name constants): Add
7204 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
7205 (unspec): Add UNSPEC_SPECULATION_TRACKER.
7206 (speculation_barrier): New insn attribute.
7207 (cmp<mode>): Allow SP in comparisons.
7208 (speculation_tracker): New insn.
7209 (speculation_barrier): Add speculation_barrier attribute.
7210 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
7211 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
7212 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
7214 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7216 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
7217 aarch64_track_speculation is true.
7218 (tb<optab><mode>1): Likewise.
7219 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
7220 generate CB[N]Z when tracking speculation.
7221 (aarch64_split_compare_and_swap): Likewise.
7222 (aarch64_split_atomic_op): Likewise.
7224 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7226 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
7228 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7230 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
7231 (speculation_barrier): New insn.
7233 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7235 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
7236 * config/arm/arm.md (speculation_barrier): New expand.
7237 (speculation_barrier_insn): New pattern.
7239 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
7241 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
7242 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
7243 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
7244 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
7246 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
7247 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
7248 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
7249 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
7250 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
7251 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
7252 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
7253 * builtins.c (expand_speculation_safe_value): New function.
7254 (expand_builtin): Call it.
7255 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
7256 * doc/extend.texi: Document __builtin_speculation_safe_value.
7257 * doc/md.texi: Document "speculation_barrier" pattern.
7258 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
7259 TARGET_HAVE_SPECULATION_SAFE_VALUE.
7260 * doc/tm.texi: Regenerated.
7261 * target.def (have_speculation_safe_value, speculation_safe_value): New
7263 * targhooks.c (default_have_speculation_safe_value): New function.
7264 (default_speculation_safe_value): New function.
7265 * targhooks.h (default_have_speculation_safe_value): Add prototype.
7266 (default_speculation_safe_value): Add prototype.
7268 2018-07-31 David Malcolm <dmalcolm@redhat.com>
7270 * dump-context.h (dump_context::dump_loc): New decl.
7271 * dumpfile.c (dump_context::dump_loc): New member function.
7272 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
7273 and dump_gimple_stmt.
7274 (dump_context::dump_gimple_expr_loc): Likewise, using
7276 (dump_context::dump_generic_expr_loc): Likewise, using
7278 (dump_context::dump_printf_loc_va): Likewise, using
7280 (dump_context::begin_scope): Explicitly using the global function
7281 "dump_loc", rather than the member function.
7283 2018-07-31 Martin Sebor <msebor@redhat.com>
7285 PR tree-optimization/86741
7286 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
7288 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
7290 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
7291 depend on whether prefetch instructions will be emitted or not.
7292 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
7293 will be emitted or not.
7294 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
7295 (TARGET_SETMEM_PFD): New macros.
7297 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7299 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
7300 (NULL_STMT_VEC_INFO): Delete.
7301 (stmt_vec_info::operator*): Likewise.
7302 (stmt_vec_info::operator gimple *): Likewise.
7303 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
7304 of NULL_STMT_VEC_INFO.
7305 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
7306 (vect_reassociating_reduction_p): Likewise.
7307 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
7308 (vectorizable_store): Likewise.
7309 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
7310 (vec_info::free_stmt_vec_infos): Likewise.
7312 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7314 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
7315 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
7317 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7319 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
7320 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
7321 (vec_info::free_stmt_vec_info): New private member functions.
7322 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
7323 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
7324 * tree-parloops.c (gather_scalar_reductions): Remove calls to
7325 set_stmt_vec_info_vec and free_stmt_vec_infos.
7326 * tree-vect-loop.c (_loop_vec_info): Remove call to
7327 set_stmt_vec_info_vec.
7328 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
7329 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
7330 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
7331 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
7332 (vec_info::free_stmt_vec_info): ...these new functions. Remove
7333 assignments in {vec_info::,}new_stmt_vec_info that are redundant
7334 with the clearing in the xcalloc.
7335 (stmt_vec_info_vec): Delete.
7336 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
7337 (vectorize_loops): Likewise.
7338 (vec_info::~vec_info): Remove argument from call to
7339 free_stmt_vec_infos.
7340 (vec_info::add_stmt): Remove vinfo argument from call to
7343 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7345 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
7346 rather than a gimple stmt.
7347 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
7348 information for pattern statements when passed the original
7349 statement; instead wait to be passed the pattern statement itself.
7350 Don't call set_vinfo_for_stmt here.
7351 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
7352 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
7353 stmt_vec_infos here.
7354 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
7355 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
7356 stmt_vec_infos entry.
7358 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7360 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
7361 * tree-vectorizer.c (vec_info::replace_stmt): New function.
7362 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
7363 * tree-vect-stmts.c (vectorizable_call): Likewise.
7364 (vectorizable_simd_clone_call): Likewise.
7366 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7368 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
7369 * tree-vectorizer.c (vec_info::remove_stmt): New function.
7370 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
7371 * tree-vect-loop.c (vect_transform_loop): Likewise.
7372 * tree-vect-slp.c (vect_schedule_slp): Likewise.
7373 * tree-vect-stmts.c (vect_remove_stores): Likewise.
7375 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7377 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
7378 (vect_dr_stmt): Delete.
7379 * tree-vectorizer.c (vec_info::lookup_dr): New function.
7380 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
7382 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
7383 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
7384 (vect_verify_datarefs_alignment, vect_peeling_supportable)
7385 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
7386 (vect_analyze_data_refs): Likewise.
7387 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
7389 (vect_find_same_alignment_drs): Likewise.
7390 (vect_slp_analyze_node_dependences): Update calls accordingly.
7391 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
7392 instead of DR_VECT_AUX.
7393 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
7394 of a vector data references. Use vec_info::lookup_dr instead of
7396 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
7397 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
7398 instead of DR_VECT_AUX.
7400 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7402 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
7404 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
7406 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
7407 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
7408 (vect_gen_prolog_loop_niters): Likewise.
7410 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7412 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
7413 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
7414 (vect_known_alignment_in_bytes, vect_dr_behavior)
7415 (vect_get_scalar_dr_size): Take references as dr_vec_infos
7416 instead of data_references. Update calls to other routines for
7417 which the same change has been made.
7418 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
7419 dr_vec_infos instead of stmt_vec_infos.
7420 (vect_analyze_data_ref_dependence): Update call accordingly.
7421 (vect_slp_analyze_data_ref_dependence)
7422 (vect_record_base_alignments): Use DR_VECT_AUX.
7423 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
7424 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
7425 (vector_alignment_reachable_p, vect_get_data_access_cost)
7426 (vect_peeling_supportable, vect_analyze_group_access_1)
7427 (vect_analyze_group_access, vect_analyze_data_ref_access)
7428 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
7429 (vect_compile_time_alias, vect_small_gap_p)
7430 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
7431 (vect_supportable_dr_alignment): Take references as dr_vec_infos
7432 instead of data_references. Update calls to other routines for
7433 which the same change has been made.
7434 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
7435 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
7436 (vect_slp_analyze_and_verify_node_alignment)
7437 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
7438 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
7439 (vect_setup_realignment): Use dr_vec_infos. Update calls after
7441 (_vect_peel_info::dr): Replace with...
7442 (_vect_peel_info::dr_info): ...this new field.
7443 (vect_peeling_hash_get_most_frequent)
7444 (vect_peeling_hash_choose_best_peeling): Update accordingly.
7445 (vect_peeling_hash_get_lowest_cost):
7446 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
7447 routines for which the same change has been made.
7448 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
7450 * tree-vect-loop-manip.c (get_misalign_in_elems)
7451 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
7453 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
7454 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
7455 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
7456 (get_group_load_store_type, get_negative_load_store_type)
7457 (vect_get_data_ptr_increment, vectorizable_store)
7458 (vectorizable_load): Likewise.
7459 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
7460 Update calls to other routines for which the same change has been made.
7462 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7464 * tree-vectorizer.h (vec_info::move_dr): New member function.
7465 (dataref_aux): Rename to...
7466 (dr_vec_info): ...this and add "dr" and "stmt" fields.
7467 (_stmt_vec_info::dr_aux): Update accordingly.
7468 (_stmt_vec_info::data_ref_info): Delete.
7469 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
7470 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
7471 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
7472 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
7474 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
7475 (STMT_VINFO_DR_INFO): New macro.
7476 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
7477 (set_dr_misalignment): Update after rename of dataref_aux.
7478 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
7479 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
7480 initialization of STMT_VINFO_DATA_REF.
7481 * tree-vectorizer.c (vec_info::move_dr): New function.
7482 * tree-vect-patterns.c (vect_recog_bool_pattern)
7483 (vect_recog_mask_conversion_pattern)
7484 (vect_recog_gather_scatter_pattern): Use it.
7485 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
7486 the "dr" and "stmt" fields of dr_vec_info instead of
7487 STMT_VINFO_DATA_REF.
7489 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7491 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
7492 (is_pattern_stmt_p): Use it.
7493 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
7494 on pattern statements.
7496 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7498 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
7499 original stmt as a stmt_vec_info rather than a gimple stmt.
7500 (vect_pattern_recog_1): Take the statement directly as a
7501 stmt_vec_info, rather than via a gimple_stmt_iterator.
7502 Update call to vect_mark_pattern_stmts.
7503 (vect_pattern_recog): Update calls accordingly.
7505 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7507 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
7508 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
7509 a vect_def_type for the first argument.
7510 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
7511 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
7512 operand if it isn't defined by a vectorized statement.
7513 (vect_build_gather_load_calls): Remove the mask_dt argument and
7514 update calls to vect_get_vec_def_for_stmt_copy.
7515 (vectorizable_bswap): Likewise the dt argument.
7516 (vectorizable_call): Update calls to vectorizable_bswap and
7517 vect_get_vec_def_for_stmt_copy.
7518 (vectorizable_simd_clone_call, vectorizable_assignment)
7519 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
7520 (vectorizable_comparison): Update calls to
7521 vect_get_vec_def_for_stmt_copy.
7522 (vectorizable_store): Likewise. Remove now-unnecessary calls to
7524 (vect_get_loop_based_defs): Remove dt argument and update call
7525 to vect_get_vec_def_for_stmt_copy.
7526 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
7527 and vect_get_vec_def_for_stmt_copy.
7528 (vectorizable_load): Update calls to vect_build_gather_load_calls
7529 and vect_get_vec_def_for_stmt_copy.
7530 * tree-vect-loop.c (vect_create_epilog_for_reduction)
7531 (vectorizable_reduction, vectorizable_live_operation): Update calls
7532 to vect_get_vec_def_for_stmt_copy.
7534 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7536 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
7537 and gimple stmt arguments with a stmt_vec_info.
7538 (vect_record_base_alignments): Update calls accordingly.
7539 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
7540 and gimple stmt arguments with a stmt_vec_info.
7541 (vect_build_slp_tree_1): Remove vinfo argument and update call
7542 to vect_record_max_nunits.
7543 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
7544 and vect_record_max_nunits.
7546 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7548 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
7549 file and take a stmt_vec_info instead of a gimple stmt.
7550 (supportable_widening_operation, vect_finish_replace_stmt)
7551 (vect_finish_stmt_generation, vect_get_store_rhs)
7552 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
7553 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
7554 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
7555 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
7556 (vect_create_data_ref_ptr, bump_vector_ptr)
7557 (vect_permute_store_chain, vect_setup_realignment)
7558 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
7559 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
7560 (vectorizable_reduction, vectorizable_induction)
7561 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
7562 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
7563 than gimple stmts as arguments.
7564 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
7565 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
7566 (can_group_stmts_p, vect_check_gather_scatter)
7567 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
7568 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
7569 (vect_permute_load_chain, vect_shift_permute_load_chain)
7570 (vect_transform_grouped_load)
7571 (vect_record_grouped_load_vectors): Likewise.
7572 * tree-vect-loop.c (vect_fixup_reduc_chain)
7573 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
7574 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
7575 (vectorizable_reduction, vectorizable_induction)
7576 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
7577 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
7578 (vect_get_load_store_mask): Likewise.
7579 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
7580 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
7581 * tree-vect-stmts.c (vect_mark_relevant)
7582 (is_simple_and_all_uses_invariant)
7583 (exist_non_indexing_operands_for_use_p, process_use)
7584 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
7585 (vect_get_vec_def_for_operand, vect_get_vec_defs)
7586 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
7587 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
7588 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
7589 (get_negative_load_store_type, get_load_store_type)
7590 (vect_check_load_store_mask, vect_check_store_rhs)
7591 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
7592 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
7593 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
7594 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
7595 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
7596 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
7597 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
7598 (supportable_widening_operation): Likewise.
7600 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7602 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
7603 a stmt_vec_info instead of a gcall.
7604 (vect_check_gather_scatter): Update call accordingly.
7605 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
7607 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
7608 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
7609 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
7610 instead of a gimple stmt.
7611 (vect_transform_loop): Update calls accordingly.
7612 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
7613 stmt_vec_infos instead of gimple stmts.
7614 (vect_analyze_slp_instance): Update use accordingly.
7615 * tree-vect-stmts.c (read_vector_array, write_vector_array)
7616 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
7617 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
7618 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
7619 (vect_gen_widened_results_half, vect_get_loop_based_defs)
7620 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
7621 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
7622 down to subroutines.
7624 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7626 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
7627 of the worklist from a vector of gimple stmts to a vector of
7629 * tree-vect-stmts.c (vect_mark_relevant, process_use)
7630 (vect_mark_stmts_to_be_vectorized): Likewise
7632 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7634 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
7635 statement before passing it to vect_analyze_stmt.
7636 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
7637 the chain of phi vector definitions. Track the exit phi via its
7639 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
7640 STMT_VINFO_REDUC_DEF.
7641 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
7642 stmt_vec_infos to handle the statement chains.
7643 (vect_get_slp_defs): Record the first statement in the node
7644 using a stmt_vec_info.
7645 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
7646 statements here and pass their stmt_vec_info down to subroutines.
7647 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
7648 down to vect_finish_stmt_generation.
7649 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
7650 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
7651 stmt_vec_infos to subroutines.
7652 (vect_remove_stores): Use stmt_vec_infos to handle the statement
7655 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7657 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
7658 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
7659 (vect_permute_store_chain, vect_setup_realignment)
7660 (vect_permute_load_chain, vect_shift_permute_load_chain)
7661 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
7662 stmts internally, and when passing values to other vectorizer routines.
7663 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
7664 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
7665 (vect_analyze_loop_operations, get_initial_def_for_reduction)
7666 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
7667 (vectorizable_reduction, vectorizable_induction)
7668 (vectorizable_live_operation, vect_transform_loop_stmt)
7669 (vect_transform_loop): Likewise.
7670 * tree-vect-patterns.c (vect_reassociating_reduction_p)
7671 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
7672 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
7673 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
7674 (vect_slp_analyze_node_operations_1): Likewise.
7675 * tree-vect-stmts.c (vect_mark_relevant, process_use)
7676 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
7677 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
7678 (vect_finish_stmt_generation_1, get_group_load_store_type)
7679 (get_load_store_type, vect_build_gather_load_calls)
7680 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
7681 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
7682 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
7683 (vectorizable_store, vectorizable_load, vectorizable_condition)
7684 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
7685 (supportable_widening_operation): Likewise.
7686 (vect_get_vector_types_for_stmt): Likewise.
7687 * tree-vectorizer.h (vect_dr_behavior): Likewise.
7689 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7691 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
7692 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
7693 (vect_permute_store_chain, vect_permute_load_chain)
7694 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
7695 repeated stmt_vec_info lookups.
7696 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
7697 (vect_update_ivs_after_vectorizer): Likewise.
7698 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
7699 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
7700 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
7701 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
7702 (vect_bb_slp_scalar_cost): Likewise.
7703 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
7705 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7707 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
7708 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
7709 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
7710 to get gassigns and gcalls, rather than operating on generc gimple
7712 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
7713 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
7714 (vectorizable_load, vect_analyze_stmt): Likewise.
7715 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
7717 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7719 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
7720 return stmt_vec_infos rather than gimple stmts. Do not accept
7722 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
7724 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
7725 Update use of get_later_stmt.
7726 (vect_get_constant_vectors): Update call accordingly.
7727 (vect_schedule_slp_instance): Likewise
7728 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
7729 (vect_slp_analyze_instance_dependence): Likewise.
7730 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
7732 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7734 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
7735 (stmt_info_for_cost::stmt_info): ...this new field.
7736 (add_stmt_costs): Update accordingly.
7737 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
7738 (vect_get_known_peeling_cost): Likewise.
7739 (vect_estimate_min_profitable_iters): Likewise.
7740 * tree-vect-stmts.c (record_stmt_cost): Likewise.
7742 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7744 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
7745 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
7746 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
7748 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
7750 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7752 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
7753 a gimple stmt to a stmt_vec_info.
7754 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
7756 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7758 * tree-vectorizer.h (vec_info::grouped_stores): Change from
7759 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
7760 (_loop_vec_info::reduction_chains): Likewise.
7761 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
7763 * tree-vect-slp.c (vect_analyze_slp): Likewise.
7765 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7767 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
7768 a gimple stmt to a stmt_vec_info.
7769 (_stmt_vec_info::next_element): Likewise.
7770 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
7771 (vect_slp_analyze_and_verify_node_alignment)
7772 (vect_analyze_group_access_1, vect_analyze_group_access)
7773 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
7774 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
7775 (vect_supportable_dr_alignment): Update accordingly.
7776 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
7777 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
7778 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
7779 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
7780 * tree-vect-slp.c (vect_build_slp_tree_1)
7781 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
7782 (vect_split_slp_store_group, vect_analyze_slp_instance)
7783 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
7784 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
7785 (get_group_load_store_type, get_load_store_type)
7786 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
7787 (vect_transform_stmt, vect_remove_stores): Likewise.
7789 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7791 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
7793 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
7794 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
7795 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
7796 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
7797 (vector_alignment_reachable_p, vect_get_data_access_cost)
7798 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
7799 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
7800 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
7801 (vect_analyze_group_access_1, vect_analyze_group_access)
7802 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
7803 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
7804 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
7805 result of vect_dr_stmt and use the stmt_vec_info instead of
7806 the associated gimple stmt.
7807 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
7808 (vect_gen_prolog_loop_niters): Likewise.
7809 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
7811 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7813 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
7814 to a vec<stmt_vec_info>.
7815 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
7816 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
7818 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
7819 to a vec<stmt_vec_info>.
7820 (bst_traits::value_type, bst_traits::value_type): Likewise.
7821 (bst_traits::hash): Update accordingly.
7822 (vect_get_and_check_slp_defs): Change the stmts parameter from
7823 a vec<gimple *> to a vec<stmt_vec_info>.
7824 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
7825 (vect_build_slp_tree): Likewise.
7826 (vect_build_slp_tree_2): Likewise. Update uses of
7827 SLP_TREE_SCALAR_STMTS.
7828 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
7829 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
7830 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
7831 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
7832 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
7833 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
7834 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
7835 (vect_get_constant_vectors, vect_get_slp_defs)
7836 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
7837 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
7838 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
7839 instead of gimple stmts.
7840 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
7841 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
7842 (vect_slp_analyze_instance_dependence): Update uses of
7843 SLP_TREE_SCALAR_STMTS.
7844 (vect_slp_analyze_and_verify_node_alignment): Likewise.
7845 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
7846 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
7847 (get_initial_defs_for_reduction): Likewise.
7848 (vect_create_epilog_for_reduction): Likewise.
7849 (vectorize_fold_left_reduction): Likewise.
7850 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
7851 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
7852 (can_vectorize_live_stmts): Likewise.
7854 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7856 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
7857 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
7858 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
7860 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
7862 (gather_scalar_reductions): Update after above interface changes.
7863 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
7864 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
7866 (vect_force_simple_reduction): Likewise.
7867 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
7868 LOOP_VINFO_REDUCTIONS.
7869 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
7871 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7873 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
7874 a gimple stmt to a stmt_vec_info.
7875 * tree-vect-loop.c (vect_active_double_reduction_p)
7876 (vect_force_simple_reduction, vectorizable_reduction): Update
7879 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7881 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
7882 vec<gimple *> to a vec<stmt_vec_info>.
7883 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
7884 the reduction_phis argument from a vec<gimple *> to a
7886 (vectorizable_reduction): Likewise the phis local variable that
7887 is passed to vect_create_epilog_for_reduction. Update for new type
7888 of SLP_TREE_VEC_STMTS.
7889 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
7890 (vectorizable_live_operation): Likewise.
7891 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
7892 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
7894 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7896 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
7897 a gimple stmt to a stmt_vec_info.
7898 (vectorizable_condition, vectorizable_live_operation)
7899 (vectorizable_reduction, vectorizable_induction): Pass back the
7900 vectorized statement as a stmt_vec_info.
7901 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
7902 use of STMT_VINFO_VEC_STMT.
7903 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
7904 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
7905 as stmt_vec_infos rather than gimple stmts.
7906 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
7908 (vectorizable_live_operation): Likewise.
7909 (vectorizable_reduction, vectorizable_induction): Likewise,
7910 updating use of STMT_VINFO_VEC_STMT.
7911 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
7912 of STMT_VINFO_VEC_STMT.
7913 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
7914 (vectorizable_simd_clone_call, vectorizable_conversion)
7915 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
7916 (vectorizable_store, vectorizable_load, vectorizable_condition)
7917 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
7918 from a gimple stmt to a stmt_vec_info.
7919 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
7920 pointer to a stmt_vec_info to the vectorizable_* routines.
7922 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7924 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
7925 a gimple stmt to a stmt_vec_info.
7926 (is_pattern_stmt_p): Update accordingly.
7927 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
7928 (vect_record_grouped_load_vectors): Likewise.
7929 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
7930 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
7931 (vect_model_reduction_cost): Likewise.
7932 (vect_create_epilog_for_reduction): Likewise.
7933 (vectorizable_reduction, vectorizable_induction): Likewise.
7934 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
7935 Return the stmt_vec_info for the pattern statement.
7936 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
7937 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
7938 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
7939 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
7940 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
7941 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
7942 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
7943 (free_stmt_vec_info, vect_is_simple_use): Likewise.
7945 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7947 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
7948 (vect_finish_stmt_generation): Likewise.
7949 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
7950 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
7951 (vect_build_gather_load_calls): Use the return value of the above
7952 functions instead of a separate call to vinfo_for_stmt. Use narrow
7953 scopes for the input gimple stmt and wider scopes for the associated
7954 stmt_vec_info. Use vec_info::lookup_def when setting these
7955 stmt_vec_infos from an SSA_NAME definition.
7956 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
7957 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
7958 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
7959 (vectorizable_store, vectorizable_load, vectorizable_condition)
7960 (vectorizable_comparison): Likewise.
7961 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
7962 (vectorizable_reduction): Likewise.
7964 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7966 * tree-vectorizer.h (vect_is_simple_use): Add an optional
7967 stmt_vec_info * parameter before the optional gimple **.
7968 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
7969 (process_use, vect_get_vec_def_for_operand_1): Update callers.
7970 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
7971 * tree-vect-loop.c (vectorizable_reduction): Likewise.
7972 (vectorizable_live_operation): Likewise.
7973 * tree-vect-patterns.c (type_conversion_p): Likewise.
7974 (vect_look_through_possible_promotion): Likewise.
7975 (vect_recog_rotate_pattern): Likewise.
7976 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
7978 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
7980 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
7981 a typedef to a wrapper class.
7982 (NULL_STMT_VEC_INFO): New macro.
7983 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
7984 (stmt_vec_info::operator*): New function.
7985 (stmt_vec_info::operator gimple *): Likewise.
7986 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
7987 (add_stmt_costs): Likewise.
7988 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
7989 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
7990 (vect_get_known_peeling_cost): Likewise.
7991 (vect_estimate_min_profitable_iters): Likewise.
7992 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
7993 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
7994 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
7995 (vectorizable_store, free_stmt_vec_infos): Likewise.
7996 (new_stmt_vec_info): Change return type of xcalloc to
7999 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8001 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
8002 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
8003 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
8004 a single_imm_use-based sequence.
8005 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
8007 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8009 * tree-vectorizer.h (vec_info::lookup_def): Declare.
8010 * tree-vectorizer.c (vec_info::lookup_def): New function.
8011 * tree-vect-patterns.c (vect_get_internal_def): Use it.
8012 (vect_widened_op_tree): Likewise.
8013 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
8014 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
8015 (vectorizable_reduction): Likewise.
8016 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
8018 (vect_is_slp_reduction): Update calls accordingly. Use
8019 vec_info::lookup_def.
8020 (vect_is_simple_reduction): Likewise
8021 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
8023 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8025 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
8026 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
8027 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
8029 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
8030 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
8031 (vect_update_vf_for_slp, vect_analyze_loop_operations)
8032 (vect_is_slp_reduction, vectorizable_induction)
8033 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
8034 * tree-vect-patterns.c (vect_init_pattern_stmt):
8035 (vect_determine_min_output_precision_1, vect_determine_precisions)
8036 (vect_pattern_recog): Likewise.
8037 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
8038 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
8039 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
8040 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
8041 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
8042 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
8043 info field from a loop to a loop_vec_info.
8045 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8047 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
8048 (vec_info::add_stmt): Declare.
8049 * tree-vectorizer.c (vec_info::add_stmt): New function.
8050 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
8051 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
8052 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
8053 (vectorizable_induction): Likewise.
8054 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
8055 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
8056 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
8057 (vectorizable_load): Likewise.
8058 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
8059 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
8060 (vect_recog_gather_scatter_pattern): Likewise.
8061 (append_pattern_def_seq): Likewise. Remove a check that is
8062 performed by add_stmt itself.
8064 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8066 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
8067 which make_ssa_name was called with new_stmt before new_stmt
8070 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8072 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
8074 (vect_is_slp_reduction): ...here...
8075 (vect_is_simple_reduction): ...and here. Remove repetition of tests
8076 that are already known to be false.
8078 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8080 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
8081 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
8082 STMT_VINFO_NUM_SLP_USES when it's true.
8083 (vect_free_slp_instance): Add a final_p parameter and pass it to
8085 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
8086 (vect_analyze_slp_instance): Likewise.
8087 (vect_slp_analyze_operations): Likewise.
8088 (vect_slp_analyze_bb_1): Likewise.
8089 * tree-vectorizer.c (vec_info): Likewise.
8090 * tree-vect-loop.c (vect_transform_loop): Likewise.
8092 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8094 * tree-vect-loop.c (vectorizable_reduction): Assert that the
8095 function is not called for second and subsequent members of
8098 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8100 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
8101 cases for nested loops from here to ...
8102 (vect_create_epilog_for_reduction): ...here. Only call
8103 vect_is_simple_use for inner-loop reductions.
8105 2018-07-31 Martin Liska <mliska@suse.cz>
8107 PR gcov-profile/85338
8108 PR gcov-profile/85350
8109 PR gcov-profile/85372
8110 * profile.c (struct location_triplet): New.
8111 (struct location_triplet_hash): Likewise.
8112 (output_location): Do not output a BB that
8113 is already recorded for a line.
8114 (branch_prob): Use streamed_locations.
8116 2018-07-31 Martin Liska <mliska@suse.cz>
8118 PR gcov-profile/85370
8119 * coverage.c (coverage_begin_function): Do not mark target
8120 clones as artificial functions.
8122 2018-07-31 Martin Liska <mliska@suse.cz>
8124 PR gcov-profile/83813
8125 PR gcov-profile/84758
8126 PR gcov-profile/85217
8127 PR gcov-profile/85332
8128 * profile.c (branch_prob): Do not record GOTO expressions
8129 for GIMPLE statements which locations are already streamed.
8131 2018-07-31 Olivier Hainque <hainque@adacore.com>
8133 * gcc.c (handle_spec_function): Accept a soft_matched_part
8134 argument, as do_spec_1. Pass it down to ...
8135 (eval_spec_function): Accept a soft_matched_part argument,
8136 and pass it down to ...
8137 (do_spec_2): Accept a soft_matched_part argument, and pass
8138 it down to do_spec_1.
8139 (do_spec_1): Pass soft_matched_part to handle_spec_function.
8140 (handle_braces): Update call to handle_spec_function.
8141 (driver::set_up_specs): Update calls to do_spec_2.
8142 (compare_debug_dump_opt_spec_function): Likewise.
8143 (compare_debug_self_opt_spec_function): Likewise.
8145 2018-07-31 Olivier Hainque <hainque@adacore.com>
8147 * common.opt (nolibc): New option.
8148 * doc/invoke.texi (Link Options): Document it.
8149 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
8150 * config/alpha/linux.h: Likewise.
8151 * config/arc/elf.h: Likewise.
8152 * config/arm/uclinux-elf.h: Likewise.
8153 * config/arm/unknown-elf.h: Likewise.
8154 * config/avr/avrlibc.h: Likewise.
8155 * config/bfin/bfin.h: Likewise.
8156 * config/bfin/linux.h: Likewise.
8157 * config/bfin/uclinux.h: Likewise.
8158 * config/darwin.h: Likewise.
8159 * config/darwin10.h: Likewise.
8160 * config/darwin12.h: Likewise.
8161 * config/gnu-user.h: Likewise.
8162 * config/lm32/uclinux-elf.h: Likewise.
8163 * config/pa/pa-hpux11.h: Likewise.
8164 * config/pa/pa64-hpux.h: Likewise.
8165 * config/sparc/sparc.h: Likewise.
8167 2018-07-31 Olivier Hainque <hainque@adacore.com>
8169 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
8170 undefined variables.
8172 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
8175 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
8178 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
8180 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
8181 terminated string literal.
8183 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
8185 PR rtl-optimization/85160
8186 * combine.c (is_just_move): New function.
8187 (try_combine): Allow combining two instructions into two if neither of
8188 the original instructions was a move.
8190 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
8193 * doc/extend.texi (Global Register Variables): Discourage use of type
8195 (Local Register Variables): Likewise.
8197 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
8199 PR tree-optimization/86506
8200 * hwint.h (ceil_log2): Resync with hwint.c implementation.
8202 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
8205 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
8206 hard_regno, make sure no insn between `from` and `to` clobbers it.
8208 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
8209 Tom de Vries <tdevries@suse.de>
8211 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
8212 (PTX_DEFAULT_RUNTIME_DIM): ... this.
8213 (nvptx_goacc_validate_dims): Set default worker and gang dims to
8214 PTX_DEFAULT_RUNTIME_DIM.
8215 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
8217 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
8219 * config/pa/pa.c (pa_output_addr_vec): Align address table.
8220 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
8221 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
8223 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
8225 * config/rs6000/constraints.md (wG constraint): Delete, no longer
8227 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
8228 predicate to reflect toc fusion has been deleted.
8229 (toc_fusion_mem_raw): Delete, no longer used.
8230 (toc_fusion_mem_wrapped): Likewise.
8231 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
8233 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
8234 Delete, no longer used.
8235 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
8236 meant to be used for toc fusion.
8237 (rs6000_debug_print_mode): Delete toc fusion debugging.
8238 (rs6000_debug_reg_global): Likewise.
8239 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
8240 fusion and secondary reload support that were never used.
8241 (rs6000_option_override_internal): Delete TOC fusion, that was only
8242 partially defined, and it did not work unless you also used the
8244 (rs6000_legitimate_address_p): Delete TOC fusion support.
8245 (rs6000_opt_masks): Likewise.
8246 (fusion_wrap_memory_address): Delete function, no longer used.
8247 (fusion_split_address); Delete TOC fusion support.
8248 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
8249 longer used with toc fusion being deleted.
8250 (TARGET_TOC_FUSION_FP): Likewise.
8251 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
8253 (toc fusion spliter): Delete TOC fusion support.
8254 (toc_fusionload_<mode>): Likewise.
8255 (toc_fusionload_di): Likewise.
8256 (fusion_gpr_load_<mode>): Delete generator function, this insn no
8257 longer needs to be named. Rename predicate to delete TOC fusion.
8258 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
8259 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
8260 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
8261 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
8262 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
8264 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
8266 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
8267 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
8268 __int128 in built-in function prototypes.
8269 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
8270 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
8272 2018-07-27 Martin Sebor <msebor@redhat.com>
8274 PR tree-optimization/86696
8275 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
8276 types, including enums.
8277 (handle_char_store): Be prepared for the above function to fail.
8279 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
8281 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
8282 when optimization level is lower than 2 or optimize for size.
8284 2018-07-26 Martin Sebor <msebor@redhat.com>
8286 PR tree-optimization/86043
8287 PR tree-optimization/86042
8288 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
8289 (get_string_cst_length): Rename...
8290 (get_min_string_length): ...to this. Add argument.
8291 (handle_char_store): Extend to handle multi-character stores by
8293 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
8294 * tree.h (initializer_zerop): Add argument.
8296 2018-07-26 Jakub Jelinek <jakub@redhat.com>
8299 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
8300 declare target to variables if they have always,{to,from,tofrom} map
8303 2018-07-26 Martin Liska <mliska@suse.cz>
8306 * lto-wrapper.c: Add linker_output as prefix
8307 for ltrans_output_file.
8309 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
8311 PR rtl-optimization/85805
8312 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
8313 value for hard registers if that was written in the same mode.
8315 2018-07-26 Martin Liska <mliska@suse.cz>
8317 PR gcov-profile/86536
8318 * gcov.c (format_gcov): Use printf format %.*f directly
8319 and do not handle special values.
8321 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
8323 * common/config/arc/arc-common.c (arc_option_optimization_table):
8324 Update default optimizations for size.
8326 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
8328 * config/arc/arc.md (movsf_insn): Add short instruction selection.
8329 * config/arc/constraints.md (CfZ): New constraint.
8330 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
8331 (subsf3_fpu): Likewise.
8332 (cmpsf_fpu): Likewise.
8333 (cmpsf_fpu_uneq): Likewise.
8335 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
8337 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
8339 (arc_is_uncached_mem_p): uncached applies to both the variable and
8342 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
8344 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
8347 2018-07-25 David Malcolm <dmalcolm@redhat.com>
8349 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
8350 field "m_scopes" from vec to auto_vec.
8352 2018-07-25 Martin Liska <mliska@suse.cz>
8354 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
8357 2018-07-25 Richard Biener <rguenther@suse.de>
8360 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
8361 special wrt context_die late.
8362 (gen_subprogram_die): Re-use DIEs in local scope.
8364 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
8366 PR tree-optimization/86644
8367 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
8369 2018-07-25 Martin Liska <mliska@suse.cz>
8372 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
8373 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
8375 2018-07-25 Martin Liska <mliska@suse.cz>
8378 * params.def: Explain ASan abbreviation and provide
8379 a documentation link.
8381 2018-07-24 Martin Sebor <msebor@redhat.com>
8383 PR tree-optimization/86622
8384 PR tree-optimization/86532
8385 * builtins.h (string_length): Declare.
8386 * builtins.c (c_strlen): Correct handling of non-constant offsets.
8387 (check_access): Be prepared for non-constant length ranges.
8388 (string_length): Make extern.
8389 * expr.c (string_constant): Only handle the minor non-constant
8390 array index. Use string_constant to compute the length of
8391 a generic string constant.
8393 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
8395 PR tree-optimization/86618
8396 * tree-vect-stmts.c (vectorizable_call): Don't take the address
8397 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
8399 2018-07-24 David Malcolm <dmalcolm@redhat.com>
8401 PR tree-optimization/86636
8402 * json.cc (json::object::set): Fix comment. Add assertions.
8403 (json::array::append): Move here from json.h. Add comment and an
8405 (json::string::string): Likewise.
8406 * json.h (json::array::append): Move to json.cc.
8407 (json::string::string): Likewise.
8408 * optinfo-emit-json.cc
8409 (optrecord_json_writer::impl_location_to_json): Assert that we
8410 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
8411 wrapper around it. Expand the location once, rather than three
8413 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
8414 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
8416 (optrecord_json_writer::optinfo_to_json): Likewise, in four
8417 places. Fix some overlong lines.
8419 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
8421 * config/aarch64/aarch64-simd.md
8422 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
8423 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
8424 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
8425 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
8426 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
8427 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
8428 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
8429 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
8430 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
8432 2018-07-24 Jakub Jelinek <jakub@redhat.com>
8435 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
8436 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
8437 and abs_d == d, do the power of two handling if profitable.
8439 2018-07-24 Richard Biener <rguenther@suse.de>
8441 * match.pd: Add BIT_FIELD_REF canonicalizations.
8443 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
8446 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
8448 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
8450 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
8451 terminated STRING_CST object.
8453 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
8455 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
8457 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
8459 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
8460 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
8461 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
8462 the elements into a register.
8463 (rs6000_split_v4si_init_di_reg): Delete.
8464 (rs6000_split_v4si_init): Delete.
8465 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
8466 (vsx_init_v4si): Rewrite as a define_expand.
8468 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
8470 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
8471 zero_extend argument from memory): New.
8473 2018-07-22 Martin Sebor <msebor@redhat.com>
8476 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
8477 diagnosing calls with unknown arguments unless -Walloca-larger-than
8478 is restricted to less than PTRDIFF_MAX bytes.
8480 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
8482 * doc/gcov.texi (Invoking Gcov): Editorial changes.
8484 2018-07-20 David Malcolm <dmalcolm@redhat.com>
8486 * pretty-print.c (text_info::set_location): Remove redundant
8487 "line_table" parameter from call to rich_location::set_range.
8489 2018-07-20 Martin Sebor <msebor@redhat.com>
8492 * builtins.c (expand_builtin_alloca): Adjust.
8493 * calls.c (alloc_max_size): Simplify.
8494 * cgraphunit.c (cgraph_node::expand): Adjust.
8495 * common.opt (larger_than_size, warn_frame_larger_than): Remove
8497 (frame_larger_than_size): Same.
8498 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
8499 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
8501 * doc/invoke.texi (GCC Command Options): Document option arguments.
8502 Explain byte-size arguments and suffixes.
8503 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
8504 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
8505 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
8506 * doc/options.texi (UInteger): Expand.
8507 (Host_Wide_Int, ByteSize): Document new properties.
8508 * final.c (final_start_function_1): Include sizes in an error message.
8509 * function.c (frame_offset_overflow): Same.
8510 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
8511 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
8512 Diagnose unbounded alloca calls only for limits of less than
8514 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
8515 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
8517 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
8518 only for limits of less than PTRDIFF_MAX.
8519 * langhooks-def.h (lhd_handle_option): Change function argument
8521 * langhooks.c (lhd_handle_option): Same.
8522 * langhooks.h (handle_option): Same.
8523 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
8525 (var_type, var_type_struct): Same.
8526 (var_set): Handle ByteSize flag.
8527 * optc-gen.awk: Add comments to output to ease debugging. Make
8528 use of HOST_WIDE_INT where appropriate.
8529 * opts-gen-save.awk: Use %lx to format unsigned long.
8530 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
8531 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
8532 arguments. Parse bytes-size suffixes.
8533 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
8534 (enum_value_to_arg): Same.
8535 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
8536 (handle_option): Adjust.
8537 (generate_option): Change function argument to HOST_WIDE_INT.
8538 (cmdline_handle_error): Adjust.
8539 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
8540 (set_option): Change function argument to HOST_WIDE_INT.
8541 (option_enabled): Handle cl_host_wide_int.
8542 (get_option_state): Handle CLVC_SIZE.
8543 (control_warning_option): Same.
8544 * opts.c (common_handle_option): Change function argument to
8545 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
8546 OPT_Wvla_larger_than_.
8547 * opts.h (enum cl_var_type): Add an enumerator.
8548 * stor-layout.c (layout_decl): Print a more meaningful warning.
8549 * toplev.c (output_stack_usage): Adjust.
8551 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
8553 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
8554 call to inline_expand_builtin_string_cmp.
8555 (expand_builtin_strcmp): Likewise.
8556 (expand_builtin_strncmp): Likewise.
8557 (inline_string_cmp): Delete the last parameter, change char_type_node
8558 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
8560 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
8561 the inlining expansion on target where the type of the call has same or
8562 narrower precision than unsigned char.
8564 2018-07-20 David Malcolm <dmalcolm@redhat.com>
8566 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
8567 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
8568 * common.opt (fsave-optimization-record): New option.
8569 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
8570 * doc/invoke.texi (-fsave-optimization-record): New option.
8571 * dumpfile.c: Include "optinfo-emit-json.h".
8572 (struct kv_pair): Move to coretypes.h.
8573 (optgroup_options): Make non-static.
8574 (dump_context::end_scope): Call
8575 optimization_records_maybe_pop_dump_scope.
8576 * dumpfile.h (optgroup_options): New decl.
8577 * json.cc: New file.
8579 * optinfo-emit-json.cc: New file.
8580 * optinfo-emit-json.h: New file.
8581 * optinfo.cc: Include "optinfo-emit-json.h".
8582 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
8583 (optinfo_enabled_p): Check optimization_records_enabled_p.
8584 (optinfo_wants_inlining_info_p): Likewise.
8585 * optinfo.h: Update comment.
8586 * profile-count.c (profile_quality_as_string): New function.
8587 * profile-count.h (profile_quality_as_string): New decl.
8588 (profile_count::quality): New accessor.
8589 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
8590 and optinfo_emit_json_cc_tests.
8591 * selftest.h (selftest::json_cc_tests): New decl.
8592 (selftest::optinfo_emit_json_cc_tests): New decl.
8593 * toplev.c: Include "optinfo-emit-json.h".
8594 (compile_file): Call optimization_records_finish.
8595 (do_compile): Call optimization_records_start.
8596 * tree-ssa-live.c: Include optinfo.h.
8597 (remove_unused_scope_block_p): Retain inlining information if
8598 optinfo_wants_inlining_info_p returns true.
8600 2018-07-20 Richard Biener <rguenther@suse.de>
8603 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
8604 to cover -flto-partition=none.
8606 2018-07-20 Martin Liska <mliska@suse.cz>
8608 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
8609 (get_decl_source_range): Remove unused function.
8611 2018-07-20 Richard Biener <rguenther@suse.de>
8613 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
8614 (struct vn_phi_s): Likewise.
8615 (struct vn_reference_s): Likewise.
8616 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
8617 for searching the slot of an entry known to be in the hash itself.
8618 (vn_phi_hasher::equal): Likewise.
8619 (vn_reference_hasher::equal): Likewise.
8620 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
8622 (optimistic_info, current_info): Remove, keeping only valid_info.
8623 (vn_reference_lookup_1): Remove fallback lookup.
8624 (vn_reference_lookup_2): Likewise.
8625 (vn_nary_op_lookup_1): Likewise.
8626 (vn_phi_lookup): Likewise.
8627 (vn_nary_build_or_lookup_1): Make sure to not chain the built
8629 (vn_reference_insert): Adjust, chain the inserted hash element
8630 at last_inserted_ref.
8631 (vn_reference_insert_pieces): Likewise.
8632 (visit_reference_op_call): Likewise.
8633 (vn_nary_op_insert_into): Chain the inserted hash element at
8635 (vn_nary_op_insert_pieces): Adjust.
8636 (vn_nary_op_insert): Likewise.
8637 (vn_nary_op_insert_stmt): Likewise.
8638 (vn_phi_insert): Adjust, chain the inserted hash element at
8640 (process_scc): Remove clearing and copying the optimistic
8641 table. Instead remove elements inserted during an optimistic
8642 iteration from the single table we maintain.
8643 (init_scc_vn): Adjust.
8644 (free_scc_vn): Likewise.
8645 (sccvn_dom_walker::record_cond): Likewise.
8646 (sccvn_dom_walker::after_dom_children): Likewise.
8648 2018-07-19 Martin Sebor <msebor@redhat.com>
8650 PR tree-optimization/84047
8651 PR tree-optimization/83776
8652 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
8653 (check_array_bounds): Call it.
8655 2018-07-19 Martin Sebor <msebor@redhat.com>
8657 * align.h (align_flags): Use member initialization.
8659 2018-07-19 David Malcolm <dmalcolm@redhat.com>
8661 * Makefile.in (OBJS): Add optinfo.o.
8662 * coretypes.h (class symtab_node): New forward decl.
8663 (struct cgraph_node): New forward decl.
8664 (class varpool_node): New forward decl.
8665 * dump-context.h: New file.
8666 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
8668 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
8669 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
8670 (set_alt_dump_file): Likewise.
8671 (dump_context::~dump_context): New dtor.
8672 (dump_gimple_stmt): Move implementation to...
8673 (dump_context::dump_gimple_stmt): ...this new member function.
8674 Add the stmt to any pending optinfo, creating one if need be.
8675 (dump_gimple_stmt_loc): Move implementation to...
8676 (dump_context::dump_gimple_stmt_loc): ...this new member function.
8677 Start a new optinfo and add the stmt to it.
8678 (dump_gimple_expr): Move implementation to...
8679 (dump_context::dump_gimple_expr): ...this new member function.
8680 Add the stmt to any pending optinfo, creating one if need be.
8681 (dump_gimple_expr_loc): Move implementation to...
8682 (dump_context::dump_gimple_expr_loc): ...this new member function.
8683 Start a new optinfo and add the stmt to it.
8684 (dump_generic_expr): Move implementation to...
8685 (dump_context::dump_generic_expr): ...this new member function.
8686 Add the tree to any pending optinfo, creating one if need be.
8687 (dump_generic_expr_loc): Move implementation to...
8688 (dump_context::dump_generic_expr_loc): ...this new member
8689 function. Add the tree to any pending optinfo, creating one if
8691 (dump_printf): Move implementation to...
8692 (dump_context::dump_printf_va): ...this new member function. Add
8693 the text to any pending optinfo, creating one if need be.
8694 (dump_printf_loc): Move implementation to...
8695 (dump_context::dump_printf_loc_va): ...this new member function.
8696 Start a new optinfo and add the stmt to it.
8697 (dump_dec): Move implementation to...
8698 (dump_context::dump_dec): ...this new member function. Add the
8699 value to any pending optinfo, creating one if need be.
8700 (dump_context::dump_symtab_node): New member function.
8701 (dump_context::get_scope_depth): New member function.
8702 (dump_context::begin_scope): New member function.
8703 (dump_context::end_scope): New member function.
8704 (dump_context::ensure_pending_optinfo): New member function.
8705 (dump_context::begin_next_optinfo): New member function.
8706 (dump_context::end_any_optinfo): New member function.
8707 (dump_context::s_current): New global.
8708 (dump_context::s_default): New global.
8709 (dump_scope_depth): Delete global.
8710 (dumpfile_ensure_any_optinfo_are_flushed): New function.
8711 (dump_symtab_node): New function.
8712 (get_dump_scope_depth): Reimplement in terms of dump_context.
8713 (dump_begin_scope): Likewise.
8714 (dump_end_scope): Likewise.
8715 (selftest::temp_dump_context::temp_dump_context): New ctor.
8716 (selftest::temp_dump_context::~temp_dump_context): New dtor.
8717 (selftest::verify_item): New function.
8718 (ASSERT_IS_TEXT): New macro.
8719 (ASSERT_IS_TREE): New macro.
8720 (ASSERT_IS_GIMPLE): New macro.
8721 (selftest::test_capture_of_dump_calls): New test.
8722 (selftest::dumpfile_c_tests): Call it.
8723 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
8724 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
8725 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
8726 descriptive comment.
8727 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
8728 (dump_node, dump_bb): Move these unrelated decls.
8729 (class dump_manager): Add leading comment.
8730 * optinfo.cc: New file.
8731 * optinfo.h: New file.
8733 2018-07-19 Michael Collison <michael.collison@arm.com>
8734 Richard Henderson <rth@redhat.com>
8736 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
8737 (subti): Handle op1 zero.
8738 (subvti4, usub4ti4): New.
8739 (*sub<GPI>3_compare1_imm): New.
8740 (sub<GPI>3_carryinCV): New.
8741 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
8742 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
8744 2018-07-19 Michael Collison <michael.collison@arm.com>
8745 Richard Henderson <rth@redhat.com>
8747 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
8748 (addti3): Create simpler code if low part is already known to be 0.
8749 (addvti4, uaddvti4): New.
8750 (*add<GPI>3_compareC_cconly_imm): New.
8751 (*add<GPI>3_compareC_cconly): New.
8752 (*add<GPI>3_compareC_imm): New.
8753 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
8754 handle constants within this pattern..
8755 (*add<GPI>3_compareV_cconly_imm): New.
8756 (*add<GPI>3_compareV_cconly): New.
8757 (*add<GPI>3_compareV_imm): New.
8758 (add<GPI>3_compareV): New.
8759 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
8760 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
8761 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
8762 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
8763 with 'comparison' operator.
8764 (*add<GPI>3_compareV_cconly_imm): Ditto.
8765 (*add<GPI>3_compareV_cconly): Ditto.
8766 (*add<GPI>3_compareV_imm): Ditto.
8767 (add<GPI>3_compareV): Ditto.
8768 (add<mode>3_carryinC): Ditto.
8769 (*add<mode>3_carryinC_zero): Ditto.
8770 (*add<mode>3_carryinC): Ditto.
8771 (add<mode>3_carryinV): Ditto.
8772 (*add<mode>3_carryinV_zero): Ditto.
8773 (*add<mode>3_carryinV): Ditto.
8775 2018-07-19 Michael Collison <michael.collison@arm.com>
8776 Richard Henderson <rth@redhat.com>
8778 * config/aarch64/aarch64-modes.def (CC_V): New.
8779 * config/aarch64/aarch64-protos.h
8780 (aarch64_addti_scratch_regs): Declare
8781 (aarch64_subvti_scratch_regs): Declare.
8782 (aarch64_expand_subvti): Declare.
8783 (aarch64_gen_unlikely_cbranch): Declare
8784 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
8785 for signed overflow using CC_Vmode.
8786 (aarch64_get_condition_code_1): Handle CC_Vmode.
8787 (aarch64_gen_unlikely_cbranch): New function.
8788 (aarch64_addti_scratch_regs): New function.
8789 (aarch64_subvti_scratch_regs): New function.
8790 (aarch64_expand_subvti): New function.
8792 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
8794 * config/aarch64/aarch64-option-extensions.def: New entry for profile
8796 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
8797 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
8800 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
8803 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
8804 address check not strict.
8806 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
8808 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
8810 (store_pair_lanes<mode>): Likewise.
8811 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
8812 enum value 'ADDR_QUERY_LDP_STP_N'.
8813 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
8814 (aarch64_print_address_internal): Add declaration.
8815 (aarch64_print_ldpstp_address): Remove.
8816 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
8817 (aarch64_print_operand): Change printing of 'y'.
8818 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
8819 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
8820 'true' rather than '1'.
8821 * config/aarch64/constraints.md (Uml): Likewise.
8822 (Uml): Rename to Umn.
8825 2018-07-19 Richard Biener <rguenther@suse.de>
8827 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
8829 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
8830 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
8831 (vn_reference_hasher): Likewise.
8832 (struct vn_tables_s): Remove obstack and alloc-pool members.
8833 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
8834 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
8835 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
8836 (vn_reference_insert_pieces): Likewise.
8837 (alloc_vn_nary_op_noinit): Adjust.
8838 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
8839 (vn_phi_eq): Adjust.
8840 (shared_lookup_phiargs): Remove.
8841 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
8842 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
8843 (visit_reference_op_call): Likewise.
8844 (copy_nary, copy_phi, copy_reference): Remove.
8845 (process_scc): Rewind the obstack when iterating. Do not
8846 copy the elements to valid_info but just move them from one
8847 hashtable to the other.
8848 (allocate_vn_table): Adjust.
8849 (free_vn_table): Likewise.
8850 (init_scc_vn): Likewise.
8851 (free_scc_vn): Likewise.
8853 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
8856 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
8857 indirect_return as function type attribute.
8858 (ix86_attribute_table): Change indirect_return to function
8860 * doc/extend.texi: Update indirect_return attribute.
8862 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
8864 * wide-int.h (widest2_int): New.
8865 * gimple-fold.c (arith_overflowed_p): Use it.
8866 * tree.h (widest2_int_cst): New.
8867 * tree-vrp.c (wide_int_binop_overflow): Rename from
8868 vrp_int_const_binop.
8869 Rewrite to work on trees.
8870 (extract_range_from_multiplicative_op_1): Abstract code to...
8871 (wide_int_range_min_max): ...here.
8872 (wide_int_range_cross_product): ...and here.
8873 (extract_range_from_binary_expr_1): Abstract overflow code to...
8874 (wide_int_range_mult_wrapping): ...here.
8875 * tree-vrp.h (wide_int_range_cross_product): New.
8876 (wide_int_range_mult_wrapping): New.
8878 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
8879 Julia Koval <julia.koval@intel.com>
8881 * config/i386/x86-tune-costs.h (skylake_memcpy,
8882 skylake_memset): Replace rep_prefix with unrolling for size 512.
8884 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
8887 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
8888 comparision with EQ_EXPR in last stmt.
8890 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
8892 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
8893 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
8894 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
8895 previously known as "PowerPC AltiVec Built-in Functions". Move
8896 some material to new subsubsections "PowerPC AltiVec Built-in
8897 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
8899 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
8900 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
8901 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
8902 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
8904 2018-07-18 Richard Biener <rguenther@suse.de>
8906 PR tree-optimization/86557
8907 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
8910 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
8912 * config/s390/s390.c (s390_function_profiler): Generate CFI.
8914 2018-07-17 Jeff Law <law@redhat.com>
8916 * config/arm/arm.c (get_label_padding): Update for recent
8917 changes to label_to_alignment.
8919 PR tree-optimization/86010
8920 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
8922 * config/mips/mips.c (vr4130_align_insns): Update for recent
8923 changes to label_to_alignment.
8925 * config/frv/frv.c (frv_label_align): Update for recent changes
8926 to label_to_alignment.
8928 * config/nios2/nios2.c (nios2_label_align): Update for recent
8929 changes which dropped ALIGN_LABELS_LOG.
8931 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
8933 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
8934 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
8936 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
8938 * config/arc/arc.c (arc_label_align): Use align_labels instead of
8939 deprecated align_labels_log.
8941 2018-07-17 Richard Biener <rguenther@suse.de>
8944 * dwarf2out.c (init_sections_and_labels): Always generate
8945 a debug_line_str_section for early LTO debug.
8946 (dwarf2out_finish): Reset debug_line_str_hash output early.
8947 Bump counter for extra dwarf5 .debug_loc labels to not conflict
8949 (dwarf2out_early_finish): Output debug_line_str.
8951 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
8953 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
8954 index register on z196 or later.
8956 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
8958 * config/s390/s390.c (s390_default_align): Set default function
8960 (s390_override_options_after_change): Call s390_default align.
8961 (s390_option_override_internal): Call s390_default_align.
8962 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
8964 2018-07-17 Jakub Jelinek <jakub@redhat.com>
8967 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
8968 to _looptemp_ clauses, other than the first two.
8970 2018-07-17 Martin Liska <mliska@suse.cz>
8972 * opts.c: Do not enable OPT_falign_* for -Os.
8974 2018-07-17 Martin Liska <mliska@suse.cz>
8976 * align.h (MAX_CODE_ALIGN): New.
8977 (MAX_CODE_ALIGN_VALUE): New.
8978 * common/config/i386/i386-common.c (ix86_handle_option):
8979 (MAX_CODE_ALIGN): Moved to align.h.
8980 * final.c (MAX_CODE_ALIGN): Likewise.
8981 * opts.c (parse_and_check_align_values):
8982 (MAX_CODE_ALIGN): Likewise.
8983 (MAX_CODE_ALIGN_VALUE): Likewise.
8985 2018-07-17 Martin Liska <mliska@suse.cz>
8987 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
8988 in order to fulfil coding style.
8989 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
8990 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8991 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
8992 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
8993 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
8994 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
8995 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
8996 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
8997 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8999 2018-07-17 Martin Liska <mliska@suse.cz>
9001 * align.h: New file.
9002 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
9004 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
9005 align_flags of label_to_alignment.
9006 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
9008 * config/m68k/m68k.c: Do not use removed align_labels_value and
9010 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
9011 (LOOP_ALIGN): Likewise.
9012 (LABEL_ALIGN): Likewise.
9013 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
9014 Remove not used macro.
9015 (rs6000_loop_align): Change return type to align_flags.
9016 (rs6000_loop_align_max_skip): Remove.
9017 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
9018 Change return type to align_flags.
9019 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
9020 Remove not used macro.
9021 (rs6000_loop_align): Change return type to align_flags.
9022 (rs6000_loop_align_max_skip): Remove.
9023 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
9024 * config/rx/rx-protos.h (rx_align_for_label): Make it
9026 * config/rx/rx.c (rx_align_for_label): Change return type
9028 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
9030 into align_flags class.
9031 (LABEL_ALIGN): Likewise.
9032 (LOOP_ALIGN): Likewise.
9033 * config/s390/s390.c (s390_label_align): Use align_flags
9035 (s390_asm_output_function_label): Likewise.
9036 * config/sh/sh.c (sh_override_options_after_change):
9037 Use align_flags class directly without macros.
9038 (find_barrier): Likewise.
9039 (barrier_align): Likewise.
9040 (sh_loop_align): Likewise.
9041 * config/spu/spu.c (spu_option_override):
9042 Use align_flags_tuple::get_value instead of removed macros.
9043 (spu_sched_init): Likewise.
9044 * config/spu/spu.h (GTY): Likewise.
9045 * config/visium/visium.c (visium_option_override):
9046 Set "8" as default secondary alignment.
9047 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
9048 in order to guarantee secondary alignment of 8.
9049 * coretypes.h: Include align.h header file.
9050 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
9051 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
9052 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
9053 * doc/tm.texi.in: Likewise.
9054 * final.c (struct label_alignment): Remove not used structure.
9055 (LABEL_ALIGN): Change type to align_flags.
9056 (LOOP_ALIGN): Likewise.
9057 (JUMP_ALIGN): Likewise.
9058 (default_loop_align_max_skip): Remove.
9059 (default_label_align_max_skip): Likewise.
9060 (default_jump_align_max_skip): Likewise.
9061 (default_label_align_after_barrier_max_skip):
9062 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
9063 (LABEL_TO_MAX_SKIP): Remove.
9064 (label_to_alignment): Return align_flags type instead of integer.
9065 (label_to_max_skip): Remove.
9066 (align_fuzz): Use align_flags type.
9067 (compute_alignments): Use align_flags type and use align_flags::max
9068 to combine multiple alignments.
9069 (grow_label_align): Grow vec instead of C array.
9070 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
9071 (shorten_branches): Use align_flags type and use align_flags::max
9072 to combine multiple alignments.
9073 (final_scan_insn_1): Remove usage of secondary alignment that comes
9074 from label alignment, but instead use proper secondary alignment
9075 which is computed in grow_label_align.
9076 * flags.h (struct align_flags_tuple): Move to align.h.
9077 (struct align_flags): Likewise.
9078 (state_align_loops): Rename to align_loops.
9079 (state_align_jumps): Rename to align_jumps.
9080 (state_align_labels): Rename to align_labels.
9081 (state_align_functions): Rename to align_functions.
9082 (align_loops_log): Remove.
9083 (align_jumps_log): Remove.
9084 (align_labels_log): Remove.
9085 (align_functions_log): Remove.
9086 (align_loops_max_skip): Remove.
9087 (align_jumps_max_skip): Remove.
9088 (align_labels_max_skip): Remove.
9089 (align_functions_max_skip): Remove.
9090 (align_loops_value): Remove.
9091 (align_jumps_value): Remove.
9092 (align_labels_value): Remove.
9093 (align_functions_value): Remove.
9094 * output.h (label_to_alignment): Change return type to align_flags.
9095 (label_to_max_skip): Remove.
9096 * target.def: Remove loop_align_max_skip, label_align_max_skip,
9097 jump_align_max_skip macros.
9098 * targhooks.h (default_loop_align_max_skip): Remove.
9099 (default_label_align_max_skip): Likewise.
9100 (default_jump_align_max_skip): Likewise.
9101 (default_label_align_after_barrier_max_skip): Remove.
9102 * toplev.c (read_log_maxskip): Use ::normalize function.
9103 (parse_N_M): Remove not used argument and also call ::normalize.
9104 (parse_alignment_opts): Do not pass unused arguments.
9105 * varasm.c (assemble_start_function): Use directly align_functions
9106 instead of removed macros.
9107 * system.h: Do not poison removed macros.
9109 2018-07-17 Jakub Jelinek <jakub@redhat.com>
9112 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
9113 and cond temporaries don't have reference type if iterator has
9114 pointer type. For init use &for_pre_body instead of pre_p if
9115 for_pre_body is non-empty.
9117 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
9119 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
9120 double-double modes to SFmode directly directly.
9121 (trunc<mode>sf2_fprs): Delete.
9123 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
9125 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
9126 for conversions between IFmode and the decimal floating point modes.
9127 (init_float128_ieee): Use the correct names for conversions between
9128 KFmode and the decimal floating point modes.
9130 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
9132 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
9133 for the conversions between TDmode and IFmode.
9134 (init_float128_ieee): Use more correct names for the conversions
9135 between TDmode and KFmode.
9137 2018-07-16 Jakub Jelinek <jakub@redhat.com>
9139 PR tree-optimization/86526
9140 * builtins.c (expand_builtin_memcmp): Formatting fixes.
9141 (inline_expand_builtin_string_cmp): Likewise.
9142 (inline_string_cmp): Likewise. Use c_readstr instead of
9143 builtin_memcpy_read_str. Add unit_mode temporary.
9145 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
9148 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
9149 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
9151 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
9153 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
9154 Alphabetize prototypes of built-in functions, separating out
9155 built-in functions that are listed in this section but should be
9156 described elsewhere.
9158 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
9161 * expmed.c (emit_store_flag): Do not emit setcc followed by a
9162 conditional move when trapping comparison was split to a
9163 non-trapping one (and vice versa).
9165 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
9167 * config/s390/s390.c (s390_function_profiler): Generate nops
9168 instead of profiler call sequences.
9169 * config/s390/s390.opt: Add the new option.
9171 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
9173 * config/s390/s390.c (s390_function_profiler): Generate
9174 __mcount_loc section.
9175 * config/s390/s390.opt: Add the new option.
9177 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
9179 * common.opt: Add the new warning.
9180 * config/s390/s390.c (s390_function_profiler): Emit "brasl
9181 %r0,__fentry__" when -mfentry is specified.
9182 (s390_option_override_internal): Disallow -mfentry for 31-bit
9184 * config/s390/s390.opt: Add the new option.
9186 2018-07-16 Richard Biener <rguenther@suse.de>
9189 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
9190 for function-local FUNCTION_DECL and RESULT_DECL immediately.
9192 2018-07-16 Martin Liska <mliska@suse.cz>
9195 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
9198 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
9200 * config/arc/arcHS.md: Update ARCHS scheduling rules.
9202 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
9204 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
9206 * config/arc/arc-cpus.def (hs4x): New cpu.
9208 * config/arc/arc-tables.opt: Regenerate.
9209 * config/arc/arc.c (arc_sched_issue_rate): New function.
9210 (TARGET_SCHED_ISSUE_RATE): Define.
9211 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
9212 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
9214 (attr tune): Add ARCHS4x tune values.
9215 (attr tune_dspmpy): Define.
9216 (*tst): Correct instruction type.
9217 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
9218 * config/arc/arcHS4x.md: New file.
9219 * config/arc/fpu.md: Update instruction type attributes.
9220 * config/arc/t-multilib: Regenerate.
9222 2018-07-16 Tom de Vries <tdevries@suse.de>
9225 * var-tracking.c (vt_initialize): Fix pre_dec handling.
9227 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
9229 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
9232 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
9234 PR tree-optimization/86514
9235 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
9236 conversion to a boolean type from a type with greater precision.
9238 2018-07-16 Tom de Vries <tdevries@suse.de>
9240 * var-tracking.c (vt_initialize): Print adjusted insn slim if
9241 dump_flags request TDF_SLIM.
9243 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
9245 * fold-const.c (int_const_binop_1): Abstract...
9246 (wide_int_binop): ...wide int code here.
9247 (poly_int_binop): ...poly int code here.
9248 Abstract the rest of int_const_binop_1 into int_const_binop.
9249 * fold-const.h (wide_int_binop): New.
9250 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
9251 Remove useless PLUS/MINUS_EXPR case.
9252 (zero_nonzero_bits_from_vr): Move wide int code...
9253 (zero_nonzero_bits_from_bounds): ...here.
9254 (extract_range_from_binary_expr_1): Move mask optimization code...
9255 (range_easy_mask_min_max): ...here.
9256 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
9257 (range_easy_mask_min_max): New.
9259 2018-07-15 Jeff Law <law@redhat.com>
9262 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
9265 2018-07-14 Jim Wilson <jimw@sifive.com>
9267 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
9269 2018-07-14 Paul Koning <ni1d@arrl.net>
9271 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
9273 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
9275 * lto-streamer-out.c (copy_function_or_variable): Dump info about
9278 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
9279 Steve Munroe <munroesj52@gmail.com>
9281 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
9282 (_mm_andnot_si128): Likewise.
9283 (_mm_or_si128): Likewise.
9284 (_mm_xor_si128): Likewise.
9286 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
9289 * builtins.c (expand_builtin_memcmp): Inline the calls first
9290 when result_eq is false.
9291 (expand_builtin_strcmp): Inline the calls first.
9292 (expand_builtin_strncmp): Likewise.
9293 (inline_string_cmp): New routine. Expand a string compare
9294 call by using a sequence of char comparison.
9295 (inline_expand_builtin_string_cmp): New routine. Inline expansion
9296 a call to str(n)cmp/memcmp.
9297 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
9299 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
9301 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
9303 * config/arm/driver-arm.c: Include arm-native.h.
9304 (host_detect_local_cpu): Use auto-generated data tables.
9305 (vendors, arm_cpu_table): Delete. Move part information to ...
9306 * config/arm/arm-cpus.in: ... here.
9307 * config/arm/parsecpu.awk (gen_native): New function.
9308 (vendor, part): New CPU fields.
9309 (END): Add support for building the native CPU detection tables.
9310 * config/arm/t-arm (arm-native.h): Add build rule.
9311 (driver-arm.o): Add dependency on arm-native.h.
9313 2018-07-13 Richard Biener <rguenther@suse.de>
9316 * match.pd (addr1 - addr2): Allow either of the operand to
9319 2018-07-13 Tom de Vries <tdevries@suse.de>
9321 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
9324 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
9326 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
9327 arrays instead of numbered variables.
9329 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
9331 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
9332 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
9334 2018-07-13 Richard Biener <rguenther@suse.de>
9337 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
9338 instead of get_context_die.
9340 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
9341 Richard Biener <rguenther@suse.de>
9344 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
9345 that the loop latch destination where phi is defined.
9347 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
9349 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
9350 (riscv_expand_epilogue): Add assertion to check interrupt mode.
9351 (riscv_set_current_function): Extract getting interrupt type to new
9353 (riscv_get_interrupt_type): New function.
9354 (riscv_merge_decl_attributes): New function, checking interrupt type is
9356 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
9358 2018-07-12 Paul Koning <ni1d@arrl.net>
9360 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
9363 2018-07-12 Paul Koning <ni1d@arrl.net>
9365 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
9366 zero reference, add doloop_end instead.
9367 * doc/md.texi (decrement_and_branch_until_zero): Remove.
9368 (Looping patterns): Remove decrement_and_branch_until_zero. Add
9369 detail for doloop_end.
9371 2018-07-12 Martin Sebor <msebor@redhat.com>
9374 * attribs.c (decl_attributes): Reject conflicting attributes before
9375 calling attribute handlers.
9377 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
9379 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
9381 (gcc::dump_manager::get_dump_file_name): likewise.
9382 (dump_begin): Likewise.
9383 * dumpfile.h (dump_begin): Update prototype.
9384 (gcc::dump_manager::get_dump_file_name,
9385 gcc::dump_manager::get_dump_file_name): Update prototype.
9387 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
9389 * internal-fn.h (vectorizable_internal_fn_p): New function.
9390 * tree-vect-slp.c (compatible_calls_p): Likewise.
9391 (vect_build_slp_tree_1): Remove nops argument. Handle calls
9392 to internal functions.
9393 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
9395 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
9397 * fold-const.h (inverse_conditions_p): Declare.
9398 * fold-const.c (inverse_conditions_p): New function.
9399 * match.pd: Use inverse_conditions_p. Add folds of view_converts
9400 that test the inverse condition of a conditional internal function.
9401 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
9402 * internal-fn.c (internal_fn_mask_index): Handle conditional
9404 (vectorized_internal_fn_supported_p): New function.
9405 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
9406 (any_pred_load_store): Replace with...
9407 (need_to_predicate): ...this new variable.
9408 (redundant_ssa_names): New variable.
9409 (ifcvt_can_use_mask_load_store): Move initial checks to...
9410 (ifcvt_can_predicate): ...this new function. Handle tree codes
9411 for which a conditional internal function exists.
9412 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
9413 instead of ifcvt_can_use_mask_load_store. Update after variable
9415 (predicate_load_or_store): New function, split out from
9416 predicate_mem_writes.
9417 (check_redundant_cond_expr): New function.
9418 (value_available_p): Likewise.
9419 (predicate_rhs_code): Likewise.
9420 (predicate_mem_writes): Rename to...
9421 (predicate_statements): ...this. Use predicate_load_or_store
9422 and predicate_rhs_code.
9423 (combine_blocks, tree_if_conversion): Update after above name changes.
9424 (ifcvt_local_dce): Handle redundant_ssa_names.
9425 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
9426 general conditional functions.
9427 * tree-vect-stmts.c (vectorizable_call): Likewise.
9429 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
9430 Alan Hayward <alan.hayward@arm.com>
9431 David Sherwood <david.sherwood@arm.com>
9433 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
9434 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
9435 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
9436 plus and minus and convert them into IFN_COND_FMA-based sequences.
9437 (convert_mult_to_fma): Handle conditional plus and minus.
9439 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
9441 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
9442 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
9443 (cond_fnms_optab): New optabs.
9444 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
9446 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
9447 * internal-fn.h (get_conditional_internal_fn): Declare.
9448 (get_unconditional_internal_fn): Likewise.
9449 * internal-fn.c (cond_ternary_direct): New macro.
9450 (expand_cond_ternary_optab_fn): Likewise.
9451 (direct_cond_ternary_optab_supported_p): Likewise.
9452 (FOR_EACH_COND_FN_PAIR): Likewise.
9453 (get_conditional_internal_fn): New function.
9454 (get_unconditional_internal_fn): Likewise.
9455 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
9456 (gimple_match_op::gimple_match_op): Add a new overload for 5
9458 (gimple_match_op::set_op): Likewise.
9459 (gimple_resimplify5): Declare.
9460 * genmatch.c (decision_tree::gen): Generate simplifications for
9462 * gimple-match-head.c (gimple_simplify): Define an overload for
9463 5 operands. Handle calls with 5 arguments in the top-level overload.
9464 (convert_conditional_op): Handle conversions from unconditional
9465 internal functions to conditional ones.
9466 (gimple_resimplify5): New function.
9467 (build_call_internal): Pass a fifth operand.
9468 (maybe_push_res_to_seq): Likewise.
9469 (try_conditional_simplification): Try converting conditional
9470 internal functions to unconditional internal functions.
9471 Handle 3-operand unconditional forms.
9472 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
9473 Define ternary equivalents of the current rules for binary conditional
9475 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
9477 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
9478 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
9479 (optab): Handle them.
9480 (SVE_COND_FP_TERNARY): New int iterator.
9481 (sve_fmla_op, sve_fmad_op): New int attributes.
9482 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
9483 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
9484 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
9486 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
9488 * target.def (preferred_else_value): New target hook.
9489 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
9490 * doc/tm.texi: Regenerate.
9491 * targhooks.h (default_preferred_else_value): Declare.
9492 * targhooks.c (default_preferred_else_value): New function.
9493 * internal-fn.h (conditional_internal_fn_code): Declare.
9494 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
9495 (get_conditional_internal_fn): Use it.
9496 (conditional_internal_fn_code): New function.
9497 * gimple-match.h (gimple_match_cond): New struct.
9498 (gimple_match_op): Add a cond member function.
9499 (gimple_match_op::gimple_match_op): Update all forms to take a
9501 * genmatch.c (expr::gen_transform): Use the same condition as res_op
9502 for the suboperation, but don't specify a particular else_value.
9503 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
9504 (visit_nary_op, visit_reference_op_load): Pass
9505 gimple_match_cond::UNCOND to the gimple_match_op constructor.
9506 * gimple-match-head.c: Include tree-eh.h
9507 (convert_conditional_op): New function.
9508 (maybe_resimplify_conditional_op): Likewise.
9509 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
9510 (gimple_resimplify2): Likewise.
9511 (gimple_resimplify3): Likewise.
9512 (gimple_resimplify4): Likewise.
9513 (maybe_push_res_to_seq): Return null for conditional operations.
9514 (try_conditional_simplification): New function.
9515 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
9517 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
9519 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
9521 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
9523 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
9525 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
9527 (hash_tree): Do not hash DECL_FCONTEXT
9528 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
9529 Do not stream DECL_FCONTEXT.
9530 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
9531 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
9533 2018-07-12 Richard Biener <rguenther@suse.de>
9536 * dwarf2out.c (gen_block_die): Only output blocks when they have
9537 at least one !DECL_IGNORED_P variable.
9539 2018-07-12 Richard Biener <rguenther@suse.de>
9542 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
9543 Remove -mieee-fp handling.
9545 2018-07-12 Richard Biener <rguenther@suse.de>
9547 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
9548 left-over from last patch.
9550 2018-07-12 Jakub Jelinek <jakub@redhat.com>
9552 PR tree-optimization/86492
9553 * gimple-ssa-store-merging.c
9554 (imm_store_chain_info::coalesce_immediate_stores): Call
9555 check_no_overlap even for the merge_overlapping case. Formatting fix.
9557 2018-07-12 Richard Biener <rguenther@suse.de>
9560 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
9561 move possibly trapping operations into the conditional.
9563 2018-07-12 Richard Biener <rguenther@suse.de>
9565 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
9566 (vn_lookup_simplify_result): Remove recursion limit applied
9568 (vn_nary_build_or_lookup_1): Adjust.
9569 (try_to_simplify): Likewise.
9570 * gimple-match-head.c (gimple_resimplify1): Instead apply one
9572 (gimple_resimplify2): Likewise.
9573 (gimple_resimplify3): Likewise.
9574 (gimple_resimplify4): Likewise.
9576 2018-07-11 Jakub Jelinek <jakub@redhat.com>
9578 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
9579 Use __mmask64 type instead of __mmask8 for __M argument.
9580 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
9581 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
9583 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
9584 __mmask16 for __M argument.
9585 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
9586 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
9587 to __mmask16 instead of __mmask8.
9588 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
9589 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
9590 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
9591 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
9592 instead of __mmask16 for __U argument.
9593 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
9594 __mmask16 instead of __mmask8 for __U argument.
9595 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
9597 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
9599 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
9601 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
9603 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
9605 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
9607 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
9609 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
9611 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
9613 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
9615 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
9616 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
9617 return type as well as __M argument type and all casts from __mmask8
9619 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
9620 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
9621 return type as well as __M argument type and all casts from __mmask8
9623 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
9624 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
9625 return type as well as __M argument type and all casts from __mmask8
9627 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
9628 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
9629 return type as well as __M argument type and all casts from __mmask8
9631 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
9632 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
9635 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
9637 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
9638 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
9641 2018-07-11 Paul Koning <ni1d@arrl.net>
9643 * doc/md.texi (define_subst): Document how multiple occurrences of
9644 the same argument in the replacement pattern are handled.
9646 2018-07-11 Paul Koning <ni1d@arrl.net>
9648 * doc/extend.texi (Common Variable Attributes): Move "mode" into
9650 (Common Type Attributes): Add "mode" attribute.
9652 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
9654 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
9655 stream DECL_ORIGINAL_TYPE.
9656 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
9657 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
9658 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
9659 Do not walk original type.
9660 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
9662 (write_ts_decl_non_common_tree_pointers): Do not stream
9664 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
9665 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
9667 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
9669 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
9670 thread twice from the same starting edge.
9672 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
9674 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
9675 * gimple.c (gimple_call_nonnull_result_p): ...here...
9676 (gimple_call_nonnull_arg): ...and here.
9677 * gimple.h (gimple_call_nonnull_result_p): New.
9678 (gimple_call_nonnull_arg): New.
9680 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
9682 * config/arm/arm-cpus.in: Move information from fpu field of each
9683 cpu definition to the isa field.
9684 * config/arm/parsecpu.awk (fpu): Delete match rule.
9685 (gen_comm_data): Don't add bits from the CPU's FPU entry.
9687 2018-07-11 Richard Biener <rguenther@suse.de>
9690 * dwarf2out.c (init_sections_and_labels): Use
9691 output_asm_line_debug_info consistently.
9692 (dwarf2out_early_finish): Likewise.
9693 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
9696 2018-07-11 Richard Biener <rguenther@suse.de>
9698 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
9699 Rework father_bb setting in a way to avoid propagating constants
9700 multiple times on a loop body.
9702 2018-07-10 Mark Wielaard <mark@klomp.org>
9705 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
9707 2018-07-10 Richard Biener <rguenther@suse.de>
9709 * hash-map.h (hash_map::iterator::operator*): Return
9710 references to key and value.
9712 2018-07-10 Jakub Jelinek <jakub@redhat.com>
9715 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
9716 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
9717 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
9718 (gimplify_omp_for): For composite loops, move outer
9719 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
9720 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
9721 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
9722 TREE_LIST for both the original class iterator and the "last" helper
9723 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
9724 loop, remember has_decl_expr from outer composite loops for the
9725 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
9727 2018-07-09 Martin Sebor <msebor@redhat.com>
9731 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
9732 accessing implicitly initialized array elements.
9733 * expr.c (string_constant): Handle string initializers of
9734 character arrays within aggregates.
9735 * gimple-fold.c (fold_array_ctor_reference): Add argument.
9736 Store element offset. As a special case, handle zero size.
9737 (fold_nonarray_ctor_reference): Same.
9738 (fold_ctor_reference): Add argument. Store subobject offset.
9739 * gimple-fold.h (fold_ctor_reference): Add argument.
9741 2018-07-09 Paul Koning <ni1d@arrl.net>
9743 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
9744 (pdp11_insn_cost): New function.
9745 (pdp11_md_asm_adjust): New function.
9746 (TARGET_INVALID_WITHIN_DOLOOP): Define.
9747 (pdp11_rtx_costs): Update to match machine better.
9748 (output_addr_const_pdp11): Correct format mismatch warnings.
9749 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
9750 * config/pdp11/pdp11.md: General change to add base_cost and/or
9751 length attributes for use by new pdp11_insn_cost function.
9752 (MIN_BRANCH): Correct definition.
9754 (doloop_end): Use standard pattern name for looping pattern.
9755 (doloop_end_nocc): New.
9756 (movsf): Add another constraint alternative.
9757 (zero_extendqihi2): Add constraint alternatives for not in place
9759 (zero_extendhisi2): Remove.
9760 (shift patterns): Add CC handling variants.
9764 (define_peephole2): New peephole to recognize mov that sets CC for
9767 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9769 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
9770 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
9773 2018-07-09 Jakub Jelinek <jakub@redhat.com>
9776 * real.c (real_nextafter): Return true if result is denormal.
9778 2018-07-09 Martin Liska <mliska@suse.cz>
9780 * common.opt: Add back wrongly removed attribute.
9782 2018-07-09 Richard Biener <rguenther@suse.de>
9785 * dwarf2out.c (gen_block_die): For an early generated DIE
9786 always output high/low PC attributes.
9788 2018-07-09 Tom de Vries <tdevries@suse.de>
9790 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
9791 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
9792 onto VAR_DECL with abstract origin.
9794 2018-07-07 Jim Wilson <jimw@sifive.com>
9796 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
9798 2018-07-07 Tom de Vries <tdevries@suse.de>
9800 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
9802 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
9804 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
9806 (combine_bound): Use wide-int overflow calculation instead of
9808 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
9810 * fold-const.c (int_const_binop_2): Same.
9811 (extract_muldiv_1): Same.
9812 (fold_div_compare): Same.
9813 (fold_abs_const): Same.
9815 * poly-int.h (add): Same.
9819 * predict.c (predict_iv_comparison): Same.
9820 * profile-count.c (slow_safe_scale_64bit): Same.
9821 * simplify-rtx.c (simplify_const_binary_operation): Same.
9822 * tree-chrec.c (tree_fold_binomial): Same.
9823 * tree-data-ref.c (split_constant_offset_1): Same.
9824 * tree-if-conv.c (idx_within_array_bound): Same.
9825 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
9826 * tree-ssa-phiopt.c (minmax_replacement): Same.
9827 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
9828 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
9829 * vr-values.c (vr_values::adjust_range_with_scev): Same.
9830 * wide-int.cc (wi::add_large): Same.
9831 (wi::mul_internal): Same.
9832 (wi::sub_large): Same.
9833 (wi::divmod_internal): Same.
9834 * wide-int.h: Change overflow type to overflow_type for neg, add,
9835 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
9836 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
9837 mul_internal, divmod_internal.
9838 (overflow_type): New enum.
9839 (accumulate_overflow): New.
9841 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
9843 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
9844 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
9846 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
9848 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
9849 argument is checked for zero before entering loop, avoid checking again.
9851 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
9853 * gimplify.h (generic_expr_could_trap_p): Set as global function.
9854 * gimplify.h (generic_expr_could_trap_p): Likwise.
9855 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
9857 2018-07-06 Jakub Jelinek <jakub@redhat.com>
9859 PR tree-optimization/86401
9860 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
9861 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
9862 (fold_bit_and_mask): ... here. New helper function for match.pd.
9863 * fold-const.h (fold_bit_and_mask): Declare.
9864 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
9866 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
9869 * target.def (translate_mode_attribute): New hook.
9870 * targhooks.h (default_translate_mode_attribute): Declare.
9871 * targhooks.c (default_translate_mode_attribute): New function.
9872 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
9873 * doc/tm.texi: Regenerate.
9874 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
9875 (rs6000_translate_mode_attribute): New function.
9877 2018-07-06 Paul Koning <ni1d@arrl.net>
9879 * doc/md.texi (define_split): Document DONE and FAIL.
9880 (define_peephole2): Ditto.
9882 2018-07-05 Jeff Law <law@redhat.com>
9884 PR tree-optimization/86010
9885 * tree-ssa-dse.c (compute_trims): More aggressively trim at
9886 both the head and tail of mem* and str* calls.
9888 2018-07-05 Jim Wilson <jimw@sifive.com>
9890 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
9892 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
9894 * config/aarch64/aarch64-simd.md: correct flags text for
9895 MIN_EXPR replacement.
9897 2018-07-05 James Clarke <jrtc27@jrtc27.com>
9899 * configure: Regenerated.
9901 2018-07-05 Carl Love <cel@us.ibm.com>
9903 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
9904 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
9905 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
9906 VSX_BUILTIN_DOUBLEL_V4SF.
9908 2018-07-05 Martin Sebor <msebor@redhat.com>
9911 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
9912 than its domain to compute its the upper bound of a char array.
9914 2018-07-05 Nathan Sidwell <nathan@acm.org>
9916 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
9917 * doc/cpp.texi: Update comment.
9918 * doc/tm.texi: Rebuilt.
9919 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
9920 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
9921 * doc/extend.texi (Backwards Compatibility): Clarify it is system
9922 headers affected by extern "C".
9923 * system.h: Poison NO_IMPLICIT_EXTERN_C.
9924 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
9925 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
9926 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
9927 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
9928 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
9929 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
9930 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
9931 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
9932 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
9933 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
9934 config/sparc/sp64-elf.h, config/spu/spu.h,
9935 config/stormy16/stormy16.h, config/v850/v850.h,
9936 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
9937 define NO_IMPLICIT_EXTERN_C.
9938 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
9940 2018-07-05 Tamar Christina <tamar.christina@arm.com>
9943 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
9944 instead of GET_MODE_SIZE when comparing Units.
9946 2018-07-05 Tamar Christina <tamar.christina@arm.com>
9949 * rtlanal.c (set_noop_p): Constrain on mode change,
9950 include hard-reg-set.h
9952 2018-07-05 Tamar Christina <tamar.christina@arm.com>
9954 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
9956 2018-07-05 Jakub Jelinek <jakub@redhat.com>
9959 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
9962 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
9964 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
9966 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
9969 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
9971 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
9973 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
9976 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
9978 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
9980 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
9981 neg_*_op* variables.
9983 2018-07-04 Martin Liska <mliska@suse.cz>
9985 * tree-switch-conversion.c: Define
9986 max_ratio_for_speed and max_ratio_for_size constants.
9988 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
9989 Martin Liska <mliska@suse.cz>
9994 * common.opt: Rename align options with 'str_' prefix.
9995 * common/config/i386/i386-common.c (set_malign_value): New
9997 (ix86_handle_option): Use it to set -falign-* options/
9998 * config/aarch64/aarch64-protos.h (struct tune_params): Change
9999 type from int to string.
10000 * config/aarch64/aarch64.c: Update default values from int
10002 * config/alpha/alpha.c (alpha_override_options_after_change):
10004 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
10005 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10006 max skip conditionally.
10007 * config/i386/freebsd.h (SUBALIGN_LOG): New.
10008 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10009 max skip conditionally.
10010 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10011 max skip conditionally.
10012 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
10013 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10014 max skip conditionally.
10015 * config/i386/i386.c (struct ptt): Change type from int to
10017 (ix86_default_align): Set default values.
10018 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
10019 max skip conditionally.
10020 * config/i386/iamcu.h (SUBALIGN_LOG): New.
10021 (ASM_OUTPUT_MAX_SKIP_ALIGN):
10022 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
10023 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10024 max skip conditionally.
10025 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
10026 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
10027 * config/i386/x86-64.h (SUBALIGN_LOG): New.
10028 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
10029 max skip conditionally.
10030 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
10031 * config/ia64/ia64.c (ia64_option_override): Set default values
10032 for alignment options.
10033 * config/m68k/m68k.c: Handle new str_align_* options.
10034 * config/mips/mips.c (mips_set_compression_mode): Change
10036 (mips_option_override): Set default values for options.
10037 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
10039 * config/rs6000/rs6000.c (rs6000_option_override_internal):
10041 * config/rx/rx.c (rx_option_override): Likewise.
10042 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
10043 (LABEL_ALIGN): Use align_labels_log.
10044 (LOOP_ALIGN): Use align_loops_align.
10045 * config/s390/s390.c (s390_asm_output_function_label): Use new
10047 * config/sh/sh.c (sh_override_options_after_change):
10048 Change type of constants.
10049 * config/spu/spu.c (spu_sched_init): Likewise.
10050 * config/sparc/sparc.c (sparc_option_override): Set default
10051 values for options.
10052 * config/visium/visium.c (visium_option_override): Likewise.
10053 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
10054 emit p2align format with last argument if it's not needed.
10055 * doc/invoke.texi: Document extended format of -falign-*.
10056 * final.c: Use align_labels alignment.
10057 * flags.h (struct target_flag_state): Change type to use
10059 (struct align_flags_tuple): New.
10060 (struct align_flags): Likewise.
10061 (align_loops_log): Redefine macro to use new types.
10062 (align_loops_max_skip): Redefine macro to use new types.
10063 (align_jumps_log): Redefine macro to use new types.
10064 (align_jumps_max_skip): Redefine macro to use new types.
10065 (align_labels_log): Redefine macro to use new types.
10066 (align_labels_max_skip): Redefine macro to use new types.
10067 (align_functions_log): Redefine macro to use new types.
10068 (align_loops): Redefine macro to use new types.
10069 (align_jumps): Redefine macro to use new types.
10070 (align_labels): Redefine macro to use new types.
10071 (align_functions): Redefine macro to use new types.
10072 (align_functions_max_skip): Redefine macro to use new types.
10073 (align_loops_value): New macro.
10074 (align_jumps_value): New macro.
10075 (align_labels_value): New macro.
10076 (align_functions_value): New macro.
10077 * function.c (invoke_set_current_function_hook): Propagate
10078 alignment values from flags to global variables default in
10080 * ipa-icf.c (sem_function::equals_wpa): Use
10081 cl_optimization_option_eq instead of memcmp.
10082 * lto-streamer.h (cl_optimization_stream_out): Support streaming
10084 (cl_optimization_stream_in): Likewise.
10085 * optc-save-gen.awk: Support strings in cl_optimization.
10086 * opth-gen.awk: Likewise.
10087 * opts.c (finish_options): Remove error checking of invalid
10089 (MAX_CODE_ALIGN): Remove.
10090 (MAX_CODE_ALIGN_VALUE): Likewise.
10091 (parse_and_check_align_values): New function.
10092 (check_alignment_argument): Likewise.
10093 (common_handle_option): Use check_alignment_argument.
10094 * opts.h (parse_and_check_align_values): Declare.
10095 * toplev.c (init_alignments): Remove.
10096 (read_log_maxskip): New.
10097 (parse_N_M): Likewise.
10098 (parse_alignment_opts): Likewise.
10099 (backend_init_target): Remove usage of init_alignments.
10100 * toplev.h (parse_alignment_opts): Declare.
10101 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
10103 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
10104 * tree.c (cl_option_hasher::equal): New.
10105 * varasm.c: Use new global macros.
10107 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
10109 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
10110 Use a simpler align directive also if MAXSKIP = ALIGN-1.
10111 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10112 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10113 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10114 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
10115 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
10116 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
10117 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
10118 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10119 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10120 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10121 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10123 2018-07-04 Martin Liska <mliska@suse.cz>
10124 Jonathan Wakely <jwakely@redhat.com>
10126 * coverage.c: Use correct type.
10127 * doc/invoke.texi: Language correction.
10129 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
10132 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
10133 ENDBRANCH for non-tail call which may return via indirect branch.
10134 * doc/extend.texi: Document indirect_return attribute.
10136 2018-07-03 Martin Sebor <msebor@redhat.com>
10138 PR tree-optimization/86274
10139 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
10141 (format_floating): Correct handling of infinities and NaNs.
10143 2018-07-03 Martin Sebor <msebor@redhat.com>
10145 * print-tree.c (print_real_cst): New function.
10146 (print_node_brief): Call it.
10147 (print_node): Ditto.
10149 2018-07-03 Jeff Law <law@redhat.com>
10151 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
10152 into a single pattern.
10154 * config/h8300/h8300.md (ors code_iterator): New.
10155 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
10156 a single pattern and single splitter.
10157 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
10158 (iorqi3_1, xorqi3_1): Likewise.
10159 (iorqi3, xorqi3 expanders): Similarly.
10161 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
10162 (movmd_internal) into a single pattern using the P mode iterator.
10163 (movmd splitters): Similarly.
10164 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
10165 (movsd splitters): Similarly.
10167 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
10168 ADDB, ADDW and ADDL into a single ADD attribute which selects the
10169 right table based on the size of the operand.
10170 * config/h8300/h8300.md (length_table): Corresponding changes. All
10171 references to "addb", "addw" and "addl" changed to "add".
10172 (btst patterns): Merge two variants into a single pattern.
10173 (tstqi, tsthi): Likewise.
10174 (addhi3_incdec, addsi3_incdec): Likewise.
10175 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
10176 (mulhi3, mulsi3): Likewise.
10177 (udivhi3, udivsi3): Likewise.
10178 (divhi3, divsi3): Likewise.
10179 (andorqi3, andorhi3, andorsi3): Likewise.
10181 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
10184 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
10185 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
10187 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10189 PR tree-optimization/85694
10190 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
10191 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
10193 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
10194 (<u>avg<mode>3_ceil): New patterns.
10196 2018-07-03 David Malcolm <dmalcolm@redhat.com>
10198 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
10199 scan-tree-dump directive.
10200 * gcc.dg/vect/slp-perm-2.c: Likewise.
10201 * gcc.dg/vect/slp-perm-3.c: Likewise.
10202 * gcc.dg/vect/slp-perm-5.c: Likewise.
10203 * gcc.dg/vect/slp-perm-6.c: Likewise.
10204 * gcc.dg/vect/slp-perm-7.c: Likewise.
10205 * gcc.dg/vect/slp-perm-8.c: Likewise.
10207 2018-07-03 Marek Polacek <polacek@redhat.com>
10209 PR middle-end/86202
10210 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
10212 2018-07-03 Richard Biener <rguenther@suse.de>
10215 * tree-ssa-structalias.c (find_func_clobbers): Properly
10216 handle indirect calls.
10218 2018-07-03 Jeff Law <law@redhat.com>
10220 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
10221 (shifts): New code iterator.
10222 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
10223 expander. Fix HImode handling on H8/SX.
10224 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
10225 (subqi3, subhi3, subsi3 expanders): Likewise.
10226 (andqi3, andhi3, andsi3 expanders): Likewise.
10227 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
10228 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
10229 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
10230 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
10231 (zero_extendqihi2, zero_extendqisi2): Likewise.
10232 (extendqihi2, extendqisi2): Likewise.
10233 (rotlqi3, rotlhi3, rotlsi3): Likewise.
10234 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
10235 (rotlqi3_1, rotlhi3_1): Likewise.
10236 (logicalhi3_sn, logicalsi3_sn): Likewise.
10237 (logicalhi3, logicalsi3): Likewise.
10239 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10241 * tree-vect-patterns.c (vect_recog_rotate_pattern)
10242 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
10243 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
10244 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
10245 type to append_pattern_def_seq instead of creating a stmt_vec_info
10247 (build_mask_conversion): Likewise. Remove vinfo argument.
10248 (vect_add_conversion_to_patterm): Likewise, renaming to...
10249 (vect_add_conversion_to_pattern): ...this.
10250 (vect_recog_mask_conversion_pattern): Update call to
10251 build_mask_conversion. Pass the vector type to
10252 append_pattern_def_seq here too.
10253 (vect_recog_gather_scatter_pattern): Update call to
10254 vect_add_conversion_to_pattern.
10256 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10258 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
10259 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
10260 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
10261 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
10262 STMT_VINFO_PATTERN_DEF_SEQ to null here.
10263 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
10264 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
10265 append_pattern_def_seq instead of new_pattern_def_seq.
10266 (vect_recog_divmod_pattern): Do both of the above.
10267 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
10270 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10272 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
10273 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
10274 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
10275 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
10276 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
10277 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
10278 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
10279 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
10280 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
10281 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
10282 parameter with a single stmt_vec_info.
10283 (vect_recog_func_ptr): Likewise.
10284 (vect_recog_gather_scatter_pattern): Likewise, folding in...
10285 (vect_try_gather_scatter_pattern): ...this.
10286 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
10287 the stmt_vec_info of the statement to be matched. Don't clear
10288 STMT_VINFO_RELATED_STMT.
10289 (vect_pattern_recog): Update call accordingly.
10291 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10293 PR tree-optimization/85694
10294 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
10295 (uavgM3_ceil): Document new optabs.
10296 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
10297 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
10299 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
10300 (savg_ceil_optab): New optabs.
10301 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
10302 (vect_vect_recog_func_ptrs): Add it.
10303 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
10304 constant directly from the associated lhs.
10306 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10308 * tree-vect-patterns.c (vect_split_statement): New function.
10309 (vect_convert_input): Use it to try to split an existing cast.
10311 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10313 * poly-int.h (print_hex): New function.
10314 * dumpfile.h (dump_dec, dump_hex): Declare.
10315 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
10316 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
10317 min_input_precision, operation_precision and operation_sign.
10318 * tree-vect-patterns.c (vect_get_range_info): New function.
10319 (vect_same_loop_or_bb_p, vect_single_imm_use)
10320 (vect_operation_fits_smaller_type): Delete.
10321 (vect_look_through_possible_promotion): Add an optional
10322 single_use_p parameter.
10323 (vect_recog_over_widening_pattern): Rewrite to use new
10324 stmt_vec_info infomration. Handle one operation at a time.
10325 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
10326 (vect_truncatable_operation_p, vect_set_operation_type)
10327 (vect_set_min_input_precision): New functions.
10328 (vect_determine_min_output_precision_1): Likewise.
10329 (vect_determine_min_output_precision): Likewise.
10330 (vect_determine_precisions_from_range): Likewise.
10331 (vect_determine_precisions_from_users): Likewise.
10332 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
10333 (vect_vect_recog_func_ptrs): Put over_widening first.
10335 (vect_pattern_recog): Call vect_determine_precisions.
10337 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
10339 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
10340 statements that have been replaced by further pattern statements.
10341 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
10343 2018-07-03 Richard Biener <rguenther@suse.de>
10345 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
10346 always set *dt. Dump vectype in vectype overload.
10347 * dumpfile.h (dump_gimple_expr): New function.
10348 (dump_gimple_expr_loc): Likewise.
10349 * dumpfile.c (dump_gimple_expr): New function.
10350 (dump_gimple_expr_loc): Likewise.
10352 2018-07-02 Jeff Law <law@redhat.com>
10354 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
10355 the H8/300, H8/300H and H8/S variants into a single pattern.
10356 (movhi_h8300, movqi_h8300hs): Similarly.
10357 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
10358 (QHI mode iterator): New.
10360 * config/h8300/h8300.md: Remove trailing whitespace.
10362 2018-07-02 Jim Wilson <jimw@sifive.com>
10364 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
10365 instead of emit_insn for interrupt returns.
10366 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
10367 (riscv_sret, riscv_uret): Likewise.
10369 2018-07-02 David Malcolm <dmalcolm@redhat.com>
10371 * pretty-print.c (selftest::test_pp_format): Move save and restore
10372 of quotes to class auto_fix_quotes, and add an instance.
10373 * selftest.c: Include "intl.h".
10374 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
10375 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
10376 * selftest.h (selftest::auto_fix_quotes): New class.
10378 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
10380 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
10381 (aarch64_sve_prepare_conditional_op): Remove.
10382 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
10383 Allow aarch64_simd_reg_or_zero as select operand; remove
10384 the aarch64_sve_prepare_conditional_op call.
10385 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
10386 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
10387 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
10388 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
10389 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
10390 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
10391 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
10392 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
10393 and a splitters to match all of the *_any patterns.
10394 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
10396 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
10397 (SVE_COND_FP_BINARY_REV): Remove.
10398 (sve_int_op_rev, sve_fp_op_rev): New.
10399 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
10400 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
10401 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
10402 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
10403 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
10404 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
10405 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
10406 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
10407 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
10409 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
10410 Remove match_dup 1 from the inner unspec.
10411 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
10413 * config/aarch64/aarch64.md (movprfx): New attr.
10414 (length): Default movprfx to 8.
10415 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
10416 (*madd<SVE_I>, *msub<SVE_I): Likewise.
10417 (*<su>mul<SVE_I>3_highpart): Likewise.
10418 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
10419 (*v<ASHIFT><SVE_I>3): Likewise.
10420 (*<su><MAXMIN><SVE_I>3): Likewise.
10421 (*<su><MAXMIN><SVE_F>3): Likewise.
10422 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
10423 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
10424 (*div<SVE_F>4): Likewise.
10426 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
10428 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
10431 2018-07-02 Richard Biener <rguenther@suse.de>
10433 PR tree-optimization/86363
10434 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
10435 memset argument refers to a non-variable address.
10437 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
10439 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
10440 {PLUS,MINUS}_EXPR code to...
10441 (adjust_symbolic_bound): ...here,
10442 (combine_bound): ...here,
10443 (set_value_range_with_overflow): ...and here.
10445 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
10447 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
10449 (extract_range_from_abs_expr): ...here.
10451 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
10453 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
10454 -fno-omit-frame-pointer when not optimizing.
10456 2018-07-02 Martin Liska <mliska@suse.cz>
10459 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
10460 (propagate_nothrow): Likewise.
10462 2018-07-02 Martin Liska <mliska@suse.cz>
10465 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
10467 2018-07-02 David Malcolm <dmalcolm@redhat.com>
10469 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
10470 function in r262149, changing "loc" param from source_location to
10471 const dump_location_t &.
10472 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
10473 declaration, as above.
10475 2018-07-01 Paul Koning <ni1d@arrl.net>
10477 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
10478 -munit-asm, -mgnu-asm, -mdec-asm.
10479 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
10480 (pdp11_output_labelref): New.
10481 (pdp11_output_def): New.
10482 (pdp11_output_addr_vec_elt): New.
10483 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
10484 %# and %@ format codes.
10485 (pdp11_option_override): New.
10486 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
10487 (pdp11_output_ident): New.
10488 (pdp11_asm_named_section): New.
10489 (pdp11_asm_init_sections): New.
10490 (pdp11_file_start): New.
10491 (pdp11_file_end): New.
10492 (output_ascii): Use .ascii/.asciz for -mdec-asm.
10493 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
10494 %o, like %c but octal.
10495 (pdp11_option_override): New.
10496 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
10498 (DATA_SECTION_ASM_OP): Ditto.
10499 (READONLY_DATA_SECTION_ASM_OP): New.
10500 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
10501 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
10502 (ASM_OUTPUT_LABELREF): Ditto.
10503 (ASM_OUTPUT_DEF): Ditto.
10504 (ASM_OUTPUT_EXTERNAL): New.
10505 (ASM_OUTPUT_SOURCE_FILENAME): New.
10506 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
10507 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
10508 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
10509 %# and %@ format codes.
10510 * config/pdp11/pdp11.opt (mgnu-asm): New.
10511 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
10512 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
10513 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
10515 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
10517 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
10518 dereferencing path[] beyond its length.
10520 (debug_all_paths): New.
10521 (rewire_first_differing_edge): New.
10522 (adjust_paths_after_duplication): New.
10523 (duplicate_thread_path): Call adjust_paths_after_duplication.
10525 (thread_through_all_blocks): Add new argument to
10526 duplicate_thread_path.
10528 2018-06-30 Jim Wilson <jimw@sifive.com>
10530 * config/riscv/predicates.md (p2m1_shift_operand): New.
10531 (high_mask_shift_operand): New.
10532 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
10533 pattern using p2m1_shift_operand.
10534 (lshsi3_zero_extend_3+2): New combiner pattern using
10535 high_mask_shift_operand.
10537 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10539 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
10541 (vect_recog_rotate_pattern): ...here.
10542 (vect_convert_input): Try to insert casts of invariants in the
10544 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
10545 preheader to be empty.
10547 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10549 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
10550 vector type. If given, install it in the new statement's
10551 STMT_VINFO_VECTYPE.
10552 (vect_element_precision): New function.
10553 (vect_unpromoted_value): New struct.
10554 (vect_unpromoted_value::vect_unpromoted_value): New function.
10555 (vect_unpromoted_value::set_op): Likewise.
10556 (vect_look_through_possible_promotion): Likewise.
10557 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
10558 (vect_widened_op_tree, vect_convert_input): Likewise.
10559 (vect_convert_inputs, vect_convert_output): Likewise.
10560 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
10561 to handle the optional cast of the multiplication result and
10562 vect_widened_op_tree to detect the widened multiplication itself.
10563 Do not require the input and output of promotion casts to have
10564 the same sign, but base the signedness of the operation on the
10565 input rather than the result. If the pattern includes two
10566 promotions, check that those promotions have the same sign.
10567 Do not restrict the MULT_EXPR handling to a double-width result;
10568 handle quadruple-width results and wider. Use vect_convert_inputs
10569 to convert the inputs to the common type.
10570 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
10571 to handle the optional cast of the ABS result. Also allow a sign
10572 change or a sign extension between the ABS and MINUS.
10573 Use vect_widened_op_tree to detect the widened subtraction and use
10574 vect_convert_inputs to convert the inputs to the common type.
10575 (vect_handle_widen_op_by_const): Delete.
10576 (vect_recog_widen_op_pattern): New function.
10577 (vect_recog_widen_mult_pattern): Use it.
10578 (vect_recog_widen_shift_pattern): Likewise.
10579 (vect_recog_widen_sum_pattern): Use
10580 vect_look_through_possible_promotion to handle the promoted
10583 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10585 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
10586 the containing gimple_seq *.
10587 * gimple-iterator.h (gsi_for_stmt): Declare it.
10588 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
10589 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
10590 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
10591 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
10592 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
10594 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
10596 (vect_mark_pattern_stmts): ...here. Handle cases in which the
10597 statement being replaced is part of an existing pattern
10598 definition sequence, inserting the new pattern statements before
10600 (vect_pattern_recog_1): Don't return a bool. If the statement
10601 is already part of a pattern, instead apply pattern matching
10602 to the pattern definition statements. Don't clear the
10603 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
10604 (vect_pattern_recog): Don't break after the first match;
10605 continue processing the pattern definition statements instead.
10606 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
10608 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10610 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
10611 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
10612 (vect_recog_widen_sum_pattern): Use it.
10614 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10616 * tree-vect-loop.c (vectorizable_reduction): Assert that the
10617 phi is not a pattern statement and has not been replaced by
10618 a pattern statement.
10619 * tree-vect-patterns.c (type_conversion_p): Don't check
10620 STMT_VINFO_IN_PATTERN_P.
10621 (vect_recog_vector_vector_shift_pattern): Likewise.
10622 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
10623 the pattern statement rather than the original statement; check
10624 directly for a WIDEN_MULT_EXPR here.
10625 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
10626 vect_is_simple_use to return the pattern statement rather
10627 than the original statement; use is_pattern_stmt_p to check
10628 for such a pattern statement.
10629 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
10630 to return the pattern statement rather than the original statement;
10631 don't do the same transformation here.
10632 (vect_is_simple_use): If the defining statement has been replaced
10633 by a pattern statement, return the pattern statement instead.
10634 Remove the corresponding (local) transformation from the vectype
10637 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
10639 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
10640 end and default to null.
10641 * tree-vect-loop.c (vect_create_epilog_for_reduction)
10642 (vectorizable_reduction): Update calls accordingly, dropping the
10643 gimple ** argument if the passed-back statement isn't needed.
10644 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
10645 (vect_recog_rotate_pattern): Likewise.
10646 (vect_recog_mask_conversion_pattern): Likewise.
10647 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
10648 (vect_mask_constant_operand_p): Likewise.
10649 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
10650 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
10651 (get_group_load_store_type, get_load_store_type): Likewise.
10652 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
10653 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
10654 (vectorizable_conversion, vectorizable_assignment): Likewise.
10655 (vectorizable_shift, vectorizable_operation): Likewise.
10656 (vectorizable_store, vect_is_simple_cond): Likewise.
10657 (vectorizable_condition, vectorizable_comparison): Likewise.
10658 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
10659 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
10660 and move it to the end. Cope with null def_stmt_outs.
10662 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
10664 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
10666 2018-06-29 Jeff Law <law@redhat.com>
10668 * config/v850/v850.c (v850_legitimate_address_p): Handle large
10669 displacements for TARGET_V850E2V3 and newer.
10670 (TARGET_LRA_P): Remove. Defaults to LRA now.
10671 * config/v850/v850.md (sign23byte_load): Remove.
10672 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
10673 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
10675 2018-06-29 Martin Liska <mliska@suse.cz>
10678 * coverage.c (coverage_init): Mangle full path name.
10679 * doc/invoke.texi: Document the change.
10680 * gcov-io.c (mangle_path): New.
10681 * gcov-io.h (mangle_path): Likewise.
10682 * gcov.c (mangle_name): Use mangle_path for path mangling.
10684 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10686 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
10687 if starting source register is not even.
10689 2018-06-29 Martin Liska <mliska@suse.cz>
10691 PR tree-optimization/86263
10692 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
10693 Make edge redirection.
10695 2018-06-29 David Malcolm <dmalcolm@redhat.com>
10697 * dumpfile.c (dump_loc): Add indentation based on scope depth.
10698 (dump_scope_depth): New variable.
10699 (get_dump_scope_depth): New function.
10700 (dump_begin_scope): New function.
10701 (dump_end_scope): New function.
10702 * dumpfile.h (get_dump_scope_depth): New declaration.
10703 (dump_begin_scope): New declaration.
10704 (dump_end_scope): New declaration.
10705 (class auto_dump_scope): New class.
10706 (AUTO_DUMP_SCOPE): New macro.
10707 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
10710 2018-06-29 Richard Biener <rguenther@suse.de>
10712 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
10713 compute_all_dependences succeeds.
10714 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
10715 exceed --param loop-max-datarefs-for-datadeps.
10717 2018-06-29 Jakub Jelinek <jakub@redhat.com>
10719 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
10721 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
10724 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
10725 alternative 0 in preferred_for_speed attribute.
10727 2018-06-28 Paul Koning <ni1d@arrl.net>
10729 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
10730 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
10731 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
10732 * config/pdp11/pdp11.md: Correct "length" attribute calculation
10733 for shift insn patterns.
10735 2018-06-28 David Malcolm <dmalcolm@redhat.com>
10737 * cgraph.c (cgraph_node::get_body): Replace assignments to
10738 "dump_file" with calls to set_dump_file.
10739 * dumpfile.c (alt_dump_file): Make static, and group with...
10740 (alt_flags): ...this definition.
10741 (dumps_are_enabled): New variable.
10742 (refresh_dumps_are_enabled): New function.
10743 (set_dump_file): New function.
10744 (set_alt_dump_file): New function.
10745 (gcc::dump_manager::dump_start): Replace assignments to
10746 "dump_file" and "alt_dump_file" with calls to set_dump_file and
10748 (gcc::dump_manager::dump_finish): Likewise.
10749 * dumpfile.h (alt_dump_file): Delete decl.
10750 (dumps_are_enabled): New variable decl.
10751 (set_dump_file): New function decl.
10752 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
10754 * tree-nested.c (lower_nested_functions): Replace assignments to
10755 "dump_file" with calls to set_dump_file.
10757 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
10759 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
10760 goto_locus of each outgoing edge of each basic block.
10762 2018-06-28 Richard Biener <rguenther@suse.de>
10764 * dwarf2out.c (decl_scope_table): Remove.
10765 (push_decl_scope): Likewise.
10766 (pop_decl_scope): Likewise.
10767 (gen_type_die_for_member): Do not call push/pop_decl_scope.
10768 (gen_struct_or_union_type_die): Likewise.
10769 (gen_tagged_type_die): Likewise.
10770 (dwarf2out_init): Do not initialize decl_scope_table.
10771 (dwarf2out_c_finalize): Do not free it.
10773 2018-06-28 Richard Biener <rguenther@suse.de>
10775 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
10776 deciding whether to not re-use a DIE.
10778 2018-06-28 Richard Biener <rguenther@suse.de>
10780 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
10781 DW_AT_abstract_origin attribute.
10783 2018-06-28 Martin Liska <mliska@suse.cz>
10785 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
10786 Use newly introduced constants.
10787 * tree-switch-conversion.h (struct jump_table_cluster):
10788 Define max_ratio_for_size and max_ratio_for_speed.
10790 2018-06-28 Martin Liska <mliska@suse.cz>
10792 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
10793 Add new checking assert to catch invalid state.
10794 (jump_table_cluster::can_be_handled): Handle single case
10796 (jump_table_cluster::is_beneficial): Bail out for such case.
10797 (bit_test_cluster::find_bit_tests):
10798 Add new checking assert to catch invalid state.
10799 (bit_test_cluster::can_be_handled): Handle single case
10801 (bit_test_cluster::is_beneficial): Bail out for such case.
10802 (switch_decision_tree::analyze_switch_statement):
10805 2018-06-28 Martin Liska <mliska@suse.cz>
10807 * common.opt: Introduce -completion option.
10808 * gcc.c (driver_handle_option): Handle it.
10809 (driver::main): Print completions if completion
10811 * opt-suggestions.c (option_proposer::get_completions):
10813 (option_proposer::suggest_completion): Likewise.
10814 (option_proposer::find_param_completions): Likewise.
10815 (verify_autocompletions): Likewise.
10816 (test_completion_valid_options): Likewise.
10817 (test_completion_valid_params): Likewise.
10818 (in_completion_p): Likewise.
10819 (empty_completion_p): Likewise.
10820 (test_completion_partial_match): Likewise.
10821 (test_completion_garbage): Likewise.
10822 (opt_proposer_c_tests): Likewise.
10823 * opt-suggestions.h: Declare new functions.
10824 * opts.c (common_handle_option): Handle OPT__completion_.
10825 * selftest-run-tests.c (selftest::run_tests): Add
10826 opt_proposer_c_tests.
10827 * selftest.c (assert_str_startswith): New.
10828 * selftest.h (assert_str_startswith): Likewise.
10829 (opt_proposer_c_tests): New.
10830 (ASSERT_STR_STARTSWITH): Likewise.
10832 2018-06-28 Martin Liska <mliska@suse.cz>
10834 * Makefile.in: Add opt-suggestions.o.
10835 * gcc-main.c: Include opt-suggestions.h.
10836 * gcc.c (driver::driver): Likewise.
10837 (driver::~driver): Remove m_option_suggestions.
10838 (driver::build_option_suggestions): Moved to option_proposer.
10839 (driver::suggest_option): Likewise.
10840 (driver::handle_unrecognized_options): Use option_proposer.
10841 * gcc.h (class driver): Add new memver m_option_proposer.
10842 * opt-suggestions.c: New file.
10843 * opt-suggestions.h: New file.
10845 2018-06-28 Martin Liska <mliska@suse.cz>
10847 * vec.h (class auto_string_vec): New (moved from auto_argvec).
10848 (auto_string_vec::~auto_string_vec): Likewise.
10850 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
10852 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
10853 prevent_decl_creation_for_types fields up and add reset_location field.
10854 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
10855 statement if id->reset_location is true.
10856 (copy_edges_for_bb): Do not set goto_locus on the new edges if
10857 id->reset_location is true.
10858 (copy_phis_for_bb): Force input_location on the arguments if
10859 id->reset_location is true.
10860 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
10861 is set on the function to be inlined.
10863 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
10865 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
10867 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
10869 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
10870 registers for Pmode.
10871 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
10872 hard registers for the clobbered pseudo.
10874 2018-06-27 Paul Koning <ni1d@arrl.net>
10876 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
10877 mutually exclusive options.
10878 * config/pdp11/constraints.md (h): New constraint.
10879 (O): Update definition to match shift code generation.
10880 (D): New constraint.
10881 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
10883 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
10885 (output_jump): Change arguments.
10886 (pdp11_fixed_cc_regs): New function.
10887 (pdp11_cc_mode): Ditto.
10888 (pdp11_expand_shift): Ditto.
10889 (pdp11_assemble_shift): Ditto.
10890 (pdp11_small_shift): Ditto.
10891 (pdp11_branch_cost): Remove.
10892 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
10894 (pdp11_register_move_cost): Update for CC registers.
10895 (pdp11_rtx_costs): Add case for LSHIFTRT.
10896 (pdp11_output_jump): Add CCNZ mode conditional branches.
10897 (notice_update_cc_on_set): Remove.
10898 (pdp11_cc_mode): New function.
10899 (simple_memory_operand): Correct pre/post decrement case.
10900 (no_side_effect_operand): New function.
10901 (pdp11_regno_reg_class): Add CC_REGS class.
10902 (pdp11_fixed_cc_regs): New function.
10903 (pdp11_small_shift): New function.
10904 (pdp11_expand_shift): New function to expand shift insns.
10905 (pdp11_assemble_shift): New function to output shifts.
10906 (pdp11_branch_cost): Remove.
10907 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
10908 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
10909 (WCHAR_TYPE): Ditto.
10910 (PTRDIFF_TYPE): Ditto.
10911 (ADJUST_INSN_LENGTH): New macro.
10912 (FIXED_REGISTERS): Add CC registers.
10913 (CALL_USED_REGISTERS): Ditto.
10914 (reg_class): Ditto.
10915 (REG_CLASS_NAMES): Ditto.
10916 (REG_CLASS_CONTENTS): Ditto.
10917 (SELECT_CC_MODE): Use new function.
10918 (TARGET_FLAGS_REGNUM): New macro.
10919 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
10920 (cc0_reg_rtx): Remove.
10921 (CC_STATUS_MDEP): Remove.
10922 (CC_STATUS_MDEFP_INIT): Remove.
10923 (CC_IN_FPU): Remove.
10924 (NOTICE_UPDATE_CC): Remove.
10925 (REGISTER_NAMES): Add CC registers.
10926 (BRANCH_COST): Change to constant 1.
10927 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
10929 * config/pdp11/pdp11.opt (mbcopy): Remove.
10930 (mbcopy-builtin): Remove.
10931 (mbranch-cheap): Remove.
10932 (mbranch-expensive): Remove.
10933 * config/pdp11/predicates.md (expand_shift_operand): Update to
10934 match shift code generation.
10935 (ccnz_operator): New predicate.
10936 * doc/invoke.texi (PDP-11 Options): Remove deleted options
10937 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
10938 Remove non-existent option -mabshi, -mno-abshi. Document mutually
10940 * doc/md.texi (PDP-11): Document new D and h constraints. Update
10941 description of O constraint.
10943 2018-06-27 Jeff Law <law@redhat.com>
10944 Austin Law <austinklaw@gmail.com>
10946 * config/v850/v850.md (addsi3_set_flags): New pattern.
10947 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
10948 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
10949 (zero_extendhisi2_v850_set_flags): Likewise.
10950 (zero_extendqisi2_v850_set_flags): Likewise.
10951 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
10952 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
10953 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
10955 * config/v850/v850-protos.h (notice_update_cc): Remove.
10956 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
10957 (v850_print_operand): Handle 'D' and "d".
10958 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
10959 Add handling of arithmetic/logical operations compared against zero.
10960 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
10961 Do not look at v850_compare_op, instead get mode from last argument.
10962 (v850_gen_compare): Remove
10963 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
10964 after reload for prologue insns.
10965 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
10967 (construct_save_jarl): Likewise.
10968 (TARGET_FLAGS_REGNUM): Define.
10969 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
10970 (NOTICE_UPDATE_CC): Remove.
10971 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
10972 than cc0. Conditionalize on reload_completed.
10973 (cmpsi_insn, setfcc_insn): Likewise.
10974 (tst1 splitter): Turn into define_and_split which sets the flags
10976 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
10977 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
10978 (cstoresf4, cstoredf4): Clobber the flags.
10979 (cmpsi, cmpsf, cmpdf): Remove expanders.
10980 (setf_insn): Remove pattern.
10981 (addsi3): Turn into define_and_split which clobbers the flags after
10982 reload and a suitable pattern (addsi3_clobber_flags) for use after
10984 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
10985 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
10986 (ashrsi3, ashrsi3_v850e2): Likewise.
10987 (bins): Clobber the flags.
10988 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
10989 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
10990 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
10991 (call_value_internal_short, call_value_internal_long): Likewise.
10992 (callt_save_interrupt, callt_return_interrupt): Likewise.
10993 (save_interrupt, return_interrupt): Likewise.
10994 (callt_save_all_interrupt, save_all_interrupt): Likewise.
10995 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
10996 (restore_all_interrupt, _restore_all_interrupt): Likewise.
10997 (All FP comparisons): Only allow after reload has completed.
10999 (divh, divhu): Tweak output template.
11000 (branch_z_normal, branch_z_invert): Remove
11001 (branch_nz_normal, branch_nz_invert): Likewise.
11002 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
11004 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
11005 * config/v850/v850.c (notice_update_cc): Remove.
11006 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
11007 (CC_NO_CARRY): Likewise.
11008 (NOTICE_UPDATE_CC): Define to nothing.
11009 * config/v850/v850.md: Remove block comment on cc0 handling
11010 Remove "cc" attribute from all patterns. Remove cc_status handling
11011 from all patterns. Minor formatting fixes.
11013 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11015 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
11016 (cortex-a76.cortex-a55): Likewise.
11017 * config/aarch64/aarch64-tune.md: Regenerate.
11018 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
11019 cortex-a76.cortex-a55.
11021 2018-06-27 Jeff Law <law@redhat.com>
11023 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
11024 (MULTILIB_DIRNAMES): Similarly.
11026 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
11028 * gimple.h (gimple_return_retbnd): Delete.
11029 (gimple_return_set_retbnd): Likewise.
11030 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
11031 gimple_return_set_retbnd.
11032 * gimple-pretty-print.c (dump_gimple_return): Remove call to
11033 gimple_return_retbnd and adjust.
11034 * tree-inline.h (struct copy_body_data): Remove retbnd field.
11035 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
11036 Explicitly return NULL in a couple more cases. Move assertion
11037 on debug statements and remove unreachable code.
11038 (reset_debug_binding): Do not test id->retbnd.
11039 (expand_call_inline): Do not set it.
11041 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
11043 * configure.ac: Add --disable-gcov option.
11044 * configure: Regenerate.
11045 * Makefile.in: Honour @enable_gcov@.
11046 * doc/install.texi: Document --disable-gcov.
11048 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11050 * config/arm/arm-cpus.in (cortex-a76): New entry.
11051 (cortex-a76.cortex-a55): Likewise.
11052 * config/arm/arm-tables.opt: Regenerate.
11053 * config/arm/arm-tune.md: Likewise.
11054 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
11055 * doc/invoke.texi (ARM Options): Document cortex-a76 and
11056 cortex-a76.cortex-a55.
11058 2018-06-27 Tamar Christina <tamar.christina@arm.com>
11061 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
11063 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
11065 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
11067 (EPILOGUE_USES): Likewise.
11069 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
11071 * tree-inline.c (remap_location): New function extracted from...
11072 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
11073 (copy_phis_for_bb): ...here. Call remap_location.
11074 (copy_cfg_body): Adjust call to copy_edges_for_bb.
11076 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
11078 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
11079 unaligned vsx for 16B memset.
11081 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
11084 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
11085 ieee128_float_type_node to long_double_type_node unless
11086 TARGET_LONG_DOUBLE_128 is set.
11088 2018-06-26 David Malcolm <dmalcolm@redhat.com>
11090 * cfgloop.c (get_loop_location): Convert return type from
11091 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
11092 by implicit construction from rtx_insn *, and using
11093 dump_user_location_t::from_function_decl for the fallback case.
11094 * cfgloop.h (get_loop_location): Convert return type from
11095 location_t to dump_user_location_t.
11096 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
11097 dump_printf_loc to pass in a dump_location_t rather than a
11098 location_t, via the gimple stmt.
11099 * coverage.c (get_coverage_counts): Update calls to
11100 dump_printf_loc to pass in dump_location_t rather than a
11102 * doc/optinfo.texi (Dump types): Convert example of
11103 dump_printf_loc from taking "locus" to taking "insn". Update
11104 description of the "_loc" calls to cover dump_location_t.
11105 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
11107 (dump_user_location_t::dump_user_location_t): New constructors,
11108 from gimple *stmt and rtx_insn *.
11109 (dump_user_location_t::from_function_decl): New function.
11110 (dump_loc): Make static.
11111 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
11112 const dump_location_t &.
11113 (dump_generic_expr_loc): Delete.
11114 (dump_printf_loc): Convert param "loc" from location_t to
11115 const dump_location_t &.
11116 (selftest::test_impl_location): New function.
11117 (selftest::dumpfile_c_tests): New function.
11118 * dumpfile.h: Include "profile-count.h".
11119 (class dump_user_location_t): New class.
11120 (struct dump_impl_location_t): New struct.
11121 (class dump_location_t): New class.
11122 (dump_printf_loc): Convert 2nd param from source_location to
11123 const dump_location_t &.
11124 (dump_generic_expr_loc): Delete.
11125 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
11126 const dump_location_t &.
11127 * gimple-fold.c (fold_gimple_assign): Update call to
11128 dump_printf_loc to pass in a dump_location_t rather than a
11129 location_t, via the gimple stmt.
11130 (gimple_fold_call): Likewise.
11131 * gimple-loop-interchange.cc
11132 (loop_cand::analyze_iloop_reduction_var): Update for change to
11133 check_reduction_path.
11134 (tree_loop_interchange::interchange): Update for change to
11135 find_loop_location.
11136 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
11137 change in return-type of find_loop_location.
11138 (graphite_regenerate_ast_isl): Likewise.
11139 * graphite-optimize-isl.c (optimize_isl): Likewise.
11140 * graphite.c (graphite_transform_loops): Likewise.
11141 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
11142 pass in a dump_location_t rather than a location_t, via the
11144 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
11145 * ipa.c (walk_polymorphic_call_targets): Likewise.
11146 * loop-unroll.c (report_unroll): Convert "locus" param from
11147 location_t to dump_location_t.
11148 (decide_unrolling): Update for change to get_loop_location's
11150 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
11151 location_t to dump_user_location_t.
11152 (grid_find_single_omp_among_assignments_1): Updates calls to
11153 dump_printf_loc to pass in a dump_location_t rather than a
11154 location_t, via the gimple stmt.
11155 (grid_parallel_clauses_gridifiable): Convert "tloc" from
11156 location_t to dump_location_t. Updates calls to dump_printf_loc
11157 to pass in a dump_location_t rather than a location_t, via the
11159 (grid_inner_loop_gridifiable_p): Likewise.
11160 (grid_dist_follows_simple_pattern): Likewise.
11161 (grid_gfor_follows_tiling_pattern): Likewise.
11162 (grid_target_follows_gridifiable_pattern): Likewise.
11163 (grid_attempt_target_gridification): Convert initialization
11164 of local "grid" from memset to zero-initialization; FIXME: does
11165 this require C++11? Update call to dump_printf_loc to pass in a
11166 optinfo_location rather than a location_t, via the gimple stmt.
11167 * profile.c (read_profile_edge_counts): Updates call to
11168 dump_printf_loc to pass in a dump_location_t rather than a
11170 (compute_branch_probabilities): Likewise.
11171 * selftest-run-tests.c (selftest::run_tests): Call
11173 * selftest.h (dumpfile_c_tests): New decl.
11174 * tree-loop-distribution.c (pass_loop_distribution::execute):
11175 Update for change in return type of find_loop_location.
11176 * tree-parloops.c (parallelize_loops): Likewise.
11177 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
11178 "locus" from location_t to dump_user_location_t.
11179 (canonicalize_loop_induction_variables): Likewise.
11180 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
11181 for change in return type of find_loop_location.
11182 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
11183 to dump_printf_loc to pass in a dump_location_t rather than a
11184 location_t, via the stmt.
11185 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
11187 * tree-vect-loop-manip.c (find_loop_location): Convert return
11188 type from source_location to dump_user_location_t.
11189 (vect_do_peeling): Update for above change.
11190 (vect_loop_versioning): Update for change in type of
11192 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
11193 from location_t to dump_user_location_t.
11194 (vect_estimate_min_profitable_iters): Update for change in type
11196 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
11197 location_t to dump_location_t.
11198 (vect_slp_bb): Update for change in type of vect_location.
11199 * tree-vectorizer.c (vect_location): Convert from source_location
11200 to dump_user_location_t.
11201 (try_vectorize_loop_1): Update for change in vect_location's type.
11202 (vectorize_loops): Likewise.
11203 (increase_alignment): Likewise.
11204 * tree-vectorizer.h (vect_location): Convert from source_location
11205 to dump_user_location_t.
11206 (find_loop_location): Convert return type from source_location to
11207 dump_user_location_t.
11208 (check_reduction_path): Convert 1st param from location_t to
11209 dump_user_location_t.
11210 * value-prof.c (check_counter): Update call to dump_printf_loc to
11211 pass in a dump_user_location_t rather than a location_t; update
11212 call to error_at for change in type of "locus".
11213 (check_ic_target): Update call to dump_printf_loc to
11214 pass in a dump_user_location_t rather than a location_t, via the
11217 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
11219 * config/s390/s390.h (enum processor_flags): Do not use
11220 default tune parameter when -march was specified.
11222 2018-06-26 Jakub Jelinek <jakub@redhat.com>
11225 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
11226 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
11229 2018-06-26 Richard Biener <rguenther@suse.de>
11231 PR tree-optimization/86287
11233 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
11234 (vect_analyze_loop): Initialize n_stmts.
11236 2018-06-26 Richard Biener <rguenther@suse.de>
11238 PR middle-end/86271
11239 * fold-const.c (fold_convertible_p): Pointer extension
11242 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
11245 * dwarf2out.c (loc_list_has_views): Adjust comments.
11246 (dw_loc_list): Split single cross-partition range with
11249 2018-06-25 Jeff Law <law@redhat.com>
11251 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
11252 on -mbig-switch by default.
11254 * config/v850/predicates.md (const_float_1_operand): Fix match_code
11256 (const_float_0_operand): Remove unused predicate.
11257 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
11258 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
11259 (recipsf2): New expander. Original pattern now called
11261 (recipdf2, recipdf2_insn): Similarly.
11262 (rsqrtsf2, rsqrtsf2_insn): Similarly
11263 (rsqrtdf2, rsqrtdf2_insn): Similarly
11265 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
11267 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
11268 Simplify logic for FreeBSD (twice).
11270 2018-06-25 Martin Sebor <msebor@redhat.com>
11272 PR tree-optimization/86204
11273 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
11274 a strnlen result if it's less than the length of the string.
11276 2018-06-25 Martin Sebor <msebor@redhat.com>
11278 PR tree-optimization/85700
11279 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
11280 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
11281 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
11283 2018-06-25 Martin Sebor <msebor@redhat.com>
11285 * doc/extend.texi (Zero-length arrays): Update and clarify.
11287 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
11289 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
11290 added IEEE/IBM long double multilib support on PowerPC little
11291 endian Linux systems.
11292 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
11293 (MULTILIB_DEFAULTS): Likewise.
11294 * config/rs6000/rs6000.c (rs6000_option_override_internal):
11296 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
11297 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
11298 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
11300 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
11302 PR middle-end/86311
11303 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
11304 (REORDER_45): Likewise.
11306 2018-06-25 Jeff Law <law@redhat.com>
11308 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
11309 dividend to 32 bits. Adjust length.
11310 (udivmodhi4): Cleanup output template. Fix length.
11312 2018-06-25 Carl Love <cel@us.ibm.com>
11314 * config/rs6000/vsx.md: Change word selector to prefered location.
11316 2018-06-25 Richard Biener <rguenther@suse.de>
11318 PR tree-optimization/86304
11319 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
11320 epilogue-if-converted loops as well.
11322 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
11324 * lto-section-out.c (lto_begin_section): Do not print section
11325 name for noaddr and unnumbered dumps.
11327 2018-06-25 Richard Biener <rguenther@suse.de>
11329 * tree-vectorizer.h (struct vec_info_shared): New structure
11330 with parts split out from struct vec_info and loop_nest from
11331 struct _loop_vec_info.
11332 (struct vec_info): Adjust accordingly.
11333 (struct _loop_vec_info): Likewise.
11334 (LOOP_VINFO_LOOP_NEST): Adjust.
11335 (LOOP_VINFO_DATAREFS): Likewise.
11336 (LOOP_VINFO_DDRS): Likewise.
11337 (struct _bb_vec_info): Likewise.
11338 (BB_VINFO_DATAREFS): Likewise.
11339 (BB_VINFO_DDRS): Likewise.
11340 (struct _stmt_vec_info): Add dr_aux member.
11341 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
11342 (DR_MISALIGNMENT_UNINITIALIZED): New.
11343 (set_dr_misalignment): Adjust.
11344 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
11345 (vect_analyze_loop): Adjust prototype.
11346 (vect_analyze_loop_form): Likewise.
11347 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
11348 Compute dependences lazily.
11349 (vect_record_base_alignments): Use shared datarefs/ddrs.
11350 (vect_verify_datarefs_alignment): Likewise.
11351 (vect_analyze_data_refs_alignment): Likewise.
11352 (vect_analyze_data_ref_accesses): Likewise.
11353 (vect_analyze_data_refs): Likewise.
11354 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
11355 constructor parameter for shared part.
11356 (vect_analyze_loop_form): Pass in shared part and adjust.
11357 (vect_analyze_loop_2): Pass in storage for the number of
11358 stmts. Move loop nest finding to the caller. Compute
11360 (vect_analyze_loop): Pass in shared part.
11361 (vect_transform_loop): Verify shared datarefs are unchanged.
11362 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
11363 constructor parameter for shared part.
11364 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
11365 (vect_slp_bb): Verify shared datarefs are unchanged before
11367 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
11369 (new_stmt_vec_info): Initialize DR_AUX misalignment to
11370 DR_MISALIGNMENT_UNINITIALIZED.
11371 * tree-vectorizer.c (vec_info::vec_info): Add constructor
11372 parameter for shared part.
11373 (vec_info::~vec_info): Adjust.
11374 (vec_info_shared::vec_info_shared): New.
11375 (vec_info_shared::~vec_info_shared): Likewise.
11376 (vec_info_shared::save_datarefs): Likewise.
11377 (vec_info_shared::check_datarefs): Likewise.
11378 (try_vectorize_loop_1): Construct shared part live for analyses
11379 of a single loop for multiple vector sizes.
11380 * tree-parloops.c (gather_scalar_reductions): Adjust.
11382 2018-06-25 Richard Biener <rguenther@suse.de>
11384 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
11385 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
11386 (vect_analyze_data_refs): Remove similar code from here and
11387 simplify accordingly.
11389 2018-06-25 Richard Biener <rguenther@suse.de>
11391 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
11392 for reverse storage order accesses rather than asserting
11393 they cannot happen here.
11395 2018-06-25 Tom de Vries <tdevries@suse.de>
11398 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
11399 Use data16 instead of .byte for insn prefix.
11401 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
11404 * parser.c (make_char_string_pack): Pass this literal chars
11405 through cpp_interpret_string.
11406 (cp_parser_userdef_numeric_literal): Check the result of
11407 make_char_string_pack.
11409 2018-06-24 Maya Rashish <coypu@sdf.org>
11411 * ginclude/stddef.h: Simplify conditions around avoiding
11412 re-definition of __size_t.
11414 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
11416 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
11417 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
11419 2018-06-22 Maya Rashish <coypu@sdf.org>
11421 * doc/invoke.texi (mno-fancy-math-387): Update for changes
11422 made to OpenBSD and NetBSD through the years.
11424 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
11426 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
11427 behavior of vec_pack (vector double, vector double) to match
11428 behavior of vec_float2 (vector double, vector double).
11430 2018-06-22 Olivier Hainque <hainque@adacore.com>
11432 * gimplify.c (gimplify_function_tree): Prevent creation
11433 of a trampoline for the address of the current function
11434 passed to entry/exit instrumentation hooks.
11436 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
11439 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
11442 2018-06-22 Martin Liska <mliska@suse.cz>
11444 PR tree-optimization/86263
11445 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
11446 Bail out if is_enabled is false.
11447 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
11449 (jump_table_cluster::is_enabled): New function.
11451 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
11453 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
11454 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
11455 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
11456 (lto_input_ts_binfo_tree_pointers): Likewise.
11457 * tree-streamer-out.c (streamer_write_tree_bitfields,
11458 write_ts_binfo_tree_pointers): Likewise.
11459 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
11461 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
11463 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
11465 2018-06-22 Martin Liska <mliska@suse.cz>
11467 * symbol-summary.h (get): Make it pure and inline move
11468 functionality from ::get function.
11469 (get): Remove and inline into ::get and ::get_create.
11470 (get_create): Move code from ::get function.
11472 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11475 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
11476 -x assembler-with-cpp.
11478 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11480 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
11481 _FILE_OFFSET_BITS=64 for C++.
11483 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
11485 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
11486 conversion insn that shows up when pr85657-3.c is compiled using
11487 IEEE 128-bit long double.
11488 (neg<mode>2_internal): Use the correct mode to check whether the
11489 mode is IBM extended.
11490 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
11491 multiply and divide external functions from being created more
11494 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
11496 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
11498 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
11499 the edge can be forwarded.
11500 (cfg_layout_merge_blocks): Likewise.
11502 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
11504 * except.c (finish_eh_generation): Commit edge insertions only after
11505 the EH edges have been redirected from post-landing to landing pads.
11507 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
11509 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
11510 create_tmp_var_for to create the FRAME decl.
11511 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
11513 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
11515 * tree-inline.c (copy_edges_for_bb): Minor tweak.
11516 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
11517 debug statement when resetting its value.
11518 (expand_call_inline): Copy the locus of the call onto the assignment
11519 of the return value, if any. Use local variable in more cases.
11521 2018-06-21 Martin Liska <mliska@suse.cz>
11523 * ipa-pure-const.c (propagate_nothrow): Use
11524 funct_state_summaries->get.
11525 (dump_malloc_lattice): Likewise.
11526 (propagate_malloc): Likewise.
11528 2018-06-21 Richard Biener <rguenther@suse.de>
11530 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
11531 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
11532 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
11534 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
11535 BLOCK_ABSTRACT_ORIGIN unconditionally.
11537 2018-06-21 David Malcolm <dmalcolm@redhat.com>
11539 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
11541 * ipa-reference.c (ipa_reference_c_finalize): Delete
11542 ipa_ref_opt_sum_summaries and set it to NULL.
11544 2018-06-21 Tom de Vries <tdevries@suse.de>
11546 PR tree-optimization/85859
11547 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
11548 test with comment from bb_no_side_effects_p.
11550 2018-06-21 Richard Biener <rguenther@suse.de>
11552 PR tree-optimization/86232
11553 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
11554 max for constant niter.
11556 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
11558 * config/aarch64/aarch64-simd.md
11559 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
11561 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
11563 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
11564 Make opernads of the unspec commutative.
11566 2018-06-21 Richard Biener <rguenther@suse.de>
11568 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
11569 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
11570 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
11571 (vect_analyze_data_ref_dependence): Re-order checks to deal with
11573 (vect_record_base_alignments): Do not record base alignment
11574 for gathers or scatters.
11575 (vect_compute_data_ref_alignment): Drop return value that is always
11576 true. Bail out early for gathers or scatters.
11577 (vect_enhance_data_refs_alignment): Bail out early for gathers
11579 (vect_find_same_alignment_drs): Likewise.
11580 (vect_analyze_data_refs_alignment): Remove dead code.
11581 (vect_slp_analyze_and_verify_node_alignment): Likewise.
11582 (vect_analyze_data_refs): For possible gathers or scatters do
11583 not create an alternate DR, just check their possible validity
11584 and mark them. Adjust DECL_NONALIASED handling to not rely
11585 on DR_BASE_ADDRESS.
11586 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
11587 update inits of gathers or scatters.
11588 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
11589 Also copy gather/scatter flag to pattern vinfo.
11591 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
11593 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
11594 behavior of vec_packsu (vector unsigned long long, vector unsigned
11595 long long) to match behavior of vec_packs with same signature.
11597 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
11598 Thomas Schwinge <thomas@codesourcery.com>
11599 Cesar Philippidis <cesar@codesourcery.com>
11601 * gimplify.c (gimplify_scan_omp_clauses): Add support for
11602 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
11603 (gimplify_adjust_omp_clauses): Likewise.
11604 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
11605 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
11606 (gimplify_omp_target_update): Update handling of acc update and
11608 * omp-low.c (install_var_field): Remove unused parameter
11609 base_pointers_restrict.
11610 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
11611 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
11613 (omp_target_base_pointers_restrict_p): Delete.
11614 (scan_omp_target): Update call to scan_sharing_clauses.
11615 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
11617 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
11618 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
11619 (convert_local_omp_clauses): Likewise.
11620 * tree-pretty-print.c (dump_omp_clause): Likewise.
11621 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
11623 (omp_clause_code_name): Likewise.
11625 2018-06-20 Jakub Jelinek <jakub@redhat.com>
11628 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
11631 PR tree-optimization/86231
11632 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
11633 anti-range don't overwrite *vr0min before using it to compute *vr0max.
11635 2018-06-20 Tom de Vries <tdevries@suse.de>
11637 PR tree-optimization/86097
11638 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
11639 iv type if signedness of iv type is not the same as that of *nit.
11641 2018-06-20 Jakub Jelinek <jakub@redhat.com>
11643 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
11644 EDGE_EH edges, verify they are all EDGE_EH.
11646 2018-06-20 Maya Rashish <coypu@sdf.org>
11648 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
11650 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11652 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
11653 * config/aarch64/aarch64.c (xgene1_tunings): Add
11654 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
11655 (aarch64_mode_valid_for_sched_fusion_p):
11656 Allow 16-byte modes.
11657 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
11658 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
11660 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
11662 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
11663 * config/aarch64/iterators.md (VQ2): New mode iterator.
11665 2018-06-20 Martin Liska <mliska@suse.cz>
11667 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
11668 Change default ratio from 10 to 8.
11670 2018-06-20 Martin Liska <mliska@suse.cz>
11672 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
11674 (bit_test_cluster::find_bit_tests): Likewise.
11675 (switch_decision_tree::analyze_switch_statement): Find clusters.
11676 * tree-switch-conversion.h (struct jump_table_cluster): Document
11679 2018-06-20 Martin Liska <mliska@suse.cz>
11681 * tree-switch-conversion.c (switch_conversion::collect):
11682 Record m_uniq property.
11683 (switch_conversion::expand): Bail out for special conditions.
11684 (group_cluster::~group_cluster): New.
11685 (group_cluster::group_cluster): Likewise.
11686 (group_cluster::dump): Likewise.
11687 (jump_table_cluster::emit): New.
11688 (switch_decision_tree::fix_phi_operands_for_edges): New.
11689 (struct case_node): Remove struct.
11690 (jump_table_cluster::can_be_handled): New.
11691 (case_values_threshold): Moved to header.
11692 (reset_out_edges_aux): Likewise.
11693 (jump_table_cluster::is_beneficial): New.
11694 (bit_test_cluster::can_be_handled): Likewise.
11695 (add_case_node): Remove.
11696 (bit_test_cluster::is_beneficial): New.
11697 (case_bit_test::cmp): New.
11698 (bit_test_cluster::emit): New.
11699 (expand_switch_as_decision_tree_p): Remove.
11700 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
11701 (fix_phi_operands_for_edge): Likewise.
11702 (switch_decision_tree::analyze_switch_statement): New.
11703 (compute_cases_per_edge): Move ...
11704 (switch_decision_tree::compute_cases_per_edge): ... here.
11705 (try_switch_expansion): Likewise.
11706 (switch_decision_tree::try_switch_expansion): Likewise.
11707 (record_phi_operand_mapping): Likewise.
11708 (switch_decision_tree::record_phi_operand_mapping): Likewise.
11709 (emit_case_decision_tree): Likewise.
11710 (switch_decision_tree::emit): Likewise.
11711 (balance_case_nodes): Likewise.
11712 (switch_decision_tree::balance_case_nodes): Likewise.
11713 (dump_case_nodes): Likewise.
11714 (switch_decision_tree::dump_case_nodes): Likewise.
11715 (emit_jump): Likewise.
11716 (switch_decision_tree::emit_jump): Likewise.
11717 (emit_cmp_and_jump_insns): Likewise.
11718 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
11719 (emit_case_nodes): Likewise.
11720 (switch_decision_tree::emit_case_nodes): Likewise.
11721 (conditional_probability): Remove.
11722 * tree-switch-conversion.h (enum cluster_type): New.
11724 (struct cluster): Likewise.
11725 (cluster::cluster): Likewise.
11726 (struct simple_cluster): Likewise.
11727 (simple_cluster::simple_cluster): Likewise.
11728 (struct group_cluster): Likewise.
11729 (struct jump_table_cluster): Likewise.
11730 (struct bit_test_cluster): Likewise.
11731 (struct min_cluster_item): Likewise.
11732 (struct case_tree_node): Likewise.
11733 (case_tree_node::case_tree_node): Likewise.
11734 (jump_table_cluster::case_values_threshold): Likewise.
11735 (struct case_bit_test): Likewise.
11736 (struct switch_decision_tree): Likewise.
11737 (struct switch_conversion): Likewise.
11738 (switch_decision_tree::reset_out_edges_aux): Likewise.
11740 2018-06-20 Martin Liska <mliska@suse.cz>
11742 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
11743 (hoist_edge_and_branch_if_true): Likewise.
11744 (expand_switch_using_bit_tests_p): Likewise.
11745 (struct case_bit_test): Likewise.
11746 (case_bit_test_cmp): Likewise.
11747 (emit_case_bit_tests): Likewise.
11748 (switch_conversion::switch_conversion): New class.
11749 (struct switch_conv_info): Remove old struct.
11750 (collect_switch_conv_info): More to ...
11751 (switch_conversion::collect): ... this.
11752 (check_range): Likewise.
11753 (switch_conversion::check_range): Likewise.
11754 (check_all_empty_except_final): Likewise.
11755 (switch_conversion::check_all_empty_except_final): Likewise.
11756 (check_final_bb): Likewise.
11757 (switch_conversion::check_final_bb): Likewise.
11758 (create_temp_arrays): Likewise.
11759 (switch_conversion::create_temp_arrays): Likewise.
11760 (free_temp_arrays): Likewise.
11761 (gather_default_values): Likewise.
11762 (switch_conversion::gather_default_values): Likewise.
11763 (build_constructors): Likewise.
11764 (switch_conversion::build_constructors): Likewise.
11765 (constructor_contains_same_values_p): Likewise.
11766 (switch_conversion::contains_same_values_p): Likewise.
11767 (array_value_type): Likewise.
11768 (switch_conversion::array_value_type): Likewise.
11769 (build_one_array): Likewise.
11770 (switch_conversion::build_one_array): Likewise.
11771 (build_arrays): Likewise.
11772 (switch_conversion::build_arrays): Likewise.
11773 (gen_def_assigns): Likewise.
11774 (switch_conversion::gen_def_assigns): Likewise.
11775 (prune_bbs): Likewise.
11776 (switch_conversion::prune_bbs): Likewise.
11777 (fix_phi_nodes): Likewise.
11778 (switch_conversion::fix_phi_nodes): Likewise.
11779 (gen_inbound_check): Likewise.
11780 (switch_conversion::gen_inbound_check): Likewise.
11781 (process_switch): Use the newly created class.
11782 (switch_conversion::expand): New.
11783 (switch_conversion::~switch_conversion): New.
11784 * tree-switch-conversion.h: New file.
11786 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11788 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
11789 tree-vect-patterns.c.
11790 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
11791 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
11792 (vect_recog_sad_pattern): Likewise.
11793 (vect_recog_widen_sum_pattern): Likewise.
11794 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
11795 (vect_recog_widen_shift_pattern): Remove the type_in argument.
11796 (vect_recog_rotate_pattern): Likewise.
11797 (vect_recog_mult_pattern): Likewise.
11798 (vect_recog_vector_vector_shift_pattern): Likewise.
11799 (vect_recog_divmod_pattern): Likewise.
11800 (vect_recog_mixed_size_cond_pattern): Likewise.
11801 (vect_recog_bool_pattern): Likewise.
11802 (vect_recog_mask_conversion_pattern): Likewise.
11803 (vect_try_gather_scatter_pattern): Likewise.
11804 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
11805 (vect_recog_over_widening_pattern): Likewise.
11806 (vect_recog_gather_scatter_pattern): Likewise.
11807 (vect_recog_func_ptr): Move from tree-vectorizer.h
11808 (vect_vect_recog_func_ptrs): Move further down the file.
11809 (vect_recog_func): Likewise. Remove the third argument.
11810 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
11811 (vect_pattern_recog_1): Expect the pattern function to do any
11812 necessary target tests. Also expect it to provide a vector type.
11813 Remove the type_in handling.
11815 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11817 * tree-vect-patterns.c (vect_pattern_detected): New function.
11818 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
11819 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
11820 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
11821 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
11822 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
11823 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
11824 (vect_recog_mask_conversion_pattern)
11825 (vect_try_gather_scatter_pattern): Likewise.
11827 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11829 * tree-vect-patterns.c (vect_get_internal_def): New function.
11830 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11831 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
11832 (search_type_for_mask_1): Use it.
11834 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11836 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
11837 redundant WIDEN_SUM_EXPR handling.
11838 (vect_recog_sad_pattern): Likewise.
11840 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11842 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
11843 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
11844 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
11845 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
11846 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
11848 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11850 * tree-vect-stmts.c (vectorizable_call): Make sure that we
11851 use the stmt_vec_info of the original bb statement for the
11852 new zero assignment, even if the call is part of a pattern.
11854 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11856 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
11857 that the sequence is attached to the original statement rather
11858 than the pattern statement.
11859 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
11860 PATTERN_DEF_SEQ from the original statement rather than
11861 the main pattern statement.
11862 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
11863 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
11864 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
11866 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
11868 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
11869 definition statements before the early exit for statements that aren't
11871 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
11873 (vect_transform_loop): ...here. Process pattern definition
11874 statements without first checking whether the main pattern
11875 statement is live or relevant.
11877 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
11879 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
11880 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
11882 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
11884 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
11885 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
11886 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
11887 (expand_block_compare): Change select_block_compare_mode call.
11888 (expand_strncmp_align_check): Use new functions, fix comment.
11889 (emit_final_str_compare_gpr): New function.
11890 (expand_strn_compare): Refactor and clean up code.
11891 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
11893 2018-06-19 Tony Reix <tony.reix@atos.com>
11894 Damien Bergamini <damien.bergamini@atos.com>
11895 David Edelsohn <dje.gcc@gmail.com>
11897 * collect2.c (static_obj): New variable.
11898 (static_libs): New variable.
11899 (is_in_list): Uncomment declaration.
11900 (main): Track AIX libraries linked statically.
11901 (is_in_list): Uncomment definition.
11902 (scan_prog_file): Don't add AIX shared libraries initializer
11903 to constructor list if linking statically.
11905 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
11907 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
11909 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
11911 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
11913 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
11916 2018-06-19 Martin Liska <mliska@suse.cz>
11918 * config/i386/i386.c (ix86_can_inline_p): Do not use
11919 ipa_fn_summaries::get_create.
11920 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
11922 (devirtualization_time_bonus): Likewise.
11923 (ipcp_propagate_stage): Likewise.
11924 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
11925 (edge_set_predicate): Likewise.
11926 (evaluate_conditions_for_known_args): Likewise.
11927 (evaluate_properties_for_edge): Likewise.
11928 (ipa_call_summary::reset): Tranform to ...
11929 (ipa_call_summary::~ipa_call_summary): ... this.
11930 (ipa_fn_summary::reset): Transform to ...
11931 (ipa_fn_summary::~ipa_fn_summary): ... this.
11932 (ipa_fn_summary_t::remove): Rename to ...
11933 (ipa_fn_summary_t::remove_callees): ... this.
11934 (ipa_fn_summary_t::duplicate): Use placement new
11935 instead of memory copy.
11936 (ipa_call_summary_t::duplicate): Likewise.
11937 (ipa_call_summary_t::remove): Remove.
11938 (dump_ipa_call_summary): Change get_create to get.
11939 (ipa_dump_fn_summary): Dump only when summary exists.
11940 (analyze_function_body): Use symbol_summary::get instead
11942 (compute_fn_summary): Likewise.
11943 (estimate_edge_devirt_benefit): Likewise.
11944 (estimate_edge_size_and_time): Likewise.
11945 (inline_update_callee_summaries): Likewise.
11946 (remap_edge_change_prob): Likewise.
11947 (remap_edge_summaries): Likewise.
11948 (ipa_merge_fn_summary_after_inlining): Likewise.
11949 (write_ipa_call_summary): Likewise.
11950 (ipa_fn_summary_write): Likewise.
11951 (ipa_free_fn_summary): Likewise.
11952 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
11953 (struct ipa_call_summary): Likewise.
11954 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
11956 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
11957 (estimate_size_after_inlining): Likewise.
11958 (estimate_growth): Likewise.
11959 (growth_likely_positive): Likewise.
11960 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
11961 (inline_call): Likewise.
11962 * ipa-inline.c (caller_growth_limits): Likewise.
11963 (can_inline_edge_p): Likewise.
11964 (can_inline_edge_by_limits_p): Likewise.
11965 (compute_uninlined_call_time): Likewise.
11966 (compute_inlined_call_time): Likewise.
11967 (want_inline_small_function_p): Likewise.
11968 (edge_badness): Likewise.
11969 (update_caller_keys): Likewise.
11970 (update_callee_keys): Likewise.
11971 (inline_small_functions): Likewise.
11972 (inline_to_all_callers_1): Likewise.
11973 (dump_overall_stats): Likewise.
11974 (early_inline_small_functions): Likewise.
11975 (early_inliner): Likewise.
11976 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
11977 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
11978 * ipa-pure-const.c (malloc_candidate_p): Likewise.
11979 * ipa-split.c (execute_split_functions): Likewise.
11980 * symbol-summary.h: Likewise.
11981 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
11983 2018-06-19 Richard Biener <rguenther@suse.de>
11985 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
11986 (vectorize_loops): ... here. Fix dbgcnt handling.
11987 (try_vectorize_loop): Wrap try_vectorize_loop_1.
11989 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
11992 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
11993 ieee128 argument takes up only one (vector) register, not two (floating
11996 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
11998 * gimplify.c (gimplify_init_constructor): Really never clear for an
11999 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
12001 2018-06-19 Richard Biener <rguenther@suse.de>
12003 PR tree-optimization/86179
12004 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
12005 after failed recognition.
12007 2018-06-18 Martin Sebor <msebor@redhat.com>
12009 PR middle-end/85602
12010 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
12011 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
12012 Handle integer subtraction.
12013 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
12014 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
12016 2018-06-18 David Malcolm <dmalcolm@redhat.com>
12018 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
12019 param from rtx to rtx_insn *.
12020 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
12022 (frv_ifcvt_modify_insn): Likwise.
12023 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
12024 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
12025 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
12026 as_a <rtx_insn *> cast to local "unprotected_region" once
12027 it's been established that it's not NULL or pc_rtx.
12028 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
12029 param "sethi" from rtx to rtx_insn *.
12030 (nds32_group_float_insns): Likewise for param "insn".
12031 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
12033 (vax_output_int_subtract): Likewise.
12034 * config/vax/vax.c (vax_output_int_add): Likewise for param
12036 (vax_output_int_subtract): Likewise.
12037 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
12038 (emit_pattern_after): Likewise for param "after".
12039 (emit_insn_after): Likewise.
12040 (emit_jump_insn_after): Likewise.
12041 (emit_call_insn_after): Likewise.
12042 (emit_debug_insn_after): Likewise.
12043 (emit_pattern_before): Likewise for param "before".
12044 (emit_insn_before): Likewise.
12045 (emit_jump_insn_before): Likewise.
12046 * final.c (get_insn_template): Likewise for param "insn", removing
12048 * output.h (get_insn_template): Likewise for 2nd param.
12049 * rtl.h (emit_insn_before): Likewise.
12050 (emit_jump_insn_before): Likewise.
12051 (emit_debug_insn_before_noloc): Likewise.
12052 (emit_insn_after): Likewise.
12053 (emit_jump_insn_after): Likewise.
12054 (emit_call_insn_after): Likewise.
12055 (emit_debug_insn_after): Likewise.
12056 (set_insn_deleted): Likewise for param.
12058 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
12061 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
12062 floating point modes, so that IFmode is numerically greater than
12063 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
12064 to declare the ordering. This prevents IFmode from being
12065 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
12066 machine. Include rs6000-modes.h to share the fractional values
12067 between genmodes* and the rest of the compiler.
12068 (IFmode): Likewise.
12069 (KFmode): Likewise.
12070 (TFmode): Likewise.
12071 * config/rs6000/rs6000-modes.h: New file.
12072 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
12073 meaning of rs6000_long_double_size so that 126..128 selects an
12074 appropriate 128-bit floating point type.
12075 (rs6000_option_override_internal): Likewise.
12076 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
12077 (TARGET_LONG_DOUBLE_128): Change the meaning of
12078 rs6000_long_double_size so that 126..128 selects an appropriate
12079 128-bit floating point type.
12080 (LONG_DOUBLE_TYPE_SIZE): Update comment.
12081 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
12082 source and destination to match the standard usage.
12083 (truncifkf2): Likewise.
12084 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
12085 ISA 2.07 to use an explicit clobber, instead of passing in a
12087 (copysign<mode>3_soft): Likewise.
12089 2018-06-18 David Malcolm <dmalcolm@redhat.com>
12091 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
12092 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
12093 (vect_slp_analyze_instance_dependence): Likewise.
12094 (vect_enhance_data_refs_alignment): Likewise.
12095 (vect_analyze_data_refs_alignment): Likewise.
12096 (vect_slp_analyze_and_verify_instance_alignment
12097 (vect_analyze_data_ref_accesses): Likewise.
12098 (vect_prune_runtime_alias_test_list): Likewise.
12099 (vect_analyze_data_refs): Likewise.
12100 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
12101 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
12102 (vect_analyze_scalar_cycles_1): Likewise.
12103 (vect_get_loop_niters): Likewise.
12104 (vect_analyze_loop_form_1): Likewise.
12105 (vect_update_vf_for_slp): Likewise.
12106 (vect_analyze_loop_operations): Likewise.
12107 (vect_analyze_loop): Likewise.
12108 (vectorizable_induction): Likewise.
12109 (vect_transform_loop): Likewise.
12110 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
12111 * tree-vect-slp.c (vect_analyze_slp): Likewise.
12112 (vect_make_slp_decision): Likewise.
12113 (vect_detect_hybrid_slp): Likewise.
12114 (vect_slp_analyze_operations): Likewise.
12115 (vect_slp_bb): Likewise.
12116 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
12117 (vectorizable_bswap): Likewise.
12118 (vectorizable_call): Likewise.
12119 (vectorizable_simd_clone_call): Likewise.
12120 (vectorizable_conversion): Likewise.
12121 (vectorizable_assignment): Likewise.
12122 (vectorizable_shift): Likewise.
12123 (vectorizable_operation): Likewise.
12124 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
12126 2018-06-18 Martin Sebor <msebor@redhat.com>
12128 PR tree-optimization/81384
12129 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
12130 * builtins.c (expand_builtin_strnlen): New function.
12131 (expand_builtin): Call it.
12132 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
12133 * builtins.def (BUILT_IN_STRNLEN): New.
12134 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
12135 Warn for bounds in excess of maximum object size.
12136 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
12137 single-value ranges. Handle strnlen.
12138 (handle_builtin_strlen): Handle strnlen.
12139 (strlen_check_and_optimize_stmt): Same.
12140 * doc/extend.texi (Other Builtins): Document strnlen.
12142 2018-06-18 Maya Rashish <coypu@sdf.org>
12144 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
12145 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
12146 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
12148 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
12150 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
12152 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
12154 * tree.c (escaped_string::escape): Replace cast to char * by
12155 const_cast<char *> (unescaped).
12157 2018-06-18 Nick Clifton <nickc@redhat.com>
12160 * tree.c (escaped_string): New class. Converts an unescaped
12161 string into its escaped equivalent.
12162 (warn_deprecated_use): Use the new class to convert the
12163 deprecation message, if present.
12164 (test_escaped_strings): New self test.
12165 (test_c_tests): Add test_escaped_strings.
12166 * doc/extend.texi (deprecated): Add a note that the
12167 deprecation message is affected by the -fmessage-length
12168 option, and that control characters will be escaped.
12169 (#pragma GCC error): Document this pragma.
12170 (#pragma GCC warning): Likewise.
12171 * doc/invoke.texi (-fmessage-length): Document this option's
12172 effect on the #warning and #error preprocessor directives and
12173 the deprecated attribute.
12175 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
12177 * tree.c (decl_value_expr_lookup): Revert latest change.
12178 (decl_value_expr_insert): Likewise.
12180 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
12182 * gimplify.c (nonlocal_vlas): Delete.
12183 (nonlocal_vla_vars): Likewise.
12184 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
12186 (gimplify_body): Do not create and destroy nonlocal_vlas.
12187 * tree-nested.c: Include diagnostic.h.
12188 (use_pointer_in_frame): Tweak.
12189 (lookup_field_for_decl): Add assertion and declare the transformation.
12190 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
12191 internal error when the reference is in a wrong context. Do not
12192 create a debug decl by default.
12193 (note_nonlocal_block_vlas): Delete.
12194 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
12195 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
12196 create a debug decl by default.
12197 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
12198 call is in a wrong context.
12199 (fixup_vla_decls): New function.
12200 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
12201 debug variables were created.
12202 * tree.c (decl_value_expr_lookup): Add checking assertion.
12203 (decl_value_expr_insert): Likewise.
12205 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
12207 PR middle-end/82479
12208 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
12209 * tree-scalar-evolution.c (interpret_expr): Likewise.
12210 (expression_expensive_p): Likewise.
12211 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
12212 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
12213 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
12214 (ssa_defined_by_minus_one_stmt_p): New.
12216 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
12218 PR middle-end/64946
12219 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
12220 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
12221 * dojump.c (do_jump): Likewise.
12222 * expr.c (expand_expr_real_2): Check operand type's sign.
12223 * fold-const.c (const_unop): Handle ABSU_EXPR.
12224 (fold_abs_const): Likewise.
12225 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
12226 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
12227 (strip_sign_op_1): Likesise.
12228 * match.pd: Add new pattern to generate ABSU_EXPR.
12229 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
12230 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
12231 * tree-eh.c (operation_could_trap_helper_p): Likewise.
12232 * tree-inline.c (estimate_operator_cost): Likewise.
12233 * tree-pretty-print.c (dump_generic_node): Likewise.
12234 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
12235 * tree.def (ABSU_EXPR): New.
12237 2018-06-16 Jakub Jelinek <jakub@redhat.com>
12239 PR middle-end/86095
12240 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
12241 documented as preserved for backward compatibility only.
12242 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
12244 PR rtl-optimization/86108
12245 * bb-reorder.c (create_forwarder_block): Renamed to ...
12246 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
12247 jump from new landing pad to the second part.
12248 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
12251 2018-06-15 Jakub Jelinek <jakub@redhat.com>
12253 PR middle-end/85878
12254 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
12255 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
12256 Only call store_expr for halves if the mode is the same.
12258 PR middle-end/86123
12259 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
12260 Fix up comment formatting.
12262 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
12264 * typed-splay-tree.h (typed_splay_tree::remove): New function.
12265 (typed_splay_tree::closure,
12266 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
12267 (typed_splay_tree::typed_splay_tree,
12268 typed_splay_tree::operator =): Declared private.
12269 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
12270 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
12271 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
12272 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
12273 typed_splay_tree::splay_tree_splay,
12274 typed_splay_tree::splay_tree_foreach_helper,
12275 typed_splay_tree::splay_tree_insert,
12276 typed_splay_tree::splay_tree_remove,
12277 typed_splay_tree::splay_tree_lookup,
12278 typed_splay_tree::splay_tree_predecessor,
12279 typed_splay_tree::splay_tree_successor,
12280 typed_splay_tree::splay_tree_min,
12281 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
12282 (typed_splay_tree::root, typed_splay_tree::comp,
12283 typed_splay_tree::delete_key,
12284 typed_splay_tree::delete_value): New data members.
12285 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
12286 typed_splay_tree::remove.
12288 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
12290 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
12291 -mginv and -mno-ginv to the assembler.
12292 * config/mips/mips.opt (-mcrc): New option.
12293 (-mginv): Likewise.
12294 * doc/invoke.text (-mcrc): Document.
12295 (-mginv): Likewise.
12297 2018-06-15 Nick Clifton <nickc@redhat.com>
12300 * tree.c (escaped_string): New class. Converts an unescaped
12301 string into its escaped equivalent.
12302 (warn_deprecated_use): Use the new class to convert the
12303 deprecation message, if present.
12304 (test_escaped_strings): New self test.
12305 (test_c_tests): Add test_escaped_strings.
12306 * doc/extend.texi (deprecated): Add a note that the
12307 deprecation message is affected by the -fmessage-length
12308 option, and that control characters will be escaped.
12309 (#pragma GCC error): Document this pragma.
12310 (#pragma GCC warning): Likewise.
12311 * doc/invoke.texi (-fmessage-length): Document this option's
12312 effect on the #warning and #error preprocessor directives and
12313 the deprecated attribute.
12315 2018-06-15 Richard Biener <rguenther@suse.de>
12317 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
12318 here, also noting vector size used.
12319 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
12320 size used in MSG_OPTIMIZED_LOCATIONS dump.
12321 (pass_slp_vectorize::execute): Adjust.
12323 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
12326 * config/arc/arc.c (arc_return_address_register): Fix
12329 2018-06-15 Richard Biener <rguenther@suse.de>
12331 PR middle-end/86159
12332 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
12333 leave useless conversion stripping to force_gimple_operand_gsi.
12334 (gimplify_build2): Likewise.
12335 (gimplify_build1): Likewise.
12337 2018-06-15 Richard Biener <rguenther@suse.de>
12339 PR middle-end/86076
12340 * tree-cfg.c (move_stmt_op): unshare invariant addresses
12341 before adjusting their block.
12343 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
12345 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
12346 multilibs for *-*-rtems*.
12347 * config/riscv/t-rtems: New file.
12349 2018-06-14 Jakub Jelinek <jakub@redhat.com>
12351 PR middle-end/86122
12352 * match.pd ((A +- CST1) +- CST2): Punt if last resort
12353 unsigned_type_for returns NULL.
12356 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
12357 subregs of multi-word pseudos unless the float mode has word size.
12359 2018-06-14 Richard Biener <rguenther@suse.de>
12361 PR middle-end/86139
12362 * tree-vect-generic.c (build_word_mode_vector_type): Remove
12363 duplicate and harmful type_hash_canon.
12364 * tree.c (type_hash_canon): Assert we didn't find ourselves.
12366 2018-06-14 Richard Biener <rguenther@suse.de>
12369 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
12372 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
12374 * config/rtems.h (STDINT_LONG32): Define.
12376 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
12377 Prachi Godbole <prachi.godbole@imgtec.com>
12379 * config/mips/mips-cpus.def: Define P6600.
12380 * config/mips/mips-tables.opt: Regenerate.
12381 * config/mips/mips.c (mips_ucbranch_type): New enum.
12382 (mips_rtx_cost_data): Add support for P6600.
12383 (mips_issue_rate): Likewise.
12384 (mips_multipass_dfa_lookahead): Likewise.
12385 (mips_avoid_hazard): Likewise.
12386 (mips_reorg_process_insns): Likewise.
12387 (mips_classify_branch_p6600): New function.
12388 * config/mips/mips.h (TUNE_P6600): New define.
12389 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
12390 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
12391 * config/mips/mips.md: Include p6600.md.
12392 (processor): Add p6600.
12393 * config/mips/p6600.md: New file.
12394 * doc/invoke.texi: Add p6600 to supported architectures.
12396 2018-06-13 Martin Sebor <msebor@redhat.com>
12398 PR tree-optimization/86114
12399 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
12401 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
12403 2018-06-13 Richard Biener <rguenther@suse.de>
12405 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
12406 Properly set vector type of the intermediate stmt.
12407 * tree-vect-stmts.c (vectorizable_operation): The destination
12408 var always has vectype_out type.
12410 2018-06-13 Jeff Law <law@redhat.com>
12412 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
12413 integer 0 for argument to print_rtl_with_bb.
12414 (rl78_reorg): Likewise.
12416 2018-06-13 David Malcolm <dmalcolm@redhat.com>
12418 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
12419 from rtx to rtx_insn *.
12420 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
12422 (add_sched_insns_for_speculation): Likewise for local "target",
12423 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
12424 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
12425 from rtx_insn ** to rtx_code_label **.
12426 (reorg_emit_nops): Likewise.
12427 (c6x_reorg): Likewise for local "call_labels".
12428 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
12430 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
12431 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
12432 the loops over LABEL_REFS.
12433 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
12435 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
12436 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
12437 (split_branches): Strengthen local "olabel" from rtx to
12438 rtx_insn *, adding a safe_as_a cast.
12439 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
12441 (add_insn_after): Likewise for first two params.
12442 (add_insn_before): Likewise.
12443 (remove_insn): Likewise for param.
12444 (emit_pattern_before_noloc): Likewise for second and third params.
12445 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
12446 (emit_call_insn_before_noloc): Likewise.
12447 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
12449 (emit_barrier_before): Likewise.
12450 (emit_label_before): Strengthen "label" param from "rtx" to
12451 "rtx_code_label *". Strengthen "before" param from "rtx" to
12453 (emit_insn_after_1): Strengthen "after" param from "rtx" to
12455 (emit_pattern_after_noloc): Likewise.
12456 (emit_insn_after_noloc): Likewise.
12457 (emit_jump_insn_after_noloc): Likewise.
12458 (emit_call_insn_after_noloc): Likewise.
12459 (emit_debug_insn_after_noloc): Likewise.
12460 (emit_barrier_after): Likewise.
12461 (emit_label_after): Likewise for both params.
12462 (emit_pattern_after_setloc): Likewise for "after" param. Convert
12463 "loc" param from "int" to "location_t".
12464 (emit_insn_after_setloc): Likewise.
12465 (emit_jump_insn_after_setloc): Likewise.
12466 (emit_call_insn_after_setloc): Likewise.
12467 (emit_debug_insn_after_setloc): Likewise.
12468 (emit_pattern_before_setloc): Likewise for "before" param. Convert
12469 "loc" param from "int" to "location_t".
12470 (emit_pattern_before): Convert NULL_RTX to NULL.
12471 (emit_insn_before_setloc): Convert "loc" param from "int" to
12473 (emit_jump_insn_before_setloc): Likewise.
12474 (emit_call_insn_before_setloc): Likewise.
12475 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
12476 rtx_insn *. Convert "loc" param from "int" to "location_t".
12477 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
12478 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
12479 Convert 3rd param from "int" to "location_t".
12480 (emit_barrier_before, emit_barrier_after, next_real_insn):
12481 Strengthen param from rtx to rtx_insn *.
12482 (emit_label_before): Strengthen 1st param from "rtx" to
12483 "rtx_code_label *". Strengthen 2nd param from "rtx" to
12485 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
12486 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
12487 Strengthen 2nd param from "rtx" to "rtx_insn *".
12488 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
12489 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
12490 Likewise. Convert 3rd param from "int" to "location_t".
12491 (emit_label_after): Strengthen 1st param from "rtx" to
12492 "rtx_code_label *".
12493 (next_real_insn, remove_insn): Strengthen param from "rtx" to
12495 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
12496 from "rtx" to "rtx_insn *".
12498 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
12500 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
12501 bodies streamed in with -Q.
12502 * dumpfile.c (dump_files): Add lto-stream-out dump file.
12503 * dumpfile.h (tree_dump_index): Add lto_stream_out.
12504 * gimple-streamer-out.c: Include gimple-pretty-print.h
12505 (output_bb): Dump stmts streamed.
12506 * lto-section-out.c: Include print-tree.h
12507 (lto_begin_section): Dump sections created.
12508 (lto_output_decl_index): Dump decl encoded.
12509 * lto-streamer-out.c: Include print-tree.h
12510 (create_output_block): Dump output block created.
12511 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
12512 (output_function): Dump function output.
12513 (output_constructor): Dump constructor streamed.
12514 (write_global_stream): Output indexes encoded.
12515 (produce_asm_for_decls): Dump streams encoded.
12516 * lto-streamer.c (streamer_dump_file): New global var.
12517 * lto-streamer.h (streamer_dump_file): Declare.
12518 * passes.c (ipa_write_summaries): Initialize streamer dump.
12519 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
12522 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
12525 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
12526 offsets for register save directives. Emit a second batch of save
12527 directives, if need be, when the function accesses prior frames.
12529 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12531 * config/arc/fpu.md (fmasf4): Force operand to register.
12532 (fnmasf4): Likewise.
12534 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12536 * config/arc/arc-protos.h (arc_pad_return): Remove.
12537 * config/arc/arc.c (machine_function): Remove force_short_suffix
12539 (arc_print_operand): Adjust printing of '&'.
12540 (arc_verify_short): Remove conditional printing of short suffix.
12541 (arc_final_prescan_insn): Remove reference to size_reason.
12542 (pad_return): New function.
12543 (arc_reorg): Call pad_return.
12544 (arc_pad_return): Remove.
12545 (arc_init_machine_status): Remove reference to force_short_suffix.
12546 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
12547 (attr length): When attribute iscompact is true force to 2
12548 regardless; in the case of maybe check if we want to force the
12549 instruction to have 4 bytes length.
12550 (nopv): Change it to generate 4 byte long nop as well.
12551 (blockage): New pattern.
12552 (simple_return): Remove call to arc_pad_return.
12553 (p_return_i): Likewise.
12555 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12557 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
12559 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12561 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
12564 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12566 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
12567 for ARC700 and ARCv2.
12569 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
12572 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
12573 operands[2] instead of operands[1].
12576 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
12578 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
12579 case, check whether the outer register overlaps an unallocatable
12580 register, not just whether it fits the required class.
12582 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
12584 * poly-int.h (can_div_trunc_p): Add new overload in which all values
12586 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
12587 (memrefs_conflict_p): Likewise.
12588 (init_alias_analysis): Likewise.
12589 * cfgexpand.c (expand_debug_expr): Likewise.
12590 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
12591 * cse.c (fold_rtx): Likewise.
12592 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
12593 * expr.c (emit_block_move_hints): Likewise.
12594 (clear_storage_hints, push_block, emit_push_insn): Likewise.
12595 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
12596 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
12597 (emit_group_store): Likewise.
12598 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
12599 to read the PRE/POST_MODIFY increment.
12600 * calls.c (store_one_arg): Use strip_offset.
12601 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
12603 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
12605 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
12606 (simplify_binary_operation_1): Extend CONST_INT handling to
12608 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
12609 than a HOST_WIDE_INT.
12610 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
12612 (adjust_mems, add_stores): Update accodingly.
12613 (vt_canonicalize_addr): Track polynomial offsets.
12614 (emit_note_insn_var_location): Likewise.
12615 (vt_add_function_parameter): Likewise.
12616 (vt_initialize): Likewise.
12618 2018-06-12 Jeff Law <law@redhat.com>
12620 * config.gcc (alpha*-*-freebsd*): Remove.
12621 * config/alpha/freebsd.h: Remove.
12623 2018-06-12 David Malcolm <dmalcolm@redhat.com>
12626 * spellcheck-tree.c (levenshtein_distance): Rename to...
12627 (get_edit_distance): ...this, and update for underlying renaming.
12628 * spellcheck-tree.h (levenshtein_distance): Rename to...
12629 (get_edit_distance): ...this.
12630 * spellcheck.c (levenshtein_distance): Rename to...
12631 (get_edit_distance): ...this. Convert from Levenshtein distance
12632 to Damerau-Levenshtein distance by supporting transpositions of
12633 adjacent characters. Rename "v1" to "v_next" and "v0" to
12635 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
12636 (selftest::test_edit_distance_unit_test_oneway): ...this, and
12637 update for underlying renaming.
12638 (selftest::levenshtein_distance_unit_test): Rename to...
12639 (selftest::test_get_edit_distance_unit): ...this, and update for
12640 underlying renaming.
12641 (selftest::test_find_closest_string): Add example from PR 69968
12642 where transposition helps
12643 (selftest::test_metric_conditions): Update for renaming.
12644 (selftest::test_metric_conditions): Likewise.
12645 (selftest::spellcheck_c_tests): Likewise.
12646 * spellcheck.h (levenshtein_distance): Rename both overloads to...
12647 (get_edit_distance): ...this.
12648 (best_match::consider): Update for renaming.
12650 2018-06-12 Martin Sebor <msebor@redhat.com>
12652 PR tree-optimization/85259
12653 * builtins.c (compute_objsize): Handle constant offsets.
12654 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
12655 true iff a warning has been issued.
12656 * gimple.h (gimple_nonartificial_location): New function.
12657 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
12658 gimple_nonartificial_location and handle -Wno-system-headers.
12659 (handle_builtin_stxncpy): Same.
12661 2018-06-12 Martin Sebor <msebor@redhat.com>
12664 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
12666 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
12668 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
12669 BUILTIN_VEC_XST entries for pointer to double and long long.
12671 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
12674 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
12676 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
12679 2018-06-12 Martin Liska <mliska@suse.cz>
12681 * doc/options.texi: Document IntegerRange.
12683 2018-06-12 Martin Liska <mliska@suse.cz>
12685 * config/i386/i386.opt: Make MPX-related options as Deprecated.
12686 * opt-functions.awk: Handle Deprecated flag.
12687 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
12689 (read_cmdline_option): Report warning for a deprecated option.
12690 * opts.h (struct cl_option): Add new field cl_deprecated.
12691 (CL_ERR_DEPRECATED): New.
12693 2018-06-12 Martin Liska <mliska@suse.cz>
12695 * doc/options.texi: Document Deprecated option flag.
12697 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12699 * config/arc/arc-arch.h (arc_extras): New enum.
12700 (arc_cpu_t):Add field extra.
12701 (arc_cpu_types): Consider the extras.
12702 * config/arc/arc-cpus.def: Add extras info.
12703 * config/arc/arc-opts.h (processor_type): Consider extra field.
12704 * config/arc/arc.c (arc_override_options): Handle extra field.
12706 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
12708 * config/arc/arc-arch.h: Update ARC_OPTX macro.
12709 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
12711 * config/arc/arc.c (arc_init): Update pic warning.
12712 (irq_range): Update irq range parsing warnings.
12713 (arc_override_options): Update various warning messages.
12714 (arc_handle_aux_attribute): Likewise.
12716 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
12718 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
12720 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
12722 * doc/sourcebuild.texi: Document usage of line number 0 in verify
12723 compiler messages directives.
12725 2018-06-12 Matthew Fortune <mfortune@gmail.com>
12727 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
12728 * config/mips/mips-tables.opt: Regenerate.
12729 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
12731 * doc/invoke.texi: Document -march=i6500.
12733 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
12735 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
12736 (i6400_gpmul): Add cpu_unit.
12737 (i6400_gpdiv): Likewise.
12738 (i6400_msa_add_d): Update reservations.
12739 (i6400_msa_int_add) Likewise.
12740 (i6400_msa_short_logic3) Likewise.
12741 (i6400_msa_short_logic2) Likewise.
12742 (i6400_msa_short_logic) Likewise.
12743 (i6400_msa_move) Likewise.
12744 (i6400_msa_cmp) Likewise.
12745 (i6400_msa_short_float2) Likewise.
12746 (i6400_msa_div_d) Likewise.
12747 (i6400_msa_long_logic1) Likewise.
12748 (i6400_msa_long_logic2) Likewise.
12749 (i6400_msa_mult) Likewise.
12750 (i6400_msa_long_float2) Likewise.
12751 (i6400_msa_long_float4) Likewise.
12752 (i6400_msa_long_float5) Likewise.
12753 (i6400_msa_long_float8) Likewise.
12754 (i6400_fpu_fadd): Include frint type.
12755 (i6400_fpu_store): New define_insn_reservation.
12756 (i6400_fpu_load): Likewise.
12757 (i6400_fpu_move): Likewise.
12758 (i6400_fpu_fcmp): Likewise.
12759 (i6400_fpu_fmadd): Likewise.
12760 (i6400_int_mult): Include imul3nc type and update reservation.
12761 (i6400_int_div): Include idiv3 type and update reservation.
12762 (i6400_int_load): Update to check type not move_type.
12763 (i6400_int_store): Likewise.
12764 (i6400_int_prefetch): Set zero latency.
12766 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
12768 * gcc.c: Document new %@{...} sequence.
12769 (LINK_COMMAND_SPEC): Use it for the -L switches.
12770 (cpp_unique_options): Use it for the -I switches.
12771 (at_file_argbuf): New global variable.
12772 (in_at_file): Likewise.
12773 (alloc_args): Create at_file_argbuf.
12774 (clear_args): Truncate at_file_argbuf.
12775 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
12776 (open_at_file): New function.
12777 (close_at_file): Likewise.
12778 (create_at_file): Delete.
12779 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
12782 (validate_switches_from_spec): Deal with %@{...} sequence.
12783 (validate_switches): Likewise.
12784 (driver::finalize): Call clear_args.
12786 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
12788 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
12790 2018-06-11 Martin Sebor <msebor@redhat.com>
12792 * doc/invoke.texi (-Wall): List -Wc++17-compat.
12793 (Wno-class-memaccess): Add @opindex.
12794 (Wno-templates, Wno-multiple-inheritance): Same.
12795 (Wno-virtual-inheritance, Wno-namespaces): Same.
12796 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
12797 (Wno-format-overflow, Wno-format-truncation): Same.
12798 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
12799 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
12800 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
12801 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
12802 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
12803 (Wno-misspelled-isr): Same.
12805 2018-06-11 Martin Sebor <msebor@redhat.com>
12807 * PR tree-optimization/86083
12808 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
12810 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
12812 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
12814 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
12817 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
12818 on the correct operand.
12819 (*movdi_internal64): Ditto.
12821 2018-06-11 Martin Liska <mliska@suse.cz>
12823 PR tree-optimization/86089
12824 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
12826 2018-06-11 Julia Koval <julia.koval@intel.com>
12828 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
12829 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
12830 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
12832 2018-06-11 Olivier Hainque <hainque@adacore.com>
12834 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
12835 for Ada with strict dwarf2.
12837 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
12840 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
12843 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
12845 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
12847 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
12849 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
12852 2018-06-08 Martin Liska <mliska@suse.cz>
12854 * tree-cfg.h (debug_function): Fix argument type to match
12857 2018-06-08 Martin Liska <mliska@suse.cz>
12859 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
12860 Remove usage of MPX-related (and removed) fields.
12861 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
12863 2018-06-08 David Malcolm <dmalcolm@redhat.com>
12865 * cfg.c (debug): Use TDF_NONE rather than 0.
12866 * cfghooks.c (debug): Likewise.
12867 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
12868 (struct dump_option_value_info): Convert to...
12869 (struct kv_pair): ...this template type.
12870 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
12872 (optinfo_verbosity_options): Likewise.
12873 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
12875 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
12876 than int for "optgroup_flags" param.
12877 (dump_generic_expr_loc): Use dump_flags_t rather than int for
12879 (dump_dec): Likewise.
12880 (dump_finish): Use TDF_NONE rather than 0.
12881 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
12882 rather than int for "optgroup_flags" param. Use TDF_NONE rather
12883 than 0. Update for change to option_ptr.
12884 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
12885 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
12886 0. Update for changes to optinfo_verbosity_options and
12888 (opt_info_switch_p): Convert optgroup_flags from int to
12890 (dump_basic_block): Use dump_flags_t rather than int
12891 for "dump_kind" param.
12892 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
12893 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
12894 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
12895 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
12896 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
12897 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
12898 TDF_NONE): Convert from macros to...
12899 (enum dump_flag): ...this new enum.
12900 (dump_flags_t): Update to use enum.
12901 (operator|, operator&, operator~, operator|=, operator&=):
12902 Implement for dump_flags_t.
12903 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
12904 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
12905 Convert from macros to...
12906 (enum optgroup_flag): ...this new enum.
12907 (optgroup_flags_t): New typedef.
12908 (operator|, operator|=): Implement for optgroup_flags_t.
12909 (struct dump_file_info): Convert field "alt_flags" to
12910 dump_flags_t. Convert field "optgroup_flags" to
12912 (dump_basic_block): Use dump_flags_t rather than int for param.
12913 (dump_generic_expr_loc): Likewise.
12914 (dump_dec): Likewise.
12915 (dump_register): Convert param "optgroup_flags" to
12917 (opt_info_enable_passes): Likewise.
12918 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
12920 * gimple-pretty-print.c (debug): Likewise.
12921 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
12922 (merged_store_group::apply_stores): Likewise.
12923 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
12924 * gimple.c (verify_gimple_pp): Likewise.
12925 * graphite-poly.c (print_pbb_body): Likewise.
12926 * passes.c (pass_manager::register_one_dump_file): Convert
12927 local "optgroup_flags" to optgroup_flags_t.
12928 * print-tree.c (print_node): Use TDF_NONE rather than 0.
12930 (debug_body): Likewise.
12931 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
12932 to optgroup_flags_t.
12933 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
12935 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
12936 (convert_mult_to_fma): Likewise.
12937 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
12938 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
12939 * tree-vect-data-refs.c (dump_lower_bound): Convert param
12940 "dump_kind" to dump_flags_t.
12942 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
12944 * config/rs6000/rs6000.c (min, max): Delete.
12946 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
12948 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
12949 -mabi=spe and -mabi=no-spe.
12951 2018-06-08 Martin Liska <mliska@suse.cz>
12953 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
12954 where we expect an existing summary.
12956 2018-06-08 Martin Liska <mliska@suse.cz>
12958 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
12959 * ipa-inline.h (estimate_edge_growth): Likewise.
12961 2018-06-08 Martin Liska <mliska@suse.cz>
12963 * cgraph.c (function_version_hasher::hash): Use
12964 cgraph_node::get_uid ().
12965 (function_version_hasher::equal):
12966 * cgraph.h (cgraph_node::get_uid): New method.
12967 * ipa-inline.c (update_caller_keys): Use
12968 cgraph_node::get_uid ().
12969 (update_callee_keys): Likewise.
12970 * ipa-utils.c (searchc): Likewise.
12971 (ipa_reduced_postorder): Likewise.
12972 * lto-cgraph.c (input_node): Likewise.
12973 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
12974 * symbol-summary.h (symtab_insertion): Likewise.
12975 (symtab_removal): Likewise.
12976 (symtab_duplication): Likewise.
12977 * tree-pretty-print.c (dump_function_header): Likewise.
12978 * tree-sra.c (convert_callers_for_node): Likewise.
12980 2018-06-08 Martin Liska <mliska@suse.cz>
12982 * cgraph.c (symbol_table::create_edge): Always assign a new
12984 (symbol_table::free_edge): Do not recycle numbers.
12985 * cgraph.h (cgraph_edge::get): New method.
12986 * symbol-summary.h (symtab_removal): Use it.
12987 (symtab_duplication): Likewise.
12988 (call_summary::hashable_uid): Remove.
12990 2018-06-08 Martin Liska <mliska@suse.cz>
12992 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
12993 (initialize_growth_caches): Remove.
12994 (free_growth_caches): Likewise.
12995 (do_estimate_edge_time): Use edge_growth_cache.
12996 (do_estimate_edge_size): Likewise.
12997 (do_estimate_edge_hints): Likewise.
12998 * ipa-inline.c (reset_edge_caches): Likewise.
12999 (recursive_inlining): Likewise.
13000 (inline_small_functions): Likewise.
13001 * ipa-inline.h (initialize_growth_caches): Remove.
13002 (estimate_edge_size): Likewise.
13003 (estimate_edge_time): Likewise.
13004 (estimate_edge_hints): Likewise.
13005 (reset_edge_growth_cache): Likewise.
13006 * symbol-summary.h (call_summary::remove): New method.
13008 2018-06-08 Martin Liska <mliska@suse.cz>
13010 * ipa-cp.c (class edge_clone_summary): New summary.
13011 (grow_edge_clone_vectors): Remove.
13012 (ipcp_edge_duplication_hook): Remove.
13013 (class edge_clone_summary_t): New call_summary class.
13014 (ipcp_edge_removal_hook): Remove.
13015 (edge_clone_summary_t::duplicate): New function.
13016 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
13017 (create_specialized_node): Likewise.
13018 (ipcp_driver): Initialize edge_clone_summaries and do not
13021 2018-06-08 Martin Liska <mliska@suse.cz>
13023 * symbol-summary.h (get): New function.
13024 (call_summary::m_initialize_when_cloning): New class member.
13026 2018-06-08 Martin Liska <mliska@suse.cz>
13028 * cgraph.c (cgraph_node::remove): Do not recycle uid.
13029 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
13030 (symbol_table::allocate_cgraph_symbol): Do not set uid.
13031 * passes.c (uid_hash_t): Record removed_nodes by their uids.
13032 (remove_cgraph_node_from_order): Use the removed_nodes set.
13033 (do_per_function_toporder): Likwise.
13034 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
13035 instead of summary_uid.
13036 (symtab_removal): Likewise.
13037 (symtab_duplication): Likewise.
13039 2018-06-08 Martin Liska <mliska@suse.cz>
13041 * ipa-cp.c (ipcp_store_bits_results): Use
13042 ipcp_transformation_sum.
13043 (ipcp_store_vr_results): Likewise.
13044 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
13046 (ipcp_transformation_initialize): ... this.
13047 (ipa_set_node_agg_value_chain):
13048 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
13049 (write_ipcp_transformation_info): Likewise.
13050 (read_ipcp_transformation_info): Likewise.
13051 (ipcp_update_bits): Likewise.
13052 (ipcp_update_vr): Likewise.
13053 (ipcp_transform_function): Likewise.
13054 * ipa-prop.h: Rename ipcp_transformation_summary to
13055 ipcp_transformation.
13056 (class ipcp_transformation_t): New function summary.
13057 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
13058 (ipa_get_agg_replacements_for_node): Likewise.
13060 2018-06-08 Martin Liska <mliska@suse.cz>
13062 * ipa-pure-const.c (struct funct_state_d): Do it class instead
13064 (class funct_state_summary_t): New function_summary class.
13065 (has_function_state): Remove.
13066 (get_function_state): Likewise.
13067 (set_function_state): Likewise.
13068 (add_new_function): Likewise.
13069 (funct_state_summary_t::insert): New function.
13070 (duplicate_node_data): Remove.
13071 (remove_node_data): Remove.
13072 (funct_state_summary_t::duplicate): New function.
13073 (register_hooks): Create new funct_state_summaries.
13074 (pure_const_generate_summary): Use it.
13075 (pure_const_write_summary): Likewise.
13076 (pure_const_read_summary): Likewise.
13077 (propagate_pure_const): Likewise.
13078 (propagate_nothrow): Likewise.
13079 (dump_malloc_lattice): Likewise.
13080 (propagate_malloc): Likewise.
13081 (execute): Do not register hooks, just remove summary
13083 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
13086 2018-06-08 Martin Liska <mliska@suse.cz>
13088 * ipa-reference.c (remove_node_data): Remove.
13089 (duplicate_node_data): Likewise.
13090 (class ipa_ref_var_info_summary_t): New class.
13091 (class ipa_ref_opt_summary_t): Likewise.
13092 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
13093 (get_reference_optimization_summary): Use
13094 ipa_ref_opt_sum_summaries.
13095 (set_reference_vars_info): Remove.
13096 (set_reference_optimization_summary): Likewise.
13097 (ipa_init): Create summaries.
13098 (init_function_info): Use function summary.
13099 (ipa_ref_opt_summary_t::duplicate): New function.
13100 (ipa_ref_opt_summary_t::remove): New function.
13101 (get_read_write_all_from_node): Fix GNU coding style.
13102 (propagate): Use function summary.
13103 (write_node_summary_p): Fix GNU coding style.
13104 (stream_out_bitmap): Likewise.
13105 (ipa_reference_read_optimization_summary): Use function summary.
13106 (ipa_reference_c_finalize): Do not release hooks.
13108 2018-06-08 Martin Liska <mliska@suse.cz>
13110 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
13111 (analyze_function_body): Extract multiple calls of get_create.
13112 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
13113 * ipa-inline.c (recursive_inlining): Use ::get method.
13114 * ipa-inline.h (estimate_edge_growth): Likewise.
13116 2018-06-08 Martin Liska <mliska@suse.cz>
13118 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
13120 (hsa_function_summary::hsa_function_summary): Use the new enum
13122 (hsa_gpu_implementation_p): Use hsa_summaries::get.
13123 * hsa-gen.c (hsa_get_host_function): Likewise.
13124 (get_brig_function_name): Likewise.
13125 * ipa-hsa.c (process_hsa_functions): Likewise.
13126 (ipa_hsa_write_summary): Likewise.
13127 * symbol-summary.h (symtab_duplication): Use ::get function/
13128 (get): New function.
13130 2018-06-08 Martin Liska <mliska@suse.cz>
13132 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
13134 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
13135 (hsa_register_kernel): Likewise.
13136 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
13137 * hsa-gen.c (hsa_get_host_function): Likewise.
13138 (get_brig_function_name): Likewise.
13139 (generate_hsa): Likewise.
13140 (pass_gen_hsail::execute): Likewise.
13141 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
13142 (devirtualization_time_bonus): Likewise.
13143 (ipcp_propagate_stage): Likewise.
13144 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
13145 (edge_set_predicate): Likewise.
13146 (evaluate_conditions_for_known_args): Likewise.
13147 (evaluate_properties_for_edge): Likewise.
13148 (ipa_fn_summary::reset): Likewise.
13149 (ipa_fn_summary_t::duplicate): Likewise.
13150 (dump_ipa_call_summary): Likewise.
13151 (ipa_dump_fn_summary): Likewise.
13152 (analyze_function_body): Likewise.
13153 (compute_fn_summary): Likewise.
13154 (estimate_edge_devirt_benefit): Likewise.
13155 (estimate_edge_size_and_time): Likewise.
13156 (estimate_calls_size_and_time): Likewise.
13157 (estimate_node_size_and_time): Likewise.
13158 (inline_update_callee_summaries): Likewise.
13159 (remap_edge_change_prob): Likewise.
13160 (remap_edge_summaries): Likewise.
13161 (ipa_merge_fn_summary_after_inlining): Likewise.
13162 (ipa_update_overall_fn_summary): Likewise.
13163 (read_ipa_call_summary): Likewise.
13164 (inline_read_section): Likewise.
13165 (write_ipa_call_summary): Likewise.
13166 (ipa_fn_summary_write): Likewise.
13167 (ipa_free_fn_summary): Likewise.
13168 * ipa-hsa.c (process_hsa_functions): Likewise.
13169 (ipa_hsa_write_summary): Likewise.
13170 (ipa_hsa_read_section): Likewise.
13171 * ipa-icf.c (sem_function::merge): Likewise.
13172 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
13173 (do_estimate_edge_time): Likewise.
13174 (estimate_size_after_inlining): Likewise.
13175 (estimate_growth): Likewise.
13176 (growth_likely_positive): Likewise.
13177 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
13178 (inline_call): Likewise.
13179 * ipa-inline.c (caller_growth_limits): Likewise.
13180 (can_inline_edge_p): Likewise.
13181 (can_inline_edge_by_limits_p): Likewise.
13182 (compute_uninlined_call_time): Likewise.
13183 (compute_inlined_call_time): Likewise.
13184 (want_inline_small_function_p): Likewise.
13185 (edge_badness): Likewise.
13186 (update_caller_keys): Likewise.
13187 (update_callee_keys): Likewise.
13188 (recursive_inlining): Likewise.
13189 (inline_small_functions): Likewise.
13190 (inline_to_all_callers_1): Likewise.
13191 (dump_overall_stats): Likewise.
13192 (early_inline_small_functions): Likewise.
13193 (early_inliner): Likewise.
13194 * ipa-inline.h (estimate_edge_growth): Likewise.
13195 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13196 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
13197 * ipa-prop.h (IPA_NODE_REF): Likewise.
13198 (IPA_EDGE_REF): Likewise.
13199 * ipa-pure-const.c (malloc_candidate_p): Likewise.
13200 (propagate_malloc): Likewise.
13201 * ipa-split.c (execute_split_functions): Likewise.
13202 * symbol-summary.h: Rename get to get_create.
13204 (get_create): Likewise.
13205 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
13207 2018-06-08 Martin Liska <mliska@suse.cz>
13209 * symbol-summary.h (release): Move definition out of class
13211 (symtab_removal): Likewise.
13212 (symtab_duplication): Likewise.
13214 2018-06-08 Martin Liska <mliska@suse.cz>
13216 * symbol-summary.h (function_summary): Move constructor
13217 implementation out of class declaration.
13218 (release): Likewise.
13219 (symtab_insertion): Likewise.
13220 (symtab_removal): Likewise.
13221 (symtab_duplication): Likewise.
13224 2018-06-08 Martin Liska <mliska@suse.cz>
13226 * Makefile.in: Remove support for MPX (macros, related functions,
13227 fields in cgraph_node, ...).
13228 * builtin-types.def (BT_BND): Likewise.
13229 (BT_FN_BND_CONST_PTR): Likewise.
13230 (BT_FN_CONST_PTR_BND): Likewise.
13231 (BT_FN_VOID_PTR_BND): Likewise.
13232 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
13233 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
13234 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
13235 (expand_builtin_mempcpy_with_bounds): Likewise.
13236 (expand_builtin_memset_with_bounds): Likewise.
13237 (expand_builtin_memset_args): Likewise.
13238 (std_expand_builtin_va_start): Likewise.
13239 (expand_builtin): Likewise.
13240 (expand_builtin_with_bounds): Likewise.
13241 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
13242 (DEF_LIB_BUILTIN_CHKP): Likewise.
13243 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
13244 (DEF_CHKP_BUILTIN): Likewise.
13245 (BUILT_IN_MEMCPY): Likewise.
13246 (BUILT_IN_MEMMOVE): Likewise.
13247 (BUILT_IN_MEMPCPY): Likewise.
13248 (BUILT_IN_MEMSET): Likewise.
13249 (BUILT_IN_STPCPY): Likewise.
13250 (BUILT_IN_STRCAT): Likewise.
13251 (BUILT_IN_STRCHR): Likewise.
13252 (BUILT_IN_STRCPY): Likewise.
13253 (BUILT_IN_STRLEN): Likewise.
13254 (BUILT_IN_MEMCPY_CHK): Likewise.
13255 (BUILT_IN_MEMMOVE_CHK): Likewise.
13256 (BUILT_IN_MEMPCPY_CHK): Likewise.
13257 (BUILT_IN_MEMSET_CHK): Likewise.
13258 (BUILT_IN_STPCPY_CHK): Likewise.
13259 (BUILT_IN_STRCAT_CHK): Likewise.
13260 (BUILT_IN_STRCPY_CHK): Likewise.
13261 * calls.c (store_bounds): Likewise.
13262 (emit_call_1): Likewise.
13263 (special_function_p): Likewise.
13264 (maybe_warn_nonstring_arg): Likewise.
13265 (initialize_argument_information): Likewise.
13266 (finalize_must_preallocate): Likewise.
13267 (compute_argument_addresses): Likewise.
13268 (expand_call): Likewise.
13269 * cfgexpand.c (expand_call_stmt): Likewise.
13270 (expand_return): Likewise.
13271 (expand_gimple_stmt_1): Likewise.
13272 (pass_expand::execute): Likewise.
13273 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
13274 (cgraph_node::remove): Likewise.
13275 (cgraph_node::dump): Likewise.
13276 (cgraph_node::verify_node): Likewise.
13277 * cgraph.h (chkp_function_instrumented_p): Likewise.
13278 (symtab_node::get_alias_target): Likewise.
13279 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
13280 (cgraph_local_p): Likewise.
13281 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
13282 (cgraph_edge::rebuild_references): Likewise.
13283 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
13284 (walk_polymorphic_call_targets): Likewise.
13285 (cgraph_node::expand_thunk): Likewise.
13286 (symbol_table::output_weakrefs): Likewise.
13287 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
13288 (ix86_handle_option): Likewise.
13289 * config/i386/constraints.md: Likewise.
13290 * config/i386/i386-builtin-types.def (BND): Likewise.
13294 * config/i386/i386-builtin.def (BDESC_END): Likewise.
13295 (BDESC_FIRST): Likewise.
13297 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
13298 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
13299 * config/i386/i386.c (enum reg_class): Likewise.
13300 (ix86_target_string): Likewise.
13301 (ix86_option_override_internal): Likewise.
13302 (ix86_conditional_register_usage): Likewise.
13303 (ix86_valid_target_attribute_inner_p): Likewise.
13304 (ix86_set_indirect_branch_type): Likewise.
13305 (ix86_set_current_function): Likewise.
13306 (ix86_function_arg_regno_p): Likewise.
13307 (init_cumulative_args): Likewise.
13308 (ix86_function_arg_advance): Likewise.
13309 (ix86_function_arg): Likewise.
13310 (ix86_pass_by_reference): Likewise.
13311 (ix86_function_value_regno_p): Likewise.
13312 (ix86_function_value_1): Likewise.
13313 (ix86_function_value_bounds): Likewise.
13314 (ix86_return_in_memory): Likewise.
13315 (ix86_setup_incoming_vararg_bounds): Likewise.
13316 (ix86_va_start): Likewise.
13317 (indirect_thunk_need_prefix): Likewise.
13318 (print_reg): Likewise.
13319 (ix86_print_operand): Likewise.
13320 (ix86_expand_call): Likewise.
13321 (ix86_output_function_return): Likewise.
13322 (reg_encoded_number): Likewise.
13323 (BDESC_VERIFYS): Likewise.
13324 (ix86_init_mpx_builtins): Likewise.
13325 (ix86_init_builtins): Likewise.
13326 (ix86_emit_cmove): Likewise.
13327 (ix86_emit_move_max): Likewise.
13328 (ix86_expand_builtin): Likewise.
13329 (ix86_builtin_mpx_function): Likewise.
13330 (ix86_get_arg_address_for_bt): Likewise.
13331 (ix86_load_bounds): Likewise.
13332 (ix86_store_bounds): Likewise.
13333 (ix86_load_returned_bounds): Likewise.
13334 (ix86_store_returned_bounds): Likewise.
13335 (ix86_class_likely_spilled_p): Likewise.
13336 (ix86_hard_regno_mode_ok): Likewise.
13337 (x86_order_regs_for_local_alloc): Likewise.
13338 (ix86_mitigate_rop): Likewise.
13339 (ix86_bnd_prefixed_insn_p): Likewise.
13340 (ix86_mpx_bound_mode): Likewise.
13341 (ix86_make_bounds_constant): Likewise.
13342 (ix86_initialize_bounds): Likewise.
13343 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
13344 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
13345 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
13346 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
13347 (TARGET_CHKP_BOUND_MODE): Likewise.
13348 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
13349 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
13350 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
13351 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
13352 * config/i386/i386.h (TARGET_MPX): Likewise.
13353 (TARGET_MPX_P): Likewise.
13354 (VALID_BND_REG_MODE): Likewise.
13355 (FIRST_BND_REG): Likewise.
13356 (LAST_BND_REG): Likewise.
13357 (enum reg_class): Likewise.
13358 (BND_REG_P): Likewise.
13359 (BND_REGNO_P): Likewise.
13360 (BNDmode): Likewise.
13361 (ADJUST_INSN_LENGTH): Likewise.
13362 * config/i386/i386.md: Likewise.
13363 * config/i386/i386.opt: Likewise.
13364 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
13365 (defined): Likewise.
13366 (LINK_MPX): Likewise.
13367 (MPX_SPEC): Likewise.
13368 (LIBMPX_SPEC): Likewise.
13369 (LIBMPXWRAPPERS_SPEC): Likewise.
13370 (CHKP_SPEC): Likewise.
13371 * config/i386/predicates.md: Likewise.
13372 * dbxout.c (dbxout_type): Likewise.
13373 * doc/extend.texi: Likewise.
13374 * doc/invoke.texi: Likewise.
13375 * doc/md.texi: Likewise.
13376 * doc/tm.texi: Likewise.
13377 * doc/tm.texi.in: Likewise.
13378 * dwarf2out.c (is_base_type): Likewise.
13379 (gen_formal_types_die): Likewise.
13380 (gen_subprogram_die): Likewise.
13381 (gen_type_die_with_usage): Likewise.
13382 (gen_decl_die): Likewise.
13383 (dwarf2out_late_global_decl): Likewise.
13384 * expr.c (expand_assignment): Likewise.
13385 (emit_storent_insn): Likewise.
13386 (store_expr_with_bounds): Likewise.
13387 (store_expr): Likewise.
13388 (expand_expr_real_1): Likewise.
13389 * expr.h (store_expr_with_bounds): Likewise.
13390 * function.c (use_register_for_decl): Likewise.
13391 (struct bounds_parm_data): Likewise.
13392 (assign_parms_augmented_arg_list): Likewise.
13393 (assign_parm_find_entry_rtl): Likewise.
13394 (assign_parm_is_stack_parm): Likewise.
13395 (assign_parm_load_bounds): Likewise.
13396 (assign_bounds): Likewise.
13397 (assign_parms): Likewise.
13398 (expand_function_start): Likewise.
13399 * gcc.c (CHKP_SPEC): Likewise.
13400 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
13401 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
13402 (wrestrict_dom_walker::check_call): Likewise.
13403 * gimple.c (gimple_build_call_from_tree): Likewise.
13404 * gimple.h (enum gf_mask): Likewise.
13405 (gimple_call_with_bounds_p): Likewise.
13406 (gimple_call_set_with_bounds): Likewise.
13407 * gimplify.c (gimplify_init_constructor): Likewise.
13408 * ipa-cp.c (initialize_node_lattices): Likewise.
13409 (propagate_constants_across_call): Likewise.
13410 (find_more_scalar_values_for_callers_subset): Likewise.
13411 * ipa-hsa.c (process_hsa_functions): Likewise.
13412 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
13413 * ipa-icf.c (sem_function::merge): Likewise.
13414 * ipa-inline.c (early_inliner): Likewise.
13415 * ipa-pure-const.c (warn_function_noreturn): Likewise.
13416 (warn_function_cold): Likewise.
13417 (propagate_pure_const): Likewise.
13418 * ipa-ref.h (enum GTY): Likewise.
13419 * ipa-split.c (find_retbnd): Likewise.
13420 (consider_split): Likewise.
13421 (split_function): Likewise.
13422 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
13423 * ipa.c (walk_polymorphic_call_targets): Likewise.
13424 (symbol_table::remove_unreachable_nodes): Likewise.
13425 (process_references): Likewise.
13426 (cgraph_build_static_cdtor_1): Likewise.
13427 * lto-cgraph.c (lto_output_node): Likewise.
13428 (output_refs): Likewise.
13429 (compute_ltrans_boundary): Likewise.
13430 (input_overwrite_node): Likewise.
13431 (input_node): Likewise.
13432 (input_cgraph_1): Likewise.
13433 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
13434 * passes.c (pass_manager::execute_early_local_passes): Likewise.
13435 (class pass_chkp_instrumentation_passes): Likewise.
13436 (make_pass_chkp_instrumentation_passes): Likewise.
13437 * passes.def: Likewise.
13438 * rtl.h (struct GTY): Likewise.
13439 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
13440 * stor-layout.c (layout_type): Likewise.
13441 * symtab.c: Likewise.
13442 * target.def: Likewise.
13443 * targhooks.c (default_chkp_bound_type): Likewise.
13444 (default_chkp_bound_mode): Likewise.
13445 (default_builtin_chkp_function): Likewise.
13446 (default_chkp_function_value_bounds): Likewise.
13447 (default_chkp_make_bounds_constant): Likewise.
13448 (default_chkp_initialize_bounds): Likewise.
13449 * targhooks.h (default_chkp_bound_type): Likewise.
13450 (default_chkp_bound_mode): Likewise.
13451 (default_builtin_chkp_function): Likewise.
13452 (default_chkp_function_value_bounds): Likewise.
13453 (default_chkp_make_bounds_constant): Likewise.
13454 (default_chkp_initialize_bounds): Likewise.
13455 * toplev.c (compile_file): Likewise.
13456 (process_options): Likewise.
13457 * tree-core.h (DEF_BUILTIN): Likewise.
13458 (DEF_BUILTIN_CHKP): Likewise.
13459 * tree-inline.c (declare_return_variable): Likewise.
13460 (remap_gimple_stmt): Likewise.
13461 (copy_bb): Likewise.
13462 (initialize_inlined_parameters): Likewise.
13463 (expand_call_inline): Likewise.
13464 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
13465 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
13466 (make_pass_ipa_chkp_produce_thunks): Likewise.
13467 (make_pass_chkp): Likewise.
13468 (make_pass_chkp_opt): Likewise.
13469 (make_pass_chkp_instrumentation_passes): Likewise.
13470 * tree-pretty-print.c (dump_generic_node): Likewise.
13471 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
13472 * tree-ssa-dce.c (propagate_necessity): Likewise.
13473 (eliminate_unnecessary_stmts): Likewise.
13474 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
13475 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
13476 * tree-ssa-sccvn.h: Likewise.
13477 * tree-ssa-strlen.c (get_string_length): Likewise.
13478 (valid_builtin_call): Likewise.
13479 (adjust_last_stmt): Likewise.
13480 (handle_builtin_strchr): Likewise.
13481 (handle_builtin_strcpy): Likewise.
13482 (handle_builtin_stxncpy): Likewise.
13483 (handle_builtin_memcpy): Likewise.
13484 (handle_builtin_strcat): Likewise.
13485 (strlen_check_and_optimize_stmt): Likewise.
13486 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
13487 * tree-streamer-in.c: Likewise.
13488 * tree-streamer.c (record_common_node): Likewise.
13489 * tree.c (tree_code_size): Likewise.
13490 (wide_int_to_tree_1): Likewise.
13491 (type_contains_placeholder_1): Likewise.
13492 (build_common_tree_nodes): Likewise.
13493 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
13494 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
13495 (POINTER_BOUNDS_P): Likewise.
13496 (BOUNDED_TYPE_P): Likewise.
13497 (BOUNDED_P): Likewise.
13498 (CALL_WITH_BOUNDS_P): Likewise.
13499 (pointer_bounds_type_node): Likewise.
13500 * value-prof.c (gimple_ic): Likewise.
13501 * var-tracking.c (vt_add_function_parameters): Likewise.
13502 * varasm.c (make_decl_rtl): Likewise.
13503 (assemble_start_function): Likewise.
13504 (output_constant): Likewise.
13505 (maybe_assemble_visibility): Likewise.
13506 * varpool.c (ctor_for_folding): Likewise.
13507 * chkp-builtins.def: Remove.
13508 * ipa-chkp.c: Remove.
13509 * ipa-chkp.h: Remove.
13510 * rtl-chkp.c: Remove.
13511 * rtl-chkp.h: Remove.
13512 * tree-chkp-opt.c: Remove.
13513 * tree-chkp.c: Remove.
13514 * tree-chkp.h: Remove.
13516 2018-06-07 Carl Love <cel@us.ibm.com>
13518 * config/rs6000/vsx.md (vextract_fp_from_shorth,
13519 vextract_fp_from_shortl): Add BE support.
13521 2018-06-07 Paul Koning <ni1d@arrl.net>
13523 * compare-elim.c (try_merge_compare): Don't merge compare if
13524 address contains a side effect.
13525 (try_eliminate_compare): Likewise.
13527 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
13529 * config.gcc: Support "tremont".
13530 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
13531 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
13533 * config/i386/i386.c (m_TREMONT): Define.
13534 (processor_target_table): Add "tremont".
13535 (PTA_TREMONT): Define.
13536 (ix86_lea_outperforms): Add TARGET_TREMONT.
13537 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
13538 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
13539 and M_INTEL_GOLDMONT_PLUS.
13540 (fold_builtin_cpu): Add "tremont".
13541 (ix86_add_stmt_cost): Add TARGET_TREMONT.
13542 (ix86_option_override_internal): Add "tremont".
13543 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
13544 (processor_type): Add PROCESSOR_TREMONT.
13545 * config/i386/x86-tune.def: Add m_TREMONT.
13546 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
13548 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13550 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
13551 symbol defined for msp430i* devices to be lower case.
13553 2018-06-07 Richard Biener <rguenther@suse.de>
13555 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
13556 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
13557 Properly wrap signed arithmetic if overflow wraps.
13559 2018-06-07 Jakub Jelinek <jakub@redhat.com>
13561 PR tree-optimization/69615
13562 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
13563 of a cast from a same precision integral SSA_NAME in a bb dominated
13564 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
13565 cast to utype if rhs2 has already a compatible type.
13567 2018-06-07 Richard Biener <rguenther@suse.de>
13569 PR tree-optimization/85935
13570 * graphite-scop-detection.c (find_params_in_bb): Analyze
13571 condition operands with respect to the correct loop. Assert
13572 the analysis doesn't fail.
13574 2018-06-04 Carl Love <cel@us.ibm.com>
13576 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
13577 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
13578 as it is slightly cheaper.
13579 (first_match_or_eos_index_<mode>):
13580 Calculate index using natural element order.
13581 (first_match_index_<mode>):
13582 Calculate index using natural element order.
13583 (first_match_or_eos_index_<mode>):
13584 Calculate index using natural order.
13585 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
13586 for BE and LE modes.
13587 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
13588 P9V_BUILTIN_VCLZLSBB_V16QI.
13589 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
13592 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
13594 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
13595 indentation and line wrap for many prototypes. Add missing
13596 @smallexample directives around block of prototypes for vec_xl and
13599 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
13601 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
13602 track if we pass or return IEEE 128-bit floating point.
13603 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
13604 C++ mangling that is compatible with GCC 8.1.
13605 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
13606 (init_cumulative_args): Note if we pass or return IEEE 128-bit
13607 floating point types.
13608 (rs6000_function_arg_advance_1): Likewise.
13609 (rs6000_mangle_type): Optionally generate mangled names that match
13610 what GCC 8.1 generated for IEEE 128-bit floating point types.
13611 (rs6000_globalize_decl_name): If we have an external function that
13612 passes or returns IEEE 128-bit types, generate a weak reference
13613 from the mangled name used in GCC 8.1 to the current mangled
13615 (rs6000_init_builtins): Make __ibm128 use the long double type if
13616 long double is IBM extended double. Make __float128 use the long
13617 double type if long double is IEEE 128-bit.
13620 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
13621 macro for __ibm128 built-in functions.
13622 (PACK_IF): Add __ibm128 pack/unpack functions.
13623 (UNPACK_IF): Likewise.
13624 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
13625 enable long double built-in functions if long double is IEEE
13626 128-bit floating point.
13627 (rs6000_invalid_builtin): Update long double built-in function
13629 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
13630 functions, adjust the built-in function to use the long double
13631 built-in function if __ibm128 and long double are the same type.
13632 * doc/extend.texi (PowerPC builtins): Update documention for
13633 __builtin_{,un}pack_longdouble. Add documentation for
13634 __builtin_{,un}pack_ibm128.
13636 2018-06-06 Jim Wilson <jimw@sifive.com>
13638 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
13639 (struct machine_function): New field interrupt_mode.
13640 (riscv_handle_type_attribute): New function. Add forward declaration.
13641 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
13642 (riscv_expand_epilogue): Check interrupt_mode field.
13643 (riscv_set_current_function): Check interrupt attribute args and
13644 set interrupt_mode field.
13645 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
13646 (riscv_sret, riscv_uret): New.
13647 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
13648 new arguments to interrupt attribute.
13650 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
13653 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
13654 Don't handle -mcpu=power8 if -mpower9-vector is also used.
13656 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
13658 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
13659 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
13660 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
13661 several redundant entries.
13663 2018-06-06 David Malcolm <dmalcolm@redhat.com>
13665 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
13666 type from "rtx" to "rtx_insn *".
13667 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
13668 for local "call_insn", removing cast.
13669 (ix86_expand_call): Likewise, introducing a "call_insn" local.
13671 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
13673 PR tree-optimization/86066
13674 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
13675 for BIT_INSERT_EXPR stores.
13677 2018-06-06 Richard Biener <rguenther@suse.de>
13679 PR tree-optimization/86062
13680 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
13681 component refs ontop
13682 of to be offsetted base.
13684 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13686 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
13687 to be static and remove check on interrupt attribute name.
13689 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
13691 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
13692 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
13694 2018-06-05 Steve Ellcey <sellcey@cavium.com>
13697 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
13699 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
13700 Remove second argument, change how error is called.
13701 (aarch64_layout_arg): Remove second argument from
13702 aarch64_err_no_fpadvsimd call.
13703 (aarch64_init_cumulative_args): Ditto.
13704 (aarch64_gimplify_va_arg_expr): Ditto.
13705 * config/aarch64/aarch64.md (mov<mode>): Ditto.
13707 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
13709 * config/i386/i386.md (simple_return_indirect_internal): New expander.
13710 (*simple_return_indirect_internal<mode>): Rename from
13711 simple_return_indirect_internal. Use W mode iterator.
13712 (rstorssp): New expander.
13713 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
13714 (clrssbsy): New expander.
13715 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
13717 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
13719 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
13721 (cmse_check_pointed_object): Likewise.
13723 2018-06-05 Martin Liska <mliska@suse.cz>
13725 PR gcov-profile/47618
13726 * doc/invoke.texi: Document how -fprofile-dir format
13729 2018-06-05 Richard Biener <rguenther@suse.de>
13731 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
13732 removal pretend DOM info isn't available so we do not update
13733 it and only remove edges, not dominated blocks. Actually free
13734 DOM info in case we removed something. Remove unreachable blocks.
13735 (mfb_keep_latches): Work with either DOM info or marked backedges.
13736 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
13737 first. Mark backedges if DOM info isn't available.
13738 (Re-)compute DOM info after cleanup_control_flow_pre.
13740 2018-06-05 Richard Biener <rguenther@suse.de>
13742 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
13743 (locus_discrim_hasher::hash): Adjust.
13744 (locus_discrim_hasher::equal): Likewise.
13745 (next_discriminator_for_locus): Work on line directly.
13746 (same_line_p): Pass in expanded locus1 as well.
13747 (assign_discriminators): Avoid redundant location expansions.
13749 2018-06-05 Richard Biener <rguenther@suse.de>
13751 PR tree-optimization/86046
13752 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
13753 if required after clearing TREE_ADDRESSABLE.
13755 2018-06-05 Richard Biener <rguenther@suse.de>
13757 PR tree-optimization/86047
13758 * tree-ssa-loop.c (for_each_index): Glob handling of all
13759 decls and constants and really handle all of them.
13761 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13764 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
13765 qualifier_void_pointer and qualifier_const_void_pointer.
13766 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
13767 (arm_init_builtins): Handle the above.
13768 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
13769 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
13770 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
13773 2018-06-05 Martin Liska <mliska@suse.cz>
13775 * auto-profile.c (read_autofdo_file): Do not use
13776 gcov_ctr_summary struct.
13777 (afdo_callsite_hot_enough_for_early_inline): Likewise.
13778 * coverage.c (struct counts_entry): Likewise.
13779 (read_counts_file): Read just single summary entry.
13780 (get_coverage_counts): Use gcov_summary struct.
13781 * coverage.h (get_coverage_counts): Likewise.
13782 * gcov-dump.c (dump_working_sets): Likewise.
13783 (tag_summary): Dump just single summary.
13784 * gcov-io.c (gcov_write_summary): Write just histogram
13786 (gcov_read_summary): Read just single summary.
13787 (compute_working_sets): Use gcov_summary struct.
13788 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
13789 of GCOV_COUNTERS_SUMMABLE.
13790 (GCOV_COUNTERS_SUMMABLE): Remove.
13791 (GCOV_FIRST_VALUE_COUNTER): Replace with
13792 GCOV_COUNTER_V_INTERVAL.
13793 (struct gcov_ctr_summary): Remove.
13794 (struct gcov_summary): Directly use fields of former
13796 (compute_working_sets): Use gcov_summary struct.
13797 * gcov.c (read_count_file): Do not use ctrs fields.
13798 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
13800 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
13802 * profile.c: Likewise.
13803 * profile.h: Likewise.
13805 2018-06-05 Martin Liska <mliska@suse.cz>
13807 PR gcov-profile/84846
13808 * gcov.c (output_lines): Print working directory only
13809 in intermediate format.
13811 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
13813 * config/s390/s390-builtin-types.def: Add void function type.
13814 * config/s390/s390-builtins.def: Use the function type for the
13817 2018-06-04 Jim Wilson <jimw@sifive.com>
13819 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
13821 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
13822 and maybe_eh_return. Change regno to unsigned int. Use new args to
13823 handle EH_RETURN_DATA_REGNO registers properly.
13824 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
13825 (riscv_expand_epilogue): Update comment. Change argument name and
13826 type. Update code to use new name and type. Pass new args to
13827 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
13829 * config/riscv/riscv.md (NORMAL_RETURN): New.
13830 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
13831 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
13832 (eh_return): Call gen_eh_return_internal and emit barrier.
13833 (eh_return_internal): Call riscv_expand_epilogue.
13835 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
13837 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
13838 bit_insertion field and declare can_be_merged_into method.
13839 (merged_store_group::can_be_merged_into): New method.
13840 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
13841 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
13842 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
13844 2018-06-04 Richard Biener <rguenther@suse.de>
13846 PR tree-optimization/85955
13847 * builtins.c (fold_builtin_sincos): Convert pointers to
13848 destination to appropriate type before dereferencing.
13850 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
13852 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
13854 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
13856 * expr.c (expand_expr_real_1): Force the operand into memory if
13857 its TYPE_MODE is BLKmode and if there is no integer mode for
13858 the number of bits being extracted.
13860 2018-06-04 Jakub Jelinek <jakub@redhat.com>
13864 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
13865 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
13867 2018-06-04 Richard Biener <rguenther@suse.de>
13869 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
13870 (cleanup_tree_cfg_noloop): ... single caller. Do
13871 start_recording_case_labels later.
13873 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
13875 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
13876 to _IMMINTRIN_H_INCLUDED.
13877 * config/i386/pconfigintrin.h: Ditto.
13878 * config/i386/waitpkgintrin.h: Ditto.
13879 * config/i386/immintrin.h: Add includes for sgxintrin.h,
13880 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
13881 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
13882 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
13883 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
13884 waitpkgintrin.h and cldemoteintrin.h.
13886 2018-06-04 Richard Biener <rguenther@suse.de>
13888 PR tree-optimization/86038
13889 * tracer.c (find_best_successor): Check probability for
13890 being initialized, bail out if not.
13892 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
13895 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
13896 of bits to ignore when comparing architectures.
13898 2018-06-04 Jakub Jelinek <jakub@redhat.com>
13900 PR tree-optimization/69615
13901 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
13902 maximum or minimum of the type, try to merge it also as if
13903 range1 is + [-, x - 1] or + [x + 1, -].
13906 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
13908 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
13910 PR tree-optimization/86034
13911 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
13912 the unsigned bitfield type in a bit insertion sequence if it does not
13913 have a larger precision than the bitfield size.
13914 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
13916 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
13918 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
13920 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
13922 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
13923 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
13924 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
13925 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
13927 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
13929 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
13930 Disable -fdelete-null-pointer-checks for ELF toolchain.
13932 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
13933 Kito Cheng <kito.cheng@gmail.com>
13935 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
13936 (nds32le-*-*, nds32be-*-*): Integrate checking process.
13937 (nds32*-*-*): Add glibc and uclibc conditions.
13938 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
13939 (TARGET_EXCEPT_UNWIND_INFO): Define.
13940 * config/nds32/elf.h: New file.
13941 * config/nds32/linux.h: New file.
13942 * config/nds32/nds32-elf.opt: New file.
13943 * config/nds32/nds32-linux.opt: New file.
13944 * config/nds32/nds32-fp-as-gp.c
13945 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
13946 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
13948 (nds32_asm_file_end): Ditto.
13949 (nds32_print_operand): Ditto.
13950 (nds32_insert_attributes): Ditto.
13951 (nds32_init_libfuncs): New function.
13952 (TARGET_HAVE_TLS): Define.
13953 (TARGET_INIT_LIBFUNCS): Define.
13954 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
13956 (TARGET_ELF): Apply different mcmodel setting.
13957 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
13958 been migrated into elf.h and linux.h files.
13959 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
13960 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
13961 (mcmodel): The content has been migrated into nds32-elf.opt and
13962 nds32-linux.opt files.
13963 * config/nds32/t-elf: New file.
13964 * config/nds32/t-linux: New file.
13966 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
13967 Shiva Chen <shiva0217@gmail.com>
13969 * config/nds32/constants.md (unspec_volatile_element): Add
13970 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
13971 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
13973 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
13974 (make_pass_nds32_fp_as_gp): Declare.
13975 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
13977 (nds32_asm_function_end_prologue): Remove unused asm output.
13978 (nds32_asm_function_begin_epilogue): Remove unused asm output.
13979 (nds32_asm_file_start): Output necessary fp_as_gp information.
13980 (nds32_option_override): Adjust register usage.
13981 (nds32_expand_prologue): Consider fp_as_gp situation.
13982 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
13983 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
13986 (simple_return): Ditto.
13987 (omit_fp_begin): Output special directive for fp_as_gp.
13988 (omit_fp_end): Output special directive for fp_as_gp.
13989 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
13990 mforbid-fp-as-gp): New options.
13992 2018-06-01 Mark Wielaard <mark@klomp.org>
13994 * dwarf2out.c (dwarf2out_finish): Remove generation of
13995 DW_AT_loclists_base.
13997 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
13999 * gimple-ssa-store-merging.c: Include gimple-fold.h.
14000 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
14001 (struct merged_store_group): Add bit_insertion field.
14002 (dump_char_array): Use standard hexadecimal format.
14003 (merged_store_group::merged_store_group): Set bit_insertion to false.
14004 (merged_store_group::apply_stores): Use optimal buffer size. Deal
14005 with BIT_INSERT_EXPR stores. Move up code updating the mask and
14006 also print the mask in the dump file.
14007 (pass_store_merging::gate): Minor tweak.
14008 (imm_store_chain_info::coalesce_immediate): Fix wrong association
14009 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
14010 stores with INTEGER_CST stores.
14011 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
14012 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
14013 and use it throughout. Generate bit insertion sequences if need be.
14014 (pass_store_merging::process_store): Remove redundant condition.
14015 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
14017 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
14019 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
14020 the 128-bit floating point types. Fix function comment.
14022 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14024 * config/aarch64/aarch64-simd.md
14025 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
14027 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
14030 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
14032 PR tree-optimization/85989
14033 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
14035 (backprop::intersect_uses): Check it when deciding whether this
14036 is a backedge reference.
14037 (backprop::process_block): Add each phi to m_visited_phis
14038 after visiting it, then clear it at the end.
14040 2018-06-01 Richard Biener <rguenther@suse.de>
14042 * tree-vectorizer.h (vect_dr_stmt): New function.
14043 (vect_get_load_cost): Adjust.
14044 (vect_get_store_cost): Likewise.
14045 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
14046 Use vect_dr_stmt instead of DR_SMTT.
14047 (vect_record_base_alignments): Likewise.
14048 (vect_calculate_target_alignment): Likewise.
14049 (vect_compute_data_ref_alignment): Likewise and make static.
14050 (vect_update_misalignment_for_peel): Likewise.
14051 (vect_verify_datarefs_alignment): Likewise.
14052 (vector_alignment_reachable_p): Likewise.
14053 (vect_get_data_access_cost): Likewise. Pass down
14054 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
14055 (vect_get_peeling_costs_all_drs): Likewise.
14056 (vect_peeling_hash_get_lowest_cost): Likewise.
14057 (vect_enhance_data_refs_alignment): Likewise.
14058 (vect_find_same_alignment_drs): Likewise.
14059 (vect_analyze_data_refs_alignment): Likewise.
14060 (vect_analyze_group_access_1): Likewise.
14061 (vect_analyze_group_access): Likewise.
14062 (vect_analyze_data_ref_access): Likewise.
14063 (vect_analyze_data_ref_accesses): Likewise.
14064 (vect_vfa_segment_size): Likewise.
14065 (vect_small_gap_p): Likewise.
14066 (vectorizable_with_step_bound_p): Likewise.
14067 (vect_prune_runtime_alias_test_list): Likewise.
14068 (vect_analyze_data_refs): Likewise.
14069 (vect_supportable_dr_alignment): Likewise.
14070 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14071 (vect_gen_prolog_loop_niters): Likewise.
14072 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14073 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
14075 (vect_recog_mask_conversion_pattern): Likewise.
14076 (vect_try_gather_scatter_pattern): Likewise.
14077 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
14078 to vect_get_store_cost.
14079 (vect_get_store_cost): Get stmt_info instead of DR.
14080 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
14081 (vect_get_load_cost): Get stmt_info instead of DR.
14083 2018-06-01 Richard Biener <rguenther@suse.de>
14085 PR middle-end/86017
14086 * gimple-fold.c (var_decl_component_p): Also allow offsetted
14087 vars wrapped in MEM_REFs.
14089 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
14091 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
14092 Fix subreg tests so that we only return a choice between
14093 GENERAL_REGS and FP_REGS if the original classes included both.
14095 2018-06-01 Richard Biener <rguenther@suse.de>
14098 * tree-ssa-structalias.c (get_function_part_constraint):
14099 Handle NULL fi->decl.
14100 (find_func_aliases_for_call): Properly handle indirect
14101 fi from direct call.
14102 (find_func_clobbers): Likewise.
14103 (ipa_pta_execute): Likewise.
14104 (create_variable_info_for): For functions that are ifunc_resolver
14105 resolve to a varinfo that contains the result of the resolver call.
14106 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
14109 2018-05-31 Michael Collison <michael.collison@arm.com>
14111 * config/aarch64/aarch64.md:
14112 (*fix_to_zero_extenddfdi2): New pattern.
14113 * gcc.target/aarch64/fix_extend1.c: New testcase.
14115 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
14117 PR middle-end/78809
14118 PR middle-end/83026
14119 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
14120 and BUILT_IN_STRNCMP_EQ.
14121 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
14122 BUILT_IN_STRNCMP_EQ.
14123 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
14124 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
14125 (gimple_fold_builtin): Likewise.
14126 * tree-ssa-strlen.c (compute_string_length): New function.
14127 (determine_min_obsize): New function.
14128 (handle_builtin_string_cmp): New function to handle calls to
14129 string compare functions.
14130 (strlen_optimize_stmt): Add handling to builtin string compare
14132 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
14133 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
14134 * tree.c (build_common_builtin_nodes): Add new defines of
14135 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
14137 2018-05-31 Jakub Jelinek <jakub@redhat.com>
14140 * bb-reorder.c (pass_partition_blocks::gate): Return false for
14141 functions with naked attribute.
14143 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
14145 * config/i386/sse.md (avx_vec_concat<mode>):
14146 Substitute concat_tg_mode mode attribute with xtg_mode.
14147 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
14148 (concat_tg_mode): Remove mode attribute.
14150 2018-05-31 Martin Sebor <msebor@redhat.com>
14153 * calls.c (alloc_max_size): Correct a logic error/typo.
14154 Treat excessive arguments as infinite. Warn for invalid arguments.
14155 * doc/invoke.texi (-Walloc-size-larger-than): Update.
14157 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
14160 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
14161 and movx for Haswell.
14163 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
14164 Cesar Philippidis <cesar@codesourcery.com>
14166 PR middle-end/85879
14167 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
14168 when emitting error on private/firstprivate reductions.
14169 * omp-low.c (lower_omp_target): Avoid reference-type processing
14170 on pointers for firstprivate clause.
14172 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
14174 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
14177 * config/aarch64/aarch64-simd.md
14178 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
14179 (aarch64_ld1_x3_<mode>): Likewise
14180 (aarch64_st1x2<VALLDIF:mode>): Likewise
14181 (aarch64_st1_x2_<mode>): Likewise
14182 (aarch64_st1x3<VALLDIF:mode>): Likewise
14183 (aarch64_st1_x3_<mode>): Likewise
14184 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
14185 (vld1_s8_x3): Likewise.
14186 (vld1_u16_x3): Likewise.
14187 (vld1_s16_x3): Likewise.
14188 (vld1_u32_x3): Likewise.
14189 (vld1_s32_x3): Likewise.
14190 (vld1_u64_x3): Likewise.
14191 (vld1_s64_x3): Likewise.
14192 (vld1_f16_x3): Likewise.
14193 (vld1_f32_x3): Likewise.
14194 (vld1_f64_x3): Likewise.
14195 (vld1_p8_x3): Likewise.
14196 (vld1_p16_x3): Likewise.
14197 (vld1_p64_x3): Likewise.
14198 (vld1q_u8_x3): Likewise.
14199 (vld1q_s8_x3): Likewise.
14200 (vld1q_u16_x3): Likewise.
14201 (vld1q_s16_x3): Likewise.
14202 (vld1q_u32_x3): Likewise.
14203 (vld1q_s32_x3): Likewise.
14204 (vld1q_u64_x3): Likewise.
14205 (vld1q_s64_x3): Likewise.
14206 (vld1q_f16_x3): Likewise.
14207 (vld1q_f32_x3): Likewise.
14208 (vld1q_f64_x3): Likewise.
14209 (vld1q_p8_x3): Likewise.
14210 (vld1q_p16_x3): Likewise.
14211 (vld1q_p64_x3): Likewise.
14212 (vst1_s64_x2): Likewise.
14213 (vst1_u64_x2): Likewise.
14214 (vst1_f64_x2): Likewise.
14215 (vst1_s8_x2): Likewise.
14216 (vst1_p8_x2): Likewise.
14217 (vst1_s16_x2): Likewise.
14218 (vst1_p16_x2): Likewise.
14219 (vst1_s32_x2): Likewise.
14220 (vst1_u8_x2): Likewise.
14221 (vst1_u16_x2): Likewise.
14222 (vst1_u32_x2): Likewise.
14223 (vst1_f16_x2): Likewise.
14224 (vst1_f32_x2): Likewise.
14225 (vst1_p64_x2): Likewise.
14226 (vst1q_s8_x2): Likewise.
14227 (vst1q_p8_x2): Likewise.
14228 (vst1q_s16_x2): Likewise.
14229 (vst1q_p16_x2): Likewise.
14230 (vst1q_s32_x2): Likewise.
14231 (vst1q_s64_x2): Likewise.
14232 (vst1q_u8_x2): Likewise.
14233 (vst1q_u16_x2): Likewise.
14234 (vst1q_u32_x2): Likewise.
14235 (vst1q_u64_x2): Likewise.
14236 (vst1q_f16_x2): Likewise.
14237 (vst1q_f32_x2): Likewise.
14238 (vst1q_f64_x2): Likewise.
14239 (vst1q_p64_x2): Likewise.
14240 (vst1_s64_x3): Likewise.
14241 (vst1_u64_x3): Likewise.
14242 (vst1_f64_x3): Likewise.
14243 (vst1_s8_x3): Likewise.
14244 (vst1_p8_x3): Likewise.
14245 (vst1_s16_x3): Likewise.
14246 (vst1_p16_x3): Likewise.
14247 (vst1_s32_x3): Likewise.
14248 (vst1_u8_x3): Likewise.
14249 (vst1_u16_x3): Likewise.
14250 (vst1_u32_x3): Likewise.
14251 (vst1_f16_x3): Likewise.
14252 (vst1_f32_x3): Likewise.
14253 (vst1_p64_x3): Likewise.
14254 (vst1q_s8_x3): Likewise.
14255 (vst1q_p8_x3): Likewise.
14256 (vst1q_s16_x3): Likewise.
14257 (vst1q_p16_x3): Likewise.
14258 (vst1q_s32_x3): Likewise.
14259 (vst1q_s64_x3): Likewise.
14260 (vst1q_u8_x3): Likewise.
14261 (vst1q_u16_x3): Likewise.
14262 (vst1q_u32_x3): Likewise.
14263 (vst1q_u64_x3): Likewise.
14264 (vst1q_f16_x3): Likewise.
14265 (vst1q_f32_x3): Likewise.
14266 (vst1q_f64_x3): Likewise.
14267 (vst1q_p64_x3): Likewise.
14269 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14271 * config/msp430/msp430.c (msp430_output_labelref): Prepend
14272 user_label_prefix to name.
14274 * tree-core.h: Update comment about the format of NAME string
14275 passed to handler in attribute_spec.
14277 * config/msp430/msp430.md: Remove erroneous subreg expression from
14278 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
14279 zero_extend{q,h}isi2.
14281 2018-05-30 Borislav Petkov <bp@suse.de>
14283 * doc/extend.texi: Document some architecture specific
14284 constraints and sort entries.
14286 2018-05-30 Martin Sebor <msebor@redhat.com>
14288 PR middle-end/85369
14289 * builtins.c (expand_builtin_stpcpy_1): New function.
14290 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
14291 only if the former succeeds.
14293 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
14295 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
14298 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
14300 * doc/invoke.texi (-flinker-output): Document
14302 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
14304 * passes.c (ipa_write_summaries): Only modify statements if body
14306 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
14307 incrementally linking.
14308 (ipa_passes): Likewise.
14309 * lto-cgraph.c (lto_output_node): When incrementally linking do not
14310 pass down resolution info.
14311 * common.opt (flag_incremental_link): Update info.
14312 * gcc.c (plugin specs): Turn flinker-output=* to
14313 -plugin-opt=-linker-output-known
14314 * toplev.c (compile_file): Also cut compilation when doing incremental
14316 * flag-types. (enum lto_partition_model): Add
14317 LTO_LINKER_OUTPUT_NOLTOREL.
14318 (invoke.texi): Add -flinker-output docs.
14319 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
14320 link same way as WPA; do not stream in dead initializers.
14322 * dwarf2out.c (dwarf2out_die_ref_for_decl,
14323 darf2out_register_external_decl): Support incremental link.
14325 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
14327 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
14329 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
14331 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
14332 it down to simple_object_copy_lto_debug_sections.
14333 (run_gcc): Determine incremental LTO link time and configure
14334 lto1 into non-wpa mode, disable renaming of debug sections.
14336 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
14338 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
14339 descriptions of various incorrectly documented functions.
14341 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
14344 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
14345 address check not strict.
14347 2018-05-30 Richard Biener <rguenther@suse.de>
14349 PR tree-optimization/85964
14350 * tracer.c (better_p): Drop initialized count check, we only
14351 call the function with initialized counts now.
14352 (find_best_successor): Do find a best edge if one
14353 has uninitialized count.
14354 (find_best_predecessor): Likewise. Do BB frequency check only
14355 if count is initialized.
14357 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
14359 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
14360 (aarch64_ldrstr_offset_compare): New.
14361 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
14362 load/store orderings.
14363 (aarch64_gen_adjusted_ldpstp): Likewise.
14365 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
14367 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
14368 Check for subset of GENERAL_REGS and FP_REGS.
14369 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
14372 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
14374 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
14375 and wi::to_poly_offset. Add the current offset and then check
14376 whether the sum fits, rather than using an unchecked addition of
14377 a checked term. Check for a shwi rather than a uhwi.
14378 * expr.c (get_bit_range): Use tree_to_poly_uint64.
14379 (store_constructor): Use poly_int_tree_p.
14380 (expand_expr_real_1): Likewise.
14381 * function.c (assign_temp): Likewise.
14382 * fold-const.c (const_binop): Use poly_int_tree_p and
14383 wi::to_poly_offset.
14384 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
14386 * ipa-icf-gimple.c (func_checker::compare_operand): Use
14387 to_poly_offset for MEM offsets.
14388 * ipa-icf.c (sem_variable::equals): Likewise.
14389 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
14390 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
14391 wi::to_poly_offset for BIT_FIELD_REF offsets.
14392 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
14393 wi::to_poly_offset.
14394 * var-tracking.c (emit_note_insn_var_location): Use
14395 tree_to_poly_uint64.
14397 2018-05-29 Jim Wilson <jimw@sifive.com>
14399 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
14401 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
14404 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
14405 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
14407 (sse4_1_round<mode>2): Use nonimmediate_operand
14408 for operand 1 predicate.
14410 2018-05-29 Martin Sebor <msebor@redhat.com>
14411 Richard Biener <rguenther@suse.de>
14414 * calls.c (get_size_range): Call determine_value_range instead
14415 of get_value_range..
14416 * tree-vrp.h (determine_value_range): Declared new function.
14417 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
14419 2018-05-29 Richard Biener <rguenther@suse.de>
14421 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
14422 sure to use non-pattern stmts for get_earlier_stmt arguments.
14423 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
14424 called on pattern stmts.
14425 (get_later_stmt): Likewise.
14427 2018-05-29 Martin Liska <mliska@suse.cz>
14429 PR gcov-profile/85759
14430 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
14433 2018-05-29 Jakub Jelinek <jakub@redhat.com>
14435 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
14437 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
14441 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
14442 VEC_PACK_FLOAT_EXPR): New tree codes.
14443 * tree-pretty-print.c (op_code_prio): Handle
14444 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
14445 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
14446 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
14447 * tree-inline.c (estimate_operator_cost): Likewise.
14448 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
14449 * fold-const.c (const_binop): Likewise.
14450 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
14451 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
14452 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
14453 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
14454 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
14455 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
14456 * expr.c (expand_expr_real_2): Likewise.
14457 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
14458 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
14459 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
14461 * optabs.c (expand_widen_pattern_expr): For
14462 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
14463 sign from result type rather than operand's type.
14464 (expand_binop_directly): For vec_packu_float_optab and
14465 vec_packs_float_optab allow result type to be different from operand's
14467 * optabs-tree.c (optab_for_tree_code): Handle
14468 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
14469 VEC_PACK_FLOAT_EXPR. Formatting fixes.
14470 * tree-vect-generic.c (expand_vector_operations_1): Handle
14471 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
14472 VEC_PACK_FLOAT_EXPR.
14473 * tree-vect-stmts.c (supportable_widening_operation): Handle
14475 (supportable_narrowing_operation): Handle FLOAT_EXPR.
14476 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
14477 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
14478 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
14479 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
14481 (vec_pack<floatprefix>_float_<mode>): New expander.
14482 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
14484 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
14485 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
14486 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
14487 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
14488 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
14490 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
14491 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
14492 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
14493 VEC_PACK_FLOAT_EXPR): Document.
14495 2018-05-29 Richard Biener <rguenther@suse.de>
14497 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
14499 (stmt_vec_info_vec): Make pointer.
14500 (init_stmt_vec_info_vec): Remove.
14501 (free_stmt_vec_info_vec): Likewise.
14502 (set_stmt_vec_info_vec): New function.
14503 (free_stmt_vec_infos): Likewise.
14504 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
14505 (set_vinfo_for_stmt): Likewise.
14506 (get_earlier_stmt): Likewise.
14507 (get_later_stmt): Likewise.
14508 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
14509 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
14510 (vec_info::~vec_info): Free stmt_vec_infos.
14511 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
14512 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
14513 (pass_slp_vectorize::execute): Likewise.
14514 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
14515 (free_stmt_vec_info_vec): Likewise.
14516 (set_stmt_vec_info_vec): New function.
14517 (free_stmt_vec_infos): Likewise.
14518 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
14519 the global stmt_vec_info_vec.
14520 * tree-parloops.c (gather_scalar_reductions): Use
14521 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
14524 2018-05-29 Richard Biener <rguenther@suse.de>
14526 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
14528 2018-05-29 Martin Liska <mliska@suse.cz>
14529 David Malcolm <dmalcolm@redhat.com>
14531 * vec.c (test_reverse): New.
14532 (vec_c_tests): Add new test.
14533 * vec.h (vl_ptr>::reverse): New function.
14535 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
14537 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
14539 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
14542 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
14544 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
14546 2018-05-28 Richard Biener <rguenther@suse.de>
14548 PR tree-optimization/85933
14549 * tree-vect-data-refs.c (vect_record_base_alignments): Only
14550 look at stmts marked as vectorizable.
14552 2018-05-28 Richard Biener <rguenther@suse.de>
14554 PR tree-optimization/85934
14555 * tree-vect-generic.c (expand_vector_operations_1): Hoist
14556 vector boolean check before scalar optimization.
14558 2018-05-28 Jakub Jelinek <jakub@redhat.com>
14560 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
14563 2018-05-28 Mark Wielaard <mark@klomp.org>
14565 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
14566 if it is an expression containing a minus sign.
14568 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
14570 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
14572 2018-05-27 Paul Koning <ni1d@arrl.net>
14574 * config/pdp11/pdp11.md (truncsihi2): Remove.
14576 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
14577 Chung-Ju Wu <jasonwucj@gmail.com>
14579 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
14581 (unaligned_store_dw): Ditto.
14582 * config/nds32/nds32-memory-manipulation.c
14583 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
14584 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
14585 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
14586 (emit_setmem_word_loop): Rename to ...
14587 (emit_setmem_doubleword_loop): ... this.
14588 (nds32_gen_dup_4_byte_to_word_value): New function.
14589 (nds32_gen_dup_8_byte_to_double_word_value): New function.
14590 (nds32_expand_setmem_loop): Refine implementation.
14591 (nds32_expand_setmem_loop_v3m): Ditto.
14592 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
14595 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
14597 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
14599 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
14601 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
14602 (nds32_init_machine_status): Initialize machine->attr_naked_p and
14603 machine->attr_no_prologue_p.
14604 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
14605 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
14606 (nds32_expand_epilogue): Consider attr_naked_p.
14607 (nds32_expand_epilogue_v3pop): Likewise.
14608 (nds32_can_use_return_insn): Likewise.
14609 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
14610 attr_no_prologue_p fields.
14611 * config/nds32/nds32.opt (mret-in-naked-func): New option.
14613 2018-05-27 Jakub Jelinek <jakub@redhat.com>
14616 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
14618 * config/i386/sse.md
14619 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
14621 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
14623 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
14625 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
14627 (*<floatsuffix>floatv2div2sf2): Rename to ...
14628 (*float<floatunssuffix>v2div2sf2): ... this.
14629 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
14630 (float<floatunssuffix>v2div2sf2_mask): ... this.
14631 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
14632 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
14633 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
14635 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
14637 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
14639 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
14641 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
14643 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
14645 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
14646 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
14647 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
14648 gen_ufix_truncv8dfv8si2.
14649 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
14650 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
14651 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
14652 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
14653 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
14654 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
14655 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
14656 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
14658 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
14662 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
14664 2018-05-25 Jim Wilson <jimw@sifive.com>
14666 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
14667 * config/riscv/riscv.c (struct machine_function): Add
14668 interrupt_handler_p and attribute_checked_p fields.
14669 (riscv_attribute_table): Add interrupt.
14670 (riscv_interrupt_type_p): New.
14671 (riscv_save_reg_p): Save extra regs for interrupt handler.
14672 (riscv_use_save_libcall): Return false for interrupt handler.
14673 (riscv_first_stack_step): Add forward declaration.
14674 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
14675 for interrupt handler with large frame. Use it for saved reg list.
14676 (riscv_expand_prologue): Move flag_stack_usage_info support to
14677 eliminate duplication.
14678 (riscv_expand_epilogue): Generate mret for interrupt handler.
14679 (riscv_epilogue_uses): New.
14680 (riscv_can_use_return_insn): Return false for interrupt handler.
14681 (riscv_function_ok_for_sibcall): Likewise.
14682 (riscv_set_current_function): Add interrupt handler support.
14683 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
14684 * config/riscv/riscv.md (UNSPECV_MRET): New.
14686 (riscv_frflags, riscv_fsflags): Use tab after opcode.
14688 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
14690 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
14692 PR tree-optimization/85712
14693 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
14694 this candidate has already been replaced in-situ by a copy.
14696 2018-05-25 Jason Merrill <jason@redhat.com>
14698 PR c++/80485 - inline function non-zero address.
14699 * symtab.c (nonzero_address): Check DECL_COMDAT.
14701 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
14704 * config/alpha/alpha.md (ashlsi3): New insn pattern.
14705 (*ashlsi_se): Rename from *ashldi_se. Define as sign
14706 extension of SImode operation. Use const123_operand predicate.
14707 (*saddsi_1): Remove.
14708 (*saddl_se_1): Ditto.
14709 (*ssubsi_1): Ditto.
14710 (*ssubl_se_1): Ditto.
14711 * config/alpha/predicates.md (const123_operand): New predicate.
14712 * config/alpha/constraints.md (P): Use IN_RANGE.
14714 2018-05-25 Richard Biener <rguenther@suse.de>
14716 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
14718 (ref_maybe_used_by_stmt_p): Likewise.
14719 (stmt_may_clobber_ref_p): Likewise.
14720 (stmt_may_clobber_ref_p_1): Likewise.
14721 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
14723 (ref_maybe_used_by_stmt_p): Likewise.
14724 (stmt_may_clobber_ref_p): Likewise.
14725 (stmt_may_clobber_ref_p_1): Likewise.
14726 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
14727 the alias oracle to disambiguate DRs with stmts DR analysis
14729 (vect_analyze_data_refs): Do not give up on not analyzable
14730 DRs for BB vectorization. Remove code truncating the dataref
14733 2018-05-25 Jakub Jelinek <jakub@redhat.com>
14736 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
14737 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
14738 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
14740 2018-05-25 Richard Biener <rguenther@suse.de>
14742 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
14743 function, combining stmt data ref gathering and fatal analysis
14745 (vect_analyze_data_refs): Remove now redudnant code and simplify.
14746 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
14747 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
14748 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
14749 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
14751 2018-05-25 Bin Cheng <bin.cheng@arm.com>
14753 PR tree-optimization/85720
14754 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
14755 SCC if all partitions are builtins.
14756 (version_loop_by_alias_check): New parameter. Generate cancelable
14757 runtime alias check if all partitions are builtins.
14758 (distribute_loop): Update call to above function.
14760 2018-05-25 Bin Cheng <bin.cheng@arm.com>
14762 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
14763 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
14764 (parm_default_def_partition_arg): Ditto.
14765 (set_parm_default_def_partition): Ditto.
14766 (get_parm_default_def_partitions): Ditto and make it static.
14767 (get_undefined_value_partitions): Ditto and make it static.
14768 (remove_ssa_form): Refactor call to init_var_map here.
14769 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
14770 computation for loop region.
14771 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
14772 (register_default_def): Delete.
14773 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
14774 (parm_default_def_partition_arg): Ditto.
14775 (set_parm_default_def_partition): Ditto.
14776 (get_parm_default_def_partitions): Ditto and make it static.
14777 (get_undefined_value_partitions): Ditto and make it static.
14778 (coalesce_with_default, coalesce_with_default): Update comment.
14779 (create_coalesce_list_for_region): New func factored out from
14780 create_outofssa_var_map.
14781 (populate_coalesce_list_for_outofssa): New func factored out from
14782 create_outofssa_var_map and coalesce_ssa_name.
14783 (create_outofssa_var_map): Delete.
14784 (coalesce_ssa_name): Refactor to support live range computation.
14785 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
14786 (get_parm_default_def_partitions): Delete.
14787 (get_undefined_value_partitions): Ditto.
14788 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
14789 computation for loop region.
14790 (new_tree_live_info, loe_visit_block): Ditto.
14791 (live_worklist, set_var_live_on_entry): Ditto.
14792 (calculate_live_on_exit, verify_live_on_entry): Ditto.
14793 * tree-ssa-live.h (struct _var_map): New fields.
14794 (init_var_map): Change decl.
14795 (region_contains_p): New.
14797 2018-05-25 Bin Cheng <bin.cheng@arm.com>
14799 * tree-ssa-live.h (live_merge_and_clear): Delete.
14801 2018-05-25 Richard Biener <rguenther@suse.de>
14804 * tree-dump.c (dequeue_and_dump): Remove access to removed
14805 operand 2 of a SWITCH_EXPR.
14807 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14809 * doc/sourcebuild.texi (vect_double_cond_arith): Include
14810 multiplication and division.
14811 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
14812 (cond_udiv@var{m}, cond_umod@var{m}): Document.
14813 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
14814 (cond_udiv_optab, cond_umod_optab): New optabs.
14815 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
14816 (IFN_COND_RDIV): New internal functions.
14817 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
14818 TRUNC_MOD_EXPR and RDIV_EXPR.
14819 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
14820 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
14822 (SVE_INT_BINARY): Include mult.
14823 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
14824 (optab, sve_int_op): Handle mult.
14825 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
14827 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
14828 for SVE_INT_BINARY_SD.
14830 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14832 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
14833 (optab, sve_int_op): Handle div and udiv.
14834 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
14835 for SVE_INT_BINARY_SD.
14836 (*<optab><mode>3): New insn for the same.
14838 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14840 * tree-vect-patterns.c: Include predict.h.
14841 (vect_recog_divmod_pattern): Restrict check for division support
14842 to when optimizing for size.
14844 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14846 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
14847 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
14848 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
14849 (gimple_match_op::set_op): Likewise.
14850 (gimple_resimplify4): Declare.
14851 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
14852 (expr::gen_transform): Likewise.
14853 (decision_tree::gen): Generate a simplification routine for 4 operands.
14854 * gimple-match-head.c (gimple_simplify): Add an overload for
14855 4 operands. In the top-level function, handle up to 4 call
14856 arguments and call gimple_resimplify4.
14857 (gimple_resimplify4): New function.
14858 (build_call_internal): Pass a fourth operand.
14859 (maybe_push_to_seq): Likewise.
14860 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
14861 Fold VEC_COND_EXPRs of an operation and a default value into
14862 an IFN_COND_* function if possible.
14863 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
14865 (SVE_COND_FP_BINARY): Include them.
14866 (optab, sve_fp_op): Handle them.
14867 (SVE_INT_BINARY_REV): New code iterator.
14868 (SVE_COND_FP_BINARY_REV): New int iterator.
14869 (commutative): New int attribute.
14870 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
14872 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
14874 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
14875 (*cond_<optab><mode>): New patterns for reversed operands.
14877 2018-05-25 Richard Biener <rguenther@suse.de>
14879 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
14880 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
14881 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
14882 (STMT_VINFO_GROUPED_ACCESS): Adjust.
14883 * tree-vect-data-refs.c (everywhere): Adjust users.
14884 * tree-vect-loop.c (everywhere): Likewise.
14885 * tree-vect-slp.c (everywhere): Likewise.
14886 * tree-vect-stmts.c (everywhere): Likewise.
14887 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
14889 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
14891 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
14893 (gcc_cv_as_section_exclude): ... this.
14894 Try Solaris as #exclude syntax.
14895 * configure: Regenerate.
14896 * config.in: Regenerate.
14897 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
14899 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
14900 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
14902 * varasm.c (default_elf_asm_named_section): Don't check if
14903 HAVE_GAS_SECTION_EXCLUDE is defined.
14905 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14907 * doc/md.texi: Update the documentation of the cond_* optabs
14908 to mention the new final operand. Fix GET_MODE_NUNITS call.
14909 Describe the scalar case too.
14910 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
14911 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
14913 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
14914 (get_conditional_internal_fn): Update comment.
14915 * tree-vect-loop.c (vectorizable_reduction): Pass the original
14916 accumulator value as a final argument to conditional functions.
14917 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
14918 a define_expand and add an "else" operand. Assert for now that
14919 the else operand is equal to operand 2. Use SVE_INT_BINARY and
14920 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
14921 (*cond_<optab><mode>): New patterns.
14922 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
14923 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
14924 (UNSPEC_COND_EOR): Delete.
14925 (optab): Remove associated mappings.
14926 (SVE_INT_BINARY): New code iterator.
14927 (sve_int_op): Remove int attribute and add "minus" to the code
14929 (SVE_COND_INT_OP): Delete.
14930 (SVE_COND_FP_OP): Rename to...
14931 (SVE_COND_FP_BINARY): ...this.
14933 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
14935 * optabs.c (can_reuse_operands_p): New function.
14936 (maybe_legitimize_operands): Try to reuse the results for
14939 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
14941 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
14942 Add {q} suffix to insn mnemonic.
14944 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14946 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
14947 (msp430_warn_func_return): New.
14949 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
14951 * fold-const.c (tree_nonzero_bits): New function.
14952 * fold-const.h (tree_nonzero_bits): Likewise.
14953 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
14954 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
14956 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
14960 * varasm.c (assemble_alias): Check ifunc_resolver only on
14963 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
14966 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
14967 when memory input operand is handled.
14969 2018-05-24 Luis Machado <luis.machado@linaro.org>
14971 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
14973 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
14975 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
14977 * match.pd: Delay FMA folds until after vectorization.
14979 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
14982 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
14983 address check not strict.
14985 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
14987 * gimple-match.h (gimple_match_op): New class.
14988 (mprts_hook): Replace parameters with a gimple_match_op *.
14989 (maybe_build_generic_op): Likewise.
14990 (gimple_simplified_result_is_gimple_val): Replace parameters with
14991 a const gimple_match_op *.
14992 (gimple_simplify): Replace code_helper * and tree * parameters with
14993 a gimple_match_op * parameter.
14994 (gimple_resimplify1): Replace code_helper *, tree and tree *
14995 parameters with a gimple_match_op * parameter.
14996 (gimple_resimplify2): Likewise.
14997 (gimple_resimplify3): Likewise.
14998 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
14999 parameters with a gimple_match_op * parameter.
15000 * gimple-match-head.c (gimple_simplify): Change prototypes of
15001 auto-generated functions to take a gimple_match_op * instead of
15002 separate code_helper * and tree * parameters. Make the same
15003 change in the top-level overload and update calls to the
15004 gimple_resimplify routines. Update calls to the auto-generated
15005 functions and to maybe_push_res_to_seq in the publicly-facing
15006 operation-specific gimple_simplify overloads.
15007 (gimple_match_op::MAX_NUM_OPS): Define.
15008 (gimple_resimplify1): Replace rcode and ops with a single res_op
15009 parameter. Update call to gimple_simplify.
15010 (gimple_resimplify2): Likewise.
15011 (gimple_resimplify3): Likewise.
15012 (mprts_hook): Replace parameters with a gimple_match_op *.
15013 (maybe_build_generic_op): Likewise.
15014 (build_call_internal): Replace type, nargs and ops with
15015 a gimple_match_op *.
15016 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
15017 with a single gimple_match_op *. Update calls to mprts_hook,
15018 build_call_internal and gimple_simplified_result_is_gimple_val.
15019 Factor out code that is common to the tree_code and combined_fn cases.
15020 * genmatch.c (expr::gen_transform): Replace tem_code and
15021 tem_ops with a gimple_match_op called tem_op. Update calls
15022 to the gimple_resimplify functions and maybe_push_res_to_seq.
15023 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
15024 res_ops. Update call to the gimple_resimplify functions.
15025 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
15026 (decision_tree::gen): Make the functions take a gimple_match_op *
15027 called res_op instead of separate res_code and res_ops parameters.
15028 Update call accordingly.
15029 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
15030 and ops with a single res_op parameter. Update calls to
15031 maybe_build_generic_op and maybe_push_res_to_seq.
15032 (fold_stmt_1): Update calls to gimple_simplify and
15033 replace_stmt_with_simplification.
15034 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
15035 and gimple_simplified_result_is_gimple_val.
15036 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
15038 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
15039 with a gimple_match_op *.
15040 (vn_nary_build_or_lookup): Likewise. Update call to
15041 vn_nary_build_or_lookup_1.
15042 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
15043 gimple_match_op *. Update calls to the gimple_resimplify routines
15044 and to gimple_simplified_result_is_gimple_val.
15045 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
15046 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
15047 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
15048 (visit_nary_op): Likewise.
15049 (visit_reference_op_load): Likewise.
15051 2018-05-23 Luis Machado <luis.machado@linaro.org>
15053 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
15054 modifier for printing the step amount.
15056 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
15059 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
15062 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
15064 * doc/sourcebuild.texi (Endianness): New subsubsection.
15066 2018-05-23 Luis Machado <luis.machado@linaro.org>
15068 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
15069 <prefetch_dynamic_strides>: New const bool field.
15070 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
15071 prefetch_dynamic_strides.
15072 (exynosm1_prefetch_tune): Likewise.
15073 (thunderxt88_prefetch_tune): Likewise.
15074 (thunderx_prefetch_tune): Likewise.
15075 (thunderx2t99_prefetch_tune): Likewise.
15076 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
15078 (aarch64_override_options_internal): Update to set
15079 PARAM_PREFETCH_DYNAMIC_STRIDES.
15080 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
15081 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
15082 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
15083 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
15084 prefetch-dynamic-strides setting.
15086 2018-05-23 Luis Machado <luis.machado@linaro.org>
15088 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
15089 <minimum_stride>: New const int field.
15090 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
15091 minimum_stride field defaulting to -1.
15092 (exynosm1_prefetch_tune): Likewise.
15093 (thunderxt88_prefetch_tune): Likewise.
15094 (thunderx_prefetch_tune): Likewise.
15095 (thunderx2t99_prefetch_tune): Likewise.
15096 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
15097 <default_opt_level>: Set to 3.
15098 (aarch64_override_options_internal): Update to set
15099 PARAM_PREFETCH_MINIMUM_STRIDE.
15100 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
15101 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
15102 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
15103 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
15104 stride is constant and is below the minimum stride threshold.
15106 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15108 * config/arm/arm-cpus.in (mode26): Delete.
15109 (armv4): Delete mode26 reference.
15110 * config/arm/arm.c (arm_configure_build_target): Delete use of
15113 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
15115 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
15117 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
15118 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
15120 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
15121 (floatunsdidf2): Ditto.
15123 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
15125 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
15126 (fixuns_trunc<mode>si2_avx512f): Ditto.
15127 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
15128 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
15129 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
15131 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
15133 PR rtl-optimization/79985
15134 * df-scan.c (df_insn_refs_collect): Remove special case for
15135 global registers and asm statements.
15137 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
15139 * extend.texi (Global Register Variables): Rewrite the bullet list.
15140 Note that the register is available for allocation. Note that access
15141 via inline asm must use constraints. Add note about async-signal
15142 handlers. Remove paragraph about automagic register selection.
15144 2018-05-23 Richard Biener <rguenther@suse.de>
15146 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
15147 of fixed offset from memset VN.
15149 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
15151 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
15152 first_interp field.
15153 (alloc_cand_and_find_basis): Initialize first_interp field.
15154 (slsr_process_mul): Modify first_interp field.
15155 (slsr_process_add): Likewise.
15156 (slsr_process_cast): Modify first_interp field for each new
15158 (slsr_process_copy): Likewise.
15159 (dump_candidate): Dump first_interp field.
15160 (replace_mult_candidate): Process all interpretations, not just
15162 (replace_rhs_if_not_dup): Likewise.
15163 (replace_one_candidate): Likewise.
15165 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
15167 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
15169 (aarch64_needs_frame_chain): New function.
15170 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
15172 2018-05-23 Sudakshina Das <sudi.das@arm.com>
15175 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
15176 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
15177 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
15178 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
15179 as true for strict-align.
15180 (aarch64_can_inline_p): Perform checks even when callee has no
15181 attributes to check for strict alignment.
15182 * doc/extend.texi (AArch64 Function Attributes): Document
15184 * doc/invoke.texi: (AArch64 Options): Likewise.
15186 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
15188 PR tree-optimization/85853
15189 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
15190 the handling of the root of the node to...
15191 (vect_slp_analyze_node_operations_1): ...this new function,
15192 and run the whole thing with the child nodes' def types
15193 set according to their SLP node's def type.
15195 2018-05-23 Richard Biener <rguenther@suse.de>
15197 PR middle-end/85874
15198 * tree-data-ref.c (create_runtime_alias_checks): Defer
15199 and ignore overflow warnings.
15201 2018-05-23 Yury Gribov <tetra2005@gmail.com>
15203 PR tree-optimization/85822
15204 * tree-vrp.c (is_masked_range_test): Fix handling of negative
15207 2018-05-23 Richard Biener <rguenther@suse.de>
15209 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
15210 memset constants via native_interpret_expr.
15212 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
15215 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
15217 (cgraph_node::create_alias): Likewise.
15218 (cgraph_node::get_availability): Check ifunc_resolver instead
15219 of looking up ifunc attribute.
15220 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
15221 * varasm.c (do_assemble_alias): Likewise.
15222 (assemble_alias): Likewise.
15223 (default_binds_local_p_3): Likewise.
15224 * cgraph.h (cgraph_node): Add ifunc_resolver.
15225 (cgraph_node::only_called_directly_or_aliased_p): Return false
15226 for IFUNC resolver.
15227 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
15229 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
15230 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
15231 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
15232 instead of looking up ifunc attribute.
15234 2018-05-22 Luis Machado <luis.machado@linaro.org>
15236 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
15238 2018-05-22 Martin Sebor <msebor@redhat.com>
15240 PR middle-end/85359
15241 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
15242 only when expasion succeeds.
15243 (expand_builtin_strcmp): Same.
15244 (expand_builtin_strncmp): Same.
15246 2018-05-22 Martin Sebor <msebor@redhat.com>
15248 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
15250 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
15251 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15253 * config/aarch64/aarch64-ldpstp.md: Replace uses of
15254 aarch64_mem_pair_operand with memory_operand and delete operand swapping
15256 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
15257 Add check for legitimate_address.
15258 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
15259 (aarch64_swap_ldrstr_operands): New.
15260 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
15263 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
15264 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15266 * config/aarch64/aarch64.md: New patterns to generate stp
15268 (store_pair_sw, store_pair_dw): New patterns to generate stp for
15269 single words and double words.
15270 (load_pair_sw, load_pair_dw): Likewise.
15271 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
15273 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
15275 * config/aarch64/aarch64-ldpstp.md: Modify peephole
15276 for different mode ldpstp and add peephole for merged zero stores.
15277 Likewise for loads.
15278 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
15280 (aarch64_gen_store_pair): Rename calls to match new patterns.
15281 (aarch64_gen_load_pair): Rename calls to match new patterns.
15282 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
15283 (load_pair<DREG:mode><DREG2:mode>): ... This.
15284 (store_pair<mode>): Rename to...
15285 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
15286 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
15287 New mode iterators.
15288 (V_INT_EQUIV): Handle SImode.
15289 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
15292 2018-05-22 Martin Sebor <msebor@redhat.com>
15295 * calls.c (maybe_warn_nonstring_arg): Use string length to set
15296 or ajust the presumed bound on an operation to avoid unnecessary
15299 2018-05-22 Martin Sebor <msebor@redhat.com>
15301 PR tree-optimization/85826
15302 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
15303 assuming that a DECL necesarily has a constant size.
15305 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
15307 PR middle-end/85862
15308 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
15310 2018-05-22 Richard Biener <rguenther@suse.de>
15312 PR tree-optimization/85834
15313 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
15314 non-constant and non-zero memset arguments.
15316 2018-05-22 Martin Liska <mliska@suse.cz>
15319 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
15321 2018-05-22 Richard Biener <rguenther@suse.de>
15323 PR tree-optimization/85863
15324 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
15325 comparisons when vectype is specified.
15326 (vectorizable_condition): Do not specify vectype for
15327 vect_is_simple_cond when SLP vectorizing.
15329 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
15332 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
15333 define __ibm128 as long double.
15334 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
15335 as a distinct type when IEEE 128-bit support is enabled.
15336 (init_float128_ieee): Fix up conversions between IFmode and IEEE
15337 128-bit types to use the correct functions.
15338 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
15339 convert between 128-bit floating point types that have different
15340 modes but the same representation, instead of using gen_lowpart to
15342 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
15344 (IFKF_reg): New attributes to give the register constraints for
15346 (extend<mode>tf2_internal): New insns to mark an explicit
15347 conversion between 128-bit floating point types that have a
15348 different mode but share the same representation.
15350 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
15352 PR tree-optimization/85814
15353 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
15354 a null return from get_strinfo when unsharing the next
15355 strinfo in the chain.
15357 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
15360 * varasm.c (weak_finish): Clean up weak_decls.
15362 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15364 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
15365 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
15366 UNSPEC_UADALP values.
15367 * config/aarch64/iterators.md (ABAL): New int iterator.
15370 (sur): Add mappings for the above.
15371 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
15373 (aarch64_<sur>abal<mode>_4): Likewise.
15374 (aarch64_<sur>adalp<mode>_3): Likewise.
15375 (<sur>sadv16qi): New define_expand.
15377 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
15379 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
15380 (*movdf_internal): Ditto.
15381 (*rcpsf2_sse): Ditto.
15382 (*rsqrtsf2_sse): Ditto.
15383 (*sqrt<mode>2_sse): Ditto.
15385 2018-05-21 Tamar Christina <tamar.christina@arm.com>
15387 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
15389 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
15390 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
15391 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
15392 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
15394 * config/aarch64/arm_neon.h: Likewise.
15395 * config/aarch64/iterators.md (VQ_I): New.
15397 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
15399 * config.gcc: Add arc/t-multilib-linux to tmake_file for
15401 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
15404 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
15406 * config/nds32/constraints.md (S): New constraint.
15407 * config/nds32/nds32.md (call_internal): Use constraint S.
15408 (call_value_internal): Likewise.
15409 (sibcall_internal): Likewise.
15410 (sibcall_value_internal): Likewise.
15412 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
15413 Chung-Ju Wu <jasonwucj@gmail.com>
15415 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
15416 into consideration.
15418 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
15419 Chung-Ju Wu <jasonwucj@gmail.com>
15421 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
15422 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
15423 (nds32_rtx_costs_impl): Simplify.
15424 (nds32_address_cost_impl): Simplify.
15425 (nds32_init_rtx_costs): New function.
15426 (nds32_rtx_costs_speed_prefer): Likewise.
15427 (nds32_rtx_costs_size_prefer): Likewise.
15428 (nds32_address_cost_speed_prefer): Likewise.
15429 (nds32_address_cost_speed_fwprop): Likewise.
15430 (nds32_address_cost_size_prefer): Likewise.
15431 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
15432 * config/nds32/nds32.c (nds32_option_override): Use
15433 nds32_init_rtx_costs function.
15435 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
15437 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
15438 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
15439 (TARGET_PIPELINE_N8): Likewise.
15440 (TARGET_PIPELINE_N10): Likewise.
15441 (TARGET_PIPELINE_N13): Likewise.
15442 (TARGET_PIPELINE_GRAYWOLF): Likewise.
15444 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
15446 * config/nds32/nds32-fpu.md: Update copyright year.
15448 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15450 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
15452 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15454 * config/nds32/nds32.c
15455 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
15456 * config/nds32/nds32.opt (minline-asm-r15): New option.
15458 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15460 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
15462 * config/nds32/nds32.md (abssi2): New pattern.
15464 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
15466 * config/i386/i386.md (rex64namesuffix): New mode attribute.
15467 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
15468 Merge insn pattern from sse_cvtsi2ss<round_name> and
15469 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
15470 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
15471 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
15472 using SWI48 mode iterator.
15473 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
15474 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
15475 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
15476 pattern from sse_cvttss2si<round_saeonly_name>
15477 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
15478 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
15479 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
15480 using SWI48 mode iterator.
15481 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
15482 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
15483 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
15484 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
15485 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
15486 using SWI48 mode iterator.
15487 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
15488 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
15489 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
15490 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
15491 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
15492 SWI48 mode iterator.
15493 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
15494 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
15495 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
15496 pattern from sse_cvttsd2si<round_saeonly_name>
15497 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
15499 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15501 * config/nds32/nds32-md-auxiliary.c
15502 (nds32_valid_smw_lwm_base_p): Refine.
15503 (nds32_output_smw_single_word): Refine.
15504 (nds32_output_smw_double_word): New.
15505 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
15507 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15509 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
15510 (nds32_output_stack_pop): Refine.
15511 (nds32_expand_unaligned_load): Refine.
15512 (nds32_expand_unaligned_store): Refine.
15514 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
15515 Chung-Ju Wu <jasonwucj@gmail.com>
15517 * config/nds32/constants.md: Add TP_REGNUM constant.
15518 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
15519 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
15521 * config/nds32/nds32-doubleword.md: Consider flag_pic.
15522 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
15523 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
15524 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
15525 and PIC code generation.
15526 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
15528 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
15530 * config/nds32/nds32.md: Support TLS and PIC.
15531 * config/nds32/nds32.c: Support TLS and PIC.
15532 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
15533 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
15536 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
15538 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
15539 mode with E_ prefix.
15541 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
15542 Chung-Ju Wu <jasonwucj@gmail.com>
15544 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
15545 * config/nds32/nds32-md-auxiliary.c
15546 (symbolic_reference_mentioned_p): New.
15547 (nds32_legitimize_ict_address): New.
15548 (nds32_expand_ict_move): New.
15549 (nds32_indirect_call_referenced_p): New.
15550 (nds32_symbol_binds_local_p): Delete.
15551 (nds32_long_call_p): Modify.
15552 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
15553 * config/nds32/nds32-protos.h
15554 (symbolic_reference_mentioned_p): Declare.
15555 (nds32_legitimize_ict_address): Declare.
15556 (nds32_expand_ict_move): Declare.
15557 (nds32_indirect_call_referenced_p): Declare.
15558 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
15559 (nds32_relax_group): Use nds32_ict_const_p as condition.
15560 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
15561 (nds32_asm_file_start): Output ict_model directive in asm code.
15562 (nds32_legitimate_address_p): Consider indirect call.
15563 (nds32_print_operand): Consider indirect call.
15564 (nds32_print_operand_address): Consider indirect call.
15565 (nds32_insert_attributes): Handle "indirect_call" attribute.
15566 (TARGET_LEGITIMATE_ADDRESS_P): Define.
15567 (TARGET_LEGITIMATE_CONSTANT_P): Define.
15568 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
15569 (TARGET_DELEGITIMIZE_ADDRESS): Define.
15570 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
15571 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
15572 (TARGET_ICT_MODEL_SMALL): Define.
15573 (TARGET_ICT_MODEL_LARGE): Define.
15574 * config/nds32/nds32.md (movsi): Consider ict model.
15575 (call, call_value): Consider ict model.
15576 (sibcall, sibcall_value): Consider ict model.
15577 * config/nds32/nds32.opt (mict-model): New option.
15578 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
15581 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
15582 Monk Chiang <sh.chiang04@gmail.com>
15583 Jim Wilson <jimw@sifive.com>
15585 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
15586 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
15587 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
15588 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
15589 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
15590 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
15591 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
15592 compute save_libcall_adjustment properly.
15593 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
15594 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
15595 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
15596 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
15597 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
15598 (ABI_SPEC): Handle mabi=ilp32e.
15599 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
15600 (RVE): Add RVE mask.
15601 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
15602 <-march>: Add rv32e as an example.
15604 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
15607 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
15608 (intra_create_variable_infos): Handle C++ constructors.
15610 2018-05-18 Martin Liska <mliska@suse.cz>
15612 * passes.def: Remove a redundant pass.
15614 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
15617 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
15619 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15621 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
15623 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
15625 (armv2, armv2a, armv3, armv3m): Delete architectures.
15626 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
15627 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
15628 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
15630 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
15631 (*mulsidi3adddi): Likewise.
15632 (mulsidi3): Likewise.
15633 (*mulsidi3_nov6): Likewise.
15634 (umulsidi3): Likewise.
15635 (umulsidi3_nov6): Likewise.
15636 (umaddsidi4): Likewise.
15637 (*umulsidi3adddi): Likewise.
15638 (smulsi3_highpart): Likewise.
15639 (*smulsi3_highpart_nov6): Likewise.
15640 (umulsi3_highpart): Likewise.
15641 (*umulsi3_highpart_nov6): Likewise.
15642 * config/arm/arm.h (arm_arch3m): Delete.
15643 * config/arm/arm.c (arm_arch3m): Delete.
15644 (arm_option_override_internal): Update armv3-related comment.
15645 (arm_configure_build_target): Delete use of isa_bit_mode32.
15646 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
15647 (arm_rtx_costs_internal): Delete check of arm_arch3m.
15648 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
15649 (mulsa3): Likewise.
15650 (mulusa3): Likewise.
15651 * config/arm/arm-protos.h (arm_arch3m): Delete.
15652 * config/arm/arm-tables.opt: Regenerate.
15653 * config/arm/arm-tune.md: Likewise.
15654 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
15655 deleted architectures.
15657 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15659 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
15660 (armv5t, armv5te): New features.
15661 (ARMv5, ARMv5e): Delete fgroups.
15662 (ARMv5t, ARMv5te): Adjust for above changes.
15663 (ARMv6m): Likewise.
15664 (armv5, armv5e): Delete arches.
15665 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
15667 (*call_reg_arm): Likewise.
15668 (*call_value_reg_armv5): Likewise.
15669 (*call_value_reg_arm): Likewise.
15670 (*call_symbol): Likewise.
15671 (*call_value_symbol): Likewise.
15672 (*sibcall_insn): Likewise.
15673 (*sibcall_value_insn): Likewise.
15674 (clzsi2): Likewise.
15675 (prefetch): Likewise.
15676 (define_split and define_peephole2 dependent on arm_arch5):
15678 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
15680 (TARGET_ARM_QBIT): Likewise.
15681 (TARGET_DSP_MULTIPLY): Likewise.
15682 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
15683 (arm_arch5, arm_arch5e): Delete.
15684 (arm_arch5t, arm_arch5te): Declare.
15685 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
15686 (arm_arch5t): Declare.
15687 (arm_option_reconfigure_globals): Update for the above.
15688 (arm_options_perform_arch_sanity_checks): Update comment, replace
15689 use of arm_arch5 with arm_arch5t.
15690 (use_return_insn): Likewise.
15691 (arm_emit_call_insn): Likewise.
15692 (output_return_instruction): Likewise.
15693 (arm_final_prescan_insn): Likewise.
15694 (arm_coproc_builtin_available): Likewise.
15695 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
15696 arm_arch5e with arm_arch5t and arm_arch5te.
15697 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
15698 (arm_arch5t, arm_arch5te): Declare.
15699 * config/arm/arm-tables.opt: Regenerate.
15700 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
15701 * config/arm/t-multilib: Likewise.
15702 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
15703 instead of arm_arch5.
15704 (*call_reg_thumb1): Likewise.
15705 (*call_value_reg_thumb1_v5): Likewise.
15706 (*call_value_reg_thumb1): Likewise.
15707 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
15709 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
15711 2018-05-18 Martin Liska <mliska@suse.cz>
15713 PR gcov-profile/84846
15714 * doc/gcov.texi: Document -t option of gcov tool.
15716 2018-05-18 Martin Liska <mliska@suse.cz>
15718 PR gcov-profile/84846
15719 * gcov.c (print_usage): Add new -t option.
15720 (process_args): Handle the option.
15721 (generate_results): Use stdout as output when requested by
15724 2018-05-18 Martin Liska <mliska@suse.cz>
15726 PR gcov-profile/84846
15727 * coverage.c (coverage_init): Write PWD to .gcno file.
15728 * doc/gcov.texi: Document how working directory is printed.
15729 * gcov-dump.c (dump_gcov_file): Print PWD.
15730 * gcov.c (output_intermediate_file): Likewise.
15731 (read_graph_file): Read PWD string.
15732 (output_lines): Print PWD.
15734 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
15736 PR middle-end/85817
15737 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
15738 for retval and return false if all args to phi are zero.
15740 2018-05-18 Richard Biener <rguenther@suse.de>
15742 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
15744 (evrp_dom_walker::before_dom_children): Call it.
15746 2018-05-18 Richard Biener <rguenther@suse.de>
15748 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
15749 results when processing array refs with variable index.
15751 2018-05-18 Toon Moene <toon@moene.org>
15753 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
15754 directly after that of -floop-interchange. Indicate that both
15755 options are enabled by default when specifying -O3.
15757 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15759 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
15760 iterator. Delete separate integer-mode vec_set<mode> expander.
15761 (aarch64_simd_vec_setv2di): Delete.
15762 (vec_setv2di): Delete.
15763 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
15764 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
15765 the "w, r" alternative.
15767 2018-05-18 Martin Liska <mliska@suse.cz>
15769 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
15770 * tree-pass.h (make_pass_lower_switch_O0): New function.
15771 * tree-switch-conversion.c (node_has_low_bound): Remove.
15772 (node_has_high_bound): Likewise.
15773 (node_is_bounded): Likewise.
15774 (class pass_lower_switch): Make it a template type and create
15776 (pass_lower_switch::execute): Add template argument.
15777 (make_pass_lower_switch): New function.
15778 (make_pass_lower_switch_O0): New function.
15779 (do_jump_if_equal): Remove.
15780 (emit_case_nodes): Simplify to just handle all 3 cases and leave
15781 all the hard work to tree optimization passes.
15783 2018-05-18 Martin Liska <mliska@suse.cz>
15785 * dbgcnt.c (limit_low): Renamed from limit.
15786 (limit_high): New variable.
15787 (dbg_cnt_is_enabled): Check for upper limit.
15788 (dbg_cnt): Adjust dumping.
15789 (dbg_cnt_set_limit_by_index): Add new argument for high
15791 (dbg_cnt_set_limit_by_name): Likewise.
15792 (dbg_cnt_process_single_pair): Parse new format.
15793 (dbg_cnt_process_opt): Use strtok.
15794 (dbg_cnt_list_all_counters): Remove 'value' and add
15796 * doc/invoke.texi: Document changes.
15798 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
15800 * doc/sourcebuild.texi (scalar_all_fma): Document.
15801 * tree.def (FMA_EXPR): Delete.
15802 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
15803 * internal-fn.c (ternary_direct): New macro.
15804 (expand_ternary_optab_fn): Likewise.
15805 (direct_ternary_optab_supported_p): Likewise.
15806 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
15807 * builtins.c (fold_builtin_fma): Delete.
15808 (fold_builtin_3): Don't call it.
15809 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
15810 * expr.c (expand_expr_real_2): Likewise.
15811 * fold-const.c (operand_equal_p): Likewise.
15812 (fold_ternary_loc): Likewise.
15813 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
15814 * gimple.c (DEFTREECODE): Likewise.
15815 * gimplify.c (gimplify_expr): Likewise.
15816 * optabs-tree.c (optab_for_tree_code): Likewise.
15817 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
15818 * tree-eh.c (operation_could_trap_p): Likewise.
15819 (stmt_could_throw_1_p): Likewise.
15820 * tree-inline.c (estimate_operator_cost): Likewise.
15821 * tree-pretty-print.c (dump_generic_node): Likewise.
15822 (op_code_prio): Likewise.
15823 * tree-ssa-loop-im.c (stmt_cost): Likewise.
15824 * tree-ssa-operands.c (get_expr_operands): Likewise.
15825 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
15826 * fold-const-call.h (fold_fma): Delete.
15827 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
15828 CFN_FNMA and CFN_FNMS.
15829 (fold_fma): Delete.
15830 * genmatch.c (combined_fn): New enum.
15831 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
15832 (commutative_op): New function.
15833 (commutate): Use it. Handle more than 2 operands.
15834 (dt_operand::gen_gimple_expr): Use commutative_op.
15835 (parser::parse_expr): Allow :c to be used with non-binary
15836 operators if the commutative operand is known.
15837 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
15838 CFN_FMS, CFN_FNMA and CFN_FNMS.
15839 (backprop::process_assign_use): Remove FMA_EXPR handling.
15840 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
15841 (gen_hsa_fma): New function.
15842 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
15843 IFN_FNMA and IFN_FNMS.
15844 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
15845 * gimple-fold.h (follow_all_ssa_edges): Declare.
15846 * gimple-fold.c (follow_all_ssa_edges): New function.
15847 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
15848 gimple_build interface and use follow_all_ssa_edges to fold the result.
15849 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
15850 instead of checking for optabs directly.
15851 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
15852 rather than FMA_EXPRs.
15853 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
15854 call to IFN_FMA instead of an FMA_EXPR.
15856 2018-05-17 Jim Wilson <jimw@sifive.com>
15858 * expr.c (do_tablejump): When converting index to Pmode, if we have a
15859 sign extended promoted subreg, and the range does not have the sign bit
15860 set, then do a sign extend.
15862 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
15863 test, check for sign extended subreg and/or constant operands, and
15864 do a sign extend in that case.
15866 2018-05-17 Steve Ellcey <sellcey@cavium.com>
15868 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
15869 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
15871 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
15872 Change logics_shift_reg to logics_shift_imm.
15873 (thunderx2t99_fp_loadpair_basic): Delete.
15874 (thunderx2t99_fp_storepair_basic): Delete.
15875 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
15876 (thunderx2t99_asimd_polynomial): Delete.
15877 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
15878 and neon_fp_mul_d_scalar_q.
15879 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
15880 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
15881 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
15882 (thunderx2t99_asimd_lut): Add missing tbl types.
15883 (thunderx2t99_asimd_ext): Delete.
15884 (thunderx2t99_asimd_load1_1_mult): Delete.
15885 (thunderx2t99_asimd_load1_2_mult): Delete.
15886 (thunderx2t99_asimd_load1_ldp): New.
15887 (thunderx2t99_asimd_load1): New.
15888 (thunderx2t99_asimd_load2): Add missing *load2* types.
15889 (thunderx2t99_asimd_load3): New.
15890 (thunderx2t99_asimd_load4): New.
15891 (thunderx2t99_asimd_store1_1_mult): Delete.
15892 (thunderx2t99_asimd_store1_2_mult): Delete.
15893 (thunderx2t99_asimd_store2_mult): Delete.
15894 (thunderx2t99_asimd_store2_onelane): Delete.
15895 (thunderx2t99_asimd_store_stp): New.
15896 (thunderx2t99_asimd_store1): New.
15897 (thunderx2t99_asimd_store2): New.
15898 (thunderx2t99_asimd_store3): New.
15899 (thunderx2t99_asimd_store4): New.
15901 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
15903 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
15904 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
15906 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
15907 Segher Boessenkool <segher@kernel.crashing.org>
15910 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
15913 2018-05-17 Richard Biener <rguenther@suse.de>
15915 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
15916 for pruning loop and prune defs feeding only already visited PHIs.
15918 2018-05-17 Richard Biener <rguenther@suse.de>
15920 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
15922 2018-05-17 Bin Cheng <bin.cheng@arm.com>
15923 Richard Biener <rguenther@suse.de>
15925 PR tree-optimization/85793
15926 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
15927 for VMAT_ELEMENTWISE.
15929 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
15931 * internal-fn.h (lookup_internal_fn): Declare
15932 * internal-fn.c (lookup_internal_fn): New function.
15933 * gimple.c (gimple_build_call_from_tree): Handle calls to
15934 internal functions.
15935 * gimple-pretty-print.c (dump_gimple_call): Print "." before
15936 internal function names.
15937 * tree-pretty-print.c (dump_generic_node): Likewise.
15938 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
15940 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
15942 * gimple-fold.h (gimple_build): Make the function forms take
15943 combined_fn rather than built_in_function.
15944 (gimple_simplify): Likewise.
15945 * gimple-match-head.c (gimple_simplify): Likewise.
15946 * gimple-fold.c (gimple_build): Likewise.
15947 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
15948 rather than gimple_build_call_internal.
15949 (get_initial_defs_for_reduction): Likewise.
15950 (vect_create_epilog_for_reduction): Likewise.
15951 (vectorizable_live_operation): Likewise.
15953 2018-05-17 Martin Liska <mliska@suse.cz>
15955 * gimple-ssa-sprintf.c (format_directive): Do not use
15956 space in between 'G_' and '('.
15958 2018-05-17 Jakub Jelinek <jakub@redhat.com>
15961 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
15962 even if the mask is not all ones.
15965 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
15967 (ix86_gimple_fold_builtin): Likewise.
15970 * config/i386/i386.c: Include tree-vector-builder.h.
15971 (ix86_vector_shift_count): New function.
15972 (ix86_fold_builtin): Fold shift builtins by scalar count.
15973 (ix86_gimple_fold_builtin): Likewise.
15975 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
15976 _mm512_setzero): New intrinsics.
15978 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
15979 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15981 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
15982 code generation for cases where splatting a value is not useful.
15983 * simplify-rtx.c (simplify_ternary_operation): Simplify
15984 vec_merge across a vec_duplicate and a paradoxical subreg forming
15985 a vector mode to a vec_concat.
15987 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
15989 * config.gcc: Support "goldmont-plus".
15990 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
15992 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
15993 PROCESSOR_GOLDMONT_PLUS.
15994 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
15995 (processor_target_table): Add "goldmont-plus".
15996 (PTA_GOLDMONT_PLUS): Define.
15997 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
15998 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
15999 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
16000 (fold_builtin_cpu): Add "goldmont-plus".
16001 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
16002 (ix86_option_override_internal): Add "goldmont-plus".
16003 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
16004 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
16005 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
16006 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
16008 2018-05-17 Richard Biener <rguenther@suse.de>
16010 PR tree-optimization/85757
16011 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
16012 remove defs that only feed that PHI from further processing.
16014 2018-05-16 Jim Wilson <jimw@sifive.com>
16016 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
16018 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
16020 2018-05-16 Mark Wielaard <mark@klomp.org>
16022 * dwarf2out.c (count_index_strings): New function.
16023 (output_indirect_strings): Call count_index_strings and generate
16024 header for dwarf_version >= 5.
16026 2018-05-16 Mark Wielaard <mark@klomp.org>
16028 * dwarf2out.c (dwarf_FORM): New function.
16029 (set_indirect_string): Use dwarf_FORM.
16030 (reset_indirect_string): Likewise.
16031 (size_of_die): Likewise.
16032 (value_format): Likewise.
16033 (output_die): Likewise.
16034 (add_skeleton_AT_string): Likewise.
16035 (output_macinfo_op): Likewise.
16036 (index_string): Likewise.
16037 (output_index_string_offset): Likewise.
16038 (output_index_string): Likewise.
16039 (count_index_strings): Likewise.
16041 2018-05-16 Carl Love <cel@us.ibm.com>
16043 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
16044 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
16046 2018-05-16 Martin Jambor <mjambor@suse.cz>
16048 * ipa-prop.c (ipa_free_all_edge_args): Remove.
16049 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
16051 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
16053 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
16054 (fnma<mode>4): Likewise.
16055 (fms<mode>4): Likewise.
16056 (fnms<mode>4): Likewise.
16057 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
16058 (aarch64_fnma<mode>4): Likewise.
16059 (aarch64_fms<mode>4): Likewise.
16060 (aarch64_fnms<mode>4): Likewise.
16061 (aarch64_fnmadd<mode>4): Likewise.
16063 2018-05-16 Jason Merrill <jason@redhat.com>
16065 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
16067 2018-05-16 Richard Biener <rguenther@suse.de>
16069 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
16070 (dump_stmt_cost): Declare.
16071 (add_stmt_cost): Dump cost we add.
16072 (add_stmt_costs): New function.
16073 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
16074 No longer exported.
16075 (vect_analyze_stmt): Adjust prototype.
16076 (vectorizable_condition): Likewise.
16077 (vectorizable_live_operation): Likewise.
16078 (vectorizable_reduction): Likewise.
16079 (vectorizable_induction): Likewise.
16080 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
16081 cost vector to pass to vectorizable_ and record afterwards.
16082 (vect_model_reduction_cost): Take cost vector argument and adjust.
16083 (vect_model_induction_cost): Likewise.
16084 (vectorizable_reduction): Likewise.
16085 (vectorizable_induction): Likewise.
16086 (vectorizable_live_operation): Likewise.
16087 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
16088 SLP_TREE_NUMBER_OF_VEC_STMTS.
16089 (vect_analyze_slp_cost_1): Remove.
16090 (vect_analyze_slp_cost): Likewise.
16091 (vect_slp_analyze_node_operations): Take visited args and
16092 a target cost vector. Avoid processing already visited stmt sets.
16093 (vect_slp_analyze_operations): Use a local cost vector to gather
16094 costs and register those of non-discarded instances.
16095 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
16096 (vect_schedule_slp_instance): Remove copying of
16097 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
16099 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
16100 adding cost. Record cost entry location.
16101 (vect_prologue_cost_for_slp_op): Function to compute cost of
16102 a constant or invariant generated for SLP vect in the prologue,
16103 split out from vect_analyze_slp_cost_1.
16104 (vect_model_simple_cost): Make static. Adjust for SLP costing.
16105 (vect_model_promotion_demotion_cost): Likewise.
16106 (vect_model_store_cost): Likewise, make static.
16107 (vect_model_load_cost): Likewise.
16108 (vectorizable_bswap): Add cost vector arg and adjust.
16109 (vectorizable_call): Likewise.
16110 (vectorizable_simd_clone_call): Likewise.
16111 (vectorizable_conversion): Likewise.
16112 (vectorizable_assignment): Likewise.
16113 (vectorizable_shift): Likewise.
16114 (vectorizable_operation): Likewise.
16115 (vectorizable_store): Likewise.
16116 (vectorizable_load): Likewise.
16117 (vectorizable_condition): Likewise.
16118 (vectorizable_comparison): Likewise.
16119 (can_vectorize_live_stmts): Likewise.
16120 (vect_analyze_stmt): Likewise.
16121 (vect_transform_stmt): Adjust calls to vectorizable_*.
16122 * tree-vectorizer.c: Include gimple-pretty-print.h.
16123 (dump_stmt_cost): New function.
16125 2018-05-16 Richard Biener <rguenther@suse.de>
16127 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
16128 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
16129 * tree-ssa-dse.c: Include tree-ssa-loop.h.
16130 (check_name): New callback.
16131 (dse_classify_store): Track cycles via a visited bitmap of PHI
16132 defs and simplify handling of in-loop and across loop dead stores
16133 and properly fail for loop-variant refs. Handle byte-tracking with
16134 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
16137 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
16139 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
16140 (vect_get_mask_type_for_stmt): Likewise.
16141 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
16143 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
16144 to determine the statement's vector type and the vector type that
16145 should be used for calculating nunits. Deal with cases in which
16146 the type has to be deferred.
16147 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
16148 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
16149 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
16150 (vect_determine_vf_for_stmt): New functions, split out from...
16151 (vect_determine_vectorization_factor): ...here.
16152 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
16153 (vect_get_mask_type_for_stmt): New functions, split out from
16154 vect_determine_vectorization_factor.
16156 2018-05-16 Richard Biener <rguenther@suse.de>
16158 * tree-cfg.c (verify_gimple_assign_ternary): Properly
16159 verify the [VEC_]COND_EXPR embedded comparison.
16161 2018-05-15 Martin Sebor <msebor@redhat.com>
16163 PR tree-optimization/85753
16164 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
16165 RECORD_TYPE in addition to ARRAY_TYPE.
16167 2018-05-15 Martin Sebor <msebor@redhat.com>
16169 PR middle-end/85643
16170 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
16172 2018-05-15 Richard Biener <rguenther@suse.de>
16174 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
16175 add by_clobber_p one. Change algorithm to collect all defs
16176 representing uses we need to walk and try reducing them to
16177 a single one before failing.
16178 (dse_dom_walker::dse_optimize_stmt): Adjust.
16180 2018-05-13 Mark Wielaard <mark@klomp.org>
16182 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
16183 (size_of_loc_descr): Likewise.
16184 (output_loc_operands): Likewise.
16185 (output_loc_operands_raw): Likewise.
16186 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
16187 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
16188 (hash_loc_operands): Likewise.
16189 (compare_loc_operands): Likewise.
16191 2018-05-14 Mark Wielaard <mark@klomp.org>
16193 * dwarf2out.c (count_index_addrs): New function.
16194 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
16196 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
16198 PR tree-optimization/83648
16199 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
16200 return value as malloc candidate.
16202 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
16205 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
16206 param as true in call to suggest_attribute.
16208 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
16210 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
16211 -mreadonly-in-sdata.
16213 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16215 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
16217 (aarch64_crypto_aesd_fused): Likewise.
16219 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
16221 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
16222 (movsi_aarch64): Likewise.
16223 (load_pairsi): Likewise.
16224 (load_pairdi): Likewise.
16225 (store_pairsi): Likewise.
16226 (store_pairdi): Likewise.
16227 (load_pairsf): Likewise.
16228 (load_pairdf): Likewise.
16229 (store_pairsf): Likewise.
16230 (store_pairdf): Likewise.
16231 (zero_extend): Likewise.
16232 (trunc): Swap alternatives.
16233 (fcvt_target): Add '?' to prefer w over r.
16235 2018-05-14 Jakub Jelinek <jakub@redhat.com>
16238 * config/i386/i386.md: Disallow non-commutative arithmetics in
16239 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
16240 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
16241 in the peephole2 before it.
16243 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
16245 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
16246 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
16247 (ix86_handle_option): Handle -mcldemote.
16248 * config.gcc: New header.
16249 * config/i386/cldemoteintrin.h: New file.
16250 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
16251 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
16253 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
16254 OPTION_MASK_ISA_CLDEMOTE.
16255 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
16256 (ix86_valid_target_attribute_inner_p): Ditto.
16257 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
16258 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
16259 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
16260 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
16261 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
16263 * config/i386/i386.opt: Add -mcldemote.
16264 * config/i386/x86intrin.h: New header.
16265 * doc/invoke.texi: Add -mcldemote.
16267 2018-05-14 Richard Biener <rguenther@suse.de>
16269 * doc/match-and-simplify.texi: Adjust :s documentation.
16271 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
16273 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
16274 intended memcpy size.
16275 (REORDER_45): Likewise.
16277 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
16279 * sort.cc: New file.
16280 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
16281 * vec.c (qsort_chk): Use gcc_qsort.
16282 * Makefile.in (OBJS-libcommon): Add sort.o.
16283 (build/sort.o): New target. Use it...
16284 (BUILD_RTL): ... here, and...
16285 (build/gencfn-macros): ... here, and...
16286 (build/genmatch): ... here.
16288 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
16289 Chung-Ju Wu <jasonwucj@gmail.com>
16291 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
16292 * config/nds32/nds32-graywolf.md: New file.
16293 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
16294 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
16296 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
16297 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
16298 * config/nds32/nds32.md (pipeline_model): Add graywolf.
16299 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
16300 * config/nds32/pipelines.md: Include n15 settings.
16302 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
16303 Chung-Ju Wu <jasonwucj@gmail.com>
16305 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
16306 * config/nds32/nds32-n13.md: New file.
16307 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
16308 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
16310 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
16311 * config/nds32/nds32.md (pipeline_model): Add n13.
16312 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
16313 * config/nds32/pipelines.md: Include n13 settings.
16315 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
16316 Chung-Ju Wu <jasonwucj@gmail.com>
16318 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
16319 * config/nds32/nds32-n10.md: New file.
16320 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
16321 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
16323 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
16324 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
16325 * config/nds32/nds32.md (pipeline_model): Add n10.
16326 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
16327 * config/nds32/pipelines.md: Include n10 settings.
16329 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
16330 Kito Cheng <kito.cheng@gmail.com>
16331 Chung-Ju Wu <jasonwucj@gmail.com>
16333 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
16334 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
16335 Add enum values for DSP extension instructions.
16336 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
16338 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
16339 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
16340 New code iterators.
16341 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
16342 * config/nds32/nds32-dspext.md: New file for DSP implementation.
16343 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
16344 * config/nds32/nds32-intrinsic.md: Likewise.
16345 * config/nds32/nds32_intrinsic.h: Likewise.
16346 * config/nds32/nds32-md-auxiliary.c: Likewise.
16347 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
16348 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
16349 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
16350 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
16351 * config/nds32/nds32-protos.h: New declarations for DSP extension.
16352 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
16353 TYPE_DMAC in switch statement.
16354 * config/nds32/nds32.c: New checking and implementation for DSP
16355 extension instructions.
16356 * config/nds32/nds32.h: Likewise.
16357 * config/nds32/nds32.md: Likewise.
16358 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
16359 * config/nds32/predicates.md: Implement new predicates for DSP
16362 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
16364 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
16365 Reformat alternatives and attributes so it is easier to identify
16366 which constraints/attributes go with which instruction.
16367 (mov<mode>_hardfloat32, FMOVE64): Likewise.
16368 (mov<mode>_softfloat32, FMOVE64): Likewise.
16369 (mov<mode>_hardfloat64, FMOVE64): Likewise.
16370 (mov<mode>_softfloat64, FMOVE64): Likewise.
16372 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
16374 * doc/extend.texi (PowerPC Built-in Functions): Rename this
16376 (Basic PowerPC Built-in Functions): The new name of the
16377 subsection previously known as "PowerPC Built-in Functions".
16378 (Basic PowerPC Built-in Functions Available on all Configurations):
16380 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
16381 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
16382 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
16383 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
16385 2018-05-11 Martin Jambor <mjambor@suse.cz>
16388 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
16391 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
16394 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
16396 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
16398 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
16399 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
16400 (ix86_handle_option): Handle -mwaitpkg.
16401 * config.gcc: New header.
16402 * config/i386/cpuid.h (bit_WAITPKG): New bit.
16403 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
16404 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
16406 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
16407 OPTION_MASK_ISA_WAITPKG.
16408 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
16409 (ix86_option_override_internal): Add PTA_WAITPKG.
16410 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
16411 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
16412 IX86_BUILTIN_TPAUSE.
16413 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
16414 __builtin_ia32_umwait and __builtin_ia32_tpause.
16415 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
16416 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
16417 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
16418 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
16419 UNSPECV_TPAUSE): New.
16420 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
16421 * config/i386/i386.opt: Add -mwaitpkg.
16422 * config/i386/waitpkgintrin.h: New file.
16423 * config/i386/x86intrin.h: New header.
16424 * doc/invoke.texi: Add -mwaitpkg.
16426 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
16429 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
16431 (cortex-m0): Use armv6s-m isa.
16432 (cortex-m0plus): Likewise.
16433 (cortex-m1): Likewise.
16434 (cortex-m0.small-multiply): Likewise.
16435 (cortex-m0plus.small-multiply): Likewise.
16436 (cortex-m1.small-multiply): Likewise.
16438 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
16439 Jakub Jelinek <jakub@redhat.com>
16441 PR tree-optimization/85692
16442 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
16443 source permute as well.
16445 2018-05-11 Martin Liska <mliska@suse.cz>
16448 * doc/extend.texi: Document LLVM style format for no_sanitize
16451 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
16453 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
16454 mode_supports_vsx_dform_quad to mode_supports_dq_form.
16455 (mode_supports_vsx_dform_quad): Likewise.
16456 (mode_supports_vmx_dform): Move these functions to be next to the
16457 other mode_supports functions.
16458 (mode_supports_dq_form): Likewise.
16459 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
16460 mode_supports_dq_form.
16461 (reg_offset_addressing_ok_p): Likewise.
16462 (offsettable_ok_by_alignment): Likewise.
16463 (rs6000_legitimate_offset_address_p): Likewise.
16464 (legitimate_lo_sum_address_p): Likewise.
16465 (rs6000_legitimize_address): Likewise.
16466 (rs6000_legitimize_reload_address): Likewise.
16467 (rs6000_secondary_reload_inner): Likewise.
16468 (rs6000_preferred_reload_class): Likewise.
16469 (rs6000_output_move_128bit): Likewise.
16471 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
16473 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
16474 Generate SImode target register for null target.
16475 <case IX86_BUILTIN_XGETBV>: Ditto.
16476 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
16477 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
16479 2018-05-10 Carl Love <cel@us.ibm.com>
16481 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
16482 dcbtt and dcbtstt if operands[2] is 0.
16484 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
16487 * config/i386/sse.md (usadv64qi): New expander.
16489 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
16491 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
16492 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
16493 -maltivec=be support.
16494 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
16495 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
16496 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
16497 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
16498 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
16499 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
16500 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
16501 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
16502 altivec_vsumsws): Adjust.
16503 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
16504 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
16505 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
16507 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
16508 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
16509 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
16510 (altivec_lve<VI_char>x): Delete expand.
16511 (*altivec_lve<VI_char>x_internal): Rename to...
16512 (altivec_lve<VI_char>x): ... this.
16513 (altivec_lvxl_<mode>): Delete expand.
16514 (*altivec_lvxl_<mode>_internal): Rename to ...
16515 (altivec_lvxl_<mode>): ... this.
16516 (altivec_stvxl_<mode>): Delete expand.
16517 (*altivec_stvxl_<mode>_internal): Rename to ...
16518 (altivec_stvxl_<mode>): ... this.
16519 (altivec_stve<VI_char>x): Delete expand.
16520 (*altivec_stve<VI_char>x_internal): Rename to ...
16521 (altivec_stve<VI_char>x): ... this.
16522 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
16523 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
16524 reduc_plus_scal_<mode>): Adjust.
16525 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
16527 (rs6000_cpu_cpp_builtins): Adjust.
16528 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
16529 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
16530 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
16531 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
16532 -maltivec=be support.
16533 (rs6000_split_vec_extract_var): Adjust.
16534 (rs6000_split_v4si_init): Adjust.
16535 (swap_selector_for_mode): Delete.
16536 (altivec_expand_lvx_be, altivec_expand_stvx_be,
16537 altivec_expand_stvex_be): Delete.
16538 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
16539 -maltivec=be support.
16540 (rs6000_gimple_fold_builtin): Ditto.
16541 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
16543 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
16544 (TARGET_DIRECT_MOVE_64BIT): Adjust.
16545 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
16546 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
16547 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
16548 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
16549 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
16550 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
16551 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
16552 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
16553 anonymous split): Adjust.
16554 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
16555 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
16557 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
16559 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
16560 when --with-gxx-include-dir is also specified.
16561 * configure: Regenerate.
16563 2018-05-09 Jim Wilson <jimw@sifive.com>
16566 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
16567 * config/riscv/t-withmultilib: New.
16568 * config/riscv/withmultilib.h: New.
16569 * doc/install.texi: Document RISC-V --with-multilib-list support.
16571 2018-05-09 Richard Biener <rguenther@suse.de>
16573 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
16575 (vect_bb_vectorization_profitable_p): Adjust. Compute
16576 actual scalar cost using the cost vector and the add_stmt_cost
16579 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
16581 PR rtl-optimization/85645
16582 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
16583 in the REG_CFA_REGISTER note for LR, don't leave it empty.
16585 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
16587 PR rtl-optimization/85645
16588 * shrink-wrap.c (spread_components): Return a boolean saying if
16589 anything was changed.
16590 (try_shrink_wrapping_separate): Iterate spread_components until
16591 nothing changes anymore.
16593 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
16595 PR rtl-optimization/85645
16596 * regrename.c (build_def_use): Also kill the chains that include the
16597 destination of a REG_CFA_REGISTER note.
16599 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
16601 PR rtl-optimization/85645
16602 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
16603 insn that has a REG_CFA_REGISTER note.
16605 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
16607 * cfgexpand.c (expand_clobber): New function.
16608 (expand_gimple_stmt_1): Use it.
16609 * tree-vect-stmts.c (vect_clobber_variable): New function,
16611 (vectorizable_simd_clone_call): ...here.
16612 (vectorizable_store): Emit a clobber either side of an
16613 IFN_STORE_LANES sequence.
16614 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
16616 2018-05-09 Tom de Vries <tom@codesourcery.com>
16619 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
16620 (define_insn "trap_if_false"): Add exit after trap.
16622 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
16624 PR rtl-optimization/85638
16625 * bb-reorder.c: Include common/common-target.h.
16626 (create_forwarder_block): New function extracted from...
16627 (fix_up_crossing_landing_pad): ...here. Rename into...
16628 (dw2_fix_up_crossing_landing_pad): ...this.
16629 (sjlj_fix_up_crossing_landing_pad): New function.
16630 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
16631 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
16632 from both partitions and exit the loop after one iteration.
16634 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
16637 * doc/extend.texi (PowerPC Built-in Functions): Rename this
16639 (Basic PowerPC Built-in Functions): The new name of the
16640 subsection previously known as "PowerPC Built-in Functions".
16641 (Basic PowerPC Built-in Functions Available on all Configurations):
16643 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
16645 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
16647 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
16649 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
16652 2018-05-08 Jim Wilson <jimw@sifive.com>
16654 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
16655 (LD_EMUL_SUFFIX): New.
16656 (LINK_SPEC): Use it.
16658 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
16660 * doc/extend.texi (PowerPC Built-in Functions): Rename this
16662 (Basic PowerPC Built-in Functions): The new name of the
16663 subsection previously known as "PowerPC Built-in Functions".
16664 (Basic PowerPC Built-in Functions Available on all Configurations):
16666 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
16668 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
16670 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
16672 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
16675 2018-05-08 Jakub Jelinek <jakub@redhat.com>
16678 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
16679 after cmpelim optimization.
16681 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
16683 * config.gcc: Support "goldmont".
16684 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
16685 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
16686 PROCESSOR_GOLDMONT.
16687 * config/i386/i386.c (m_GOLDMONT): Define.
16688 (processor_target_table): Add "goldmont".
16689 (PTA_GOLDMONT): Define.
16690 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
16691 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
16692 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
16693 (fold_builtin_cpu): Add "goldmont".
16694 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
16695 (ix86_option_override_internal): Add "goldmont".
16696 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
16697 (processor_type): Add PROCESSOR_GOLDMONT.
16698 * config/i386/i386.md: Add CPU "glm".
16699 * config/i386/glm.md: New file.
16700 * config/i386/x86-tune.def: Add m_GOLDMONT.
16701 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
16703 2018-05-08 Jakub Jelinek <jakub@redhat.com>
16706 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
16708 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
16709 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
16710 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
16713 * config/i386/i386.c (ix86_fold_builtin): Handle
16714 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
16717 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
16718 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
16720 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
16723 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
16724 (check_arch): Likewise.
16725 (check_fpu): Return the result rather than printing it.
16726 (end arch): Fix operator precedence.
16727 (end cpu): Likewise.
16728 (END): Print the result from check_fpu.
16730 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
16731 Alan Hayward <alan.hayward@arm.com>
16732 David Sherwood <david.sherwood@arm.com>
16734 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
16735 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
16736 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
16737 (*fcmuo<mode>_and): New patterns.
16739 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
16741 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
16742 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
16743 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
16744 (cmp_op, sve_imm_con): New code attributes.
16745 (SVE_COND_INT_CMP, imm_con): Delete.
16746 (cmp_op): Remove above unspecs from int attribute.
16747 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
16749 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
16750 comparison-specific unspecs.
16751 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
16752 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
16753 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
16754 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
16755 (*vec_fcm<cmp_op><mode>): Rename to...
16756 (*fcm<cmp_op><mode>): ...this and adjust likewise.
16757 (*vec_fcmuo<mode>): Rename to...
16758 (*fcmuo<mode>): ...this and adjust likewise.
16759 (*pred_fcm<cmp_op><mode>): New pattern.
16760 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
16761 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
16763 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
16765 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
16766 (aarch64_emit_sve_predicated_cond): New function.
16767 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
16768 (aarch64_emit_unspec_cond_or): Replace with...
16769 (aarch64_emit_sve_or_conds): ...this new function. Use
16770 aarch64_emit_sve_ptrue_op for the individual comparisons and
16771 aarch64_emit_binop to OR them together.
16772 (aarch64_emit_inverted_unspec_cond): Replace with...
16773 (aarch64_emit_sve_inverted_cond): ...this new function. Use
16774 aarch64_emit_sve_ptrue_op for the comparison and
16775 aarch64_emit_unop to invert the result.
16776 (aarch64_expand_sve_vec_cmp_float): Update after the above
16777 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
16779 2018-05-07 Nathan Sidwell <nathan@acm.org>
16781 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
16782 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
16783 (Backwards Compatibility): Likewise.
16785 2018-05-07 Luis Machado <luis.machado@linaro.org>
16789 2018-05-07 Luis Machado <luis.machado@linaro.org>
16791 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16792 <prefetch_dynamic_strides>: New const bool field.
16793 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16794 prefetch_dynamic_strides.
16795 (exynosm1_prefetch_tune): Likewise.
16796 (thunderxt88_prefetch_tune): Likewise.
16797 (thunderx_prefetch_tune): Likewise.
16798 (thunderx2t99_prefetch_tune): Likewise.
16799 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
16801 (aarch64_override_options_internal): Update to set
16802 PARAM_PREFETCH_DYNAMIC_STRIDES.
16803 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
16804 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
16805 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
16806 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
16807 prefetch-dynamic-strides setting.
16809 2018-05-07 Luis Machado <luis.machado@linaro.org>
16811 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16812 <minimum_stride>: New const int field.
16813 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16814 minimum_stride field.
16815 (exynosm1_prefetch_tune): Likewise.
16816 (thunderxt88_prefetch_tune): Likewise.
16817 (thunderx_prefetch_tune): Likewise.
16818 (thunderx2t99_prefetch_tune): Likewise.
16819 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
16820 (aarch64_override_options_internal): Update to set
16821 PARAM_PREFETCH_MINIMUM_STRIDE.
16822 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
16823 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
16824 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
16825 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
16826 stride is constant and is below the minimum stride threshold.
16828 2018-05-07 Luis Machado <luis.machado@linaro.org>
16830 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
16833 2018-05-07 Luis Machado <luis.machado@linaro.org>
16835 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16836 <prefetch_dynamic_strides>: New const bool field.
16837 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16838 prefetch_dynamic_strides.
16839 (exynosm1_prefetch_tune): Likewise.
16840 (thunderxt88_prefetch_tune): Likewise.
16841 (thunderx_prefetch_tune): Likewise.
16842 (thunderx2t99_prefetch_tune): Likewise.
16843 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
16845 (aarch64_override_options_internal): Update to set
16846 PARAM_PREFETCH_DYNAMIC_STRIDES.
16847 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
16848 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
16849 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
16850 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
16851 prefetch-dynamic-strides setting.
16853 2018-05-07 Luis Machado <luis.machado@linaro.org>
16855 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16856 <minimum_stride>: New const int field.
16857 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16858 minimum_stride field.
16859 (exynosm1_prefetch_tune): Likewise.
16860 (thunderxt88_prefetch_tune): Likewise.
16861 (thunderx_prefetch_tune): Likewise.
16862 (thunderx2t99_prefetch_tune): Likewise.
16863 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
16864 (aarch64_override_options_internal): Update to set
16865 PARAM_PREFETCH_MINIMUM_STRIDE.
16866 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
16867 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
16868 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
16869 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
16870 stride is constant and is below the minimum stride threshold.
16872 2018-05-06 Jakub Jelinek <jakub@redhat.com>
16875 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
16876 the type is addressable. Don't force op into register if it has
16879 2018-05-05 Roland McGrath <mcgrathr@google.com>
16882 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
16883 any section for which we don't know a specific type it should have,
16884 regardless of name. Previously this was done only for the exact
16885 names ".init_array", ".fini_array", and ".preinit_array".
16886 (default_elf_asm_named_section): Add comment about
16887 relationship with default_section_type_flags and SECTION_NOTYPE.
16888 (get_section): Don't consider it a type conflict if one side has
16889 SECTION_NOTYPE and the other doesn't, as long as neither has the
16890 SECTION_BSS et al used in the default_section_type_flags logic.
16892 2018-05-05 Tom de Vries <tom@codesourcery.com>
16895 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
16896 (workaround_barsyncs): New function.
16897 (nvptx_reorg): Use workaround_barsyncs.
16898 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
16899 (define_expand "nvptx_membar_cta"): New define_expand.
16900 (define_insn "*nvptx_membar_cta"): New insn.
16902 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
16904 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
16905 To improve optimization opportunities.
16906 * builtin-types.def: The new needed builtin types for the above.
16908 2018-05-04 Richard Biener <rguenther@suse.de>
16910 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
16911 * gimple-ssa-store-merging.c
16912 (imm_store_chain_info::output_merged_store): Remove redundant create,
16913 release split_store vector contents on failure.
16914 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
16915 scalar stmt vector on cache hit.
16917 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
16919 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
16921 * config.gcc (powerpc-xilinx-eabi*): Remove.
16922 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
16924 (fusion_addis_mem_combo_load): Ditto.
16925 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
16927 (rs6000_cpu_cpp_builtins): Ditto.
16928 * config/rs6000/rs6000-linux.c
16929 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
16930 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
16931 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
16933 (rs6000_setup_reg_addr_masks): Ditto.
16934 (rs6000_init_hard_regno_mode_ok): Ditto.
16935 (rs6000_option_override_internal): Ditto.
16936 (legitimate_lo_sum_address_p): Ditto.
16937 (rs6000_legitimize_address): Ditto.
16938 (rs6000_legitimize_reload_address): Ditto.
16939 (rs6000_legitimate_address_p): Ditto.
16940 (abi_v4_pass_in_fpr): Ditto.
16941 (setup_incoming_varargs): Ditto.
16942 (rs6000_gimplify_va_arg): Ditto.
16943 (rs6000_split_multireg_move): Ditto.
16944 (rs6000_savres_strategy): Ditto.
16945 (rs6000_emit_prologue_components): Ditto.
16946 (rs6000_emit_epilogue_components): Ditto.
16947 (rs6000_emit_prologue): Ditto.
16948 (rs6000_emit_epilogue): Ditto.
16949 (rs6000_elf_file_end): Ditto.
16950 (rs6000_function_value): Ditto.
16951 (rs6000_libcall_value): Ditto.
16952 * config/rs6000/rs6000.h: Ditto.
16953 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
16954 (TARGET_MINMAX): ... this. New.
16955 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
16956 * config/rs6000/rs6000.md: Remove Xilinx FP support.
16957 (*movsi_internal1_single): Delete.
16958 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
16959 mfpu=, mxilinx-fpu): Delete.
16960 * config/rs6000/singlefp.h: Delete.
16961 * config/rs6000/sysv4.h: Remove Xilinx FP support.
16962 * config/rs6000/t-rs6000: Ditto.
16963 * config/rs6000/t-xilinx: Delete.
16964 * config/rs6000/titan.md: Adjust for fp_type removal.
16965 * config/rs6000/vsx.md: Remove Xilinx FP support.
16966 (VStype_simple): Delete.
16967 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
16968 * config/rs6000/xfpu.h: Delete.
16969 * config/rs6000/xfpu.md: Delete.
16970 * config/rs6000/xilinx.h: Delete.
16971 * config/rs6000/xilinx.opt: Delete.
16972 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
16973 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
16975 2018-05-04 Tom de Vries <tom@codesourcery.com>
16978 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
16981 2018-05-04 Richard Biener <rguenther@suse.de>
16983 PR middle-end/85627
16984 * tree-complex.c (update_complex_assignment): We are always in SSA form.
16985 (expand_complex_div_wide): Likewise.
16986 (expand_complex_operations_1): Likewise.
16987 (expand_complex_libcall): Preserve EH info of the original stmt.
16988 (tree_lower_complex): Handle removed blocks.
16989 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
16990 on complex multiplication and division libcall builtins.
16992 2018-05-04 Richard Biener <rguenther@suse.de>
16994 PR middle-end/85574
16995 * fold-const.c (negate_expr_p): Restrict negation of operand
16996 zero of a division to when we know that can happen without
16998 (fold_negate_expr_1): Likewise.
17000 2018-05-04 Jakub Jelinek <jakub@redhat.com>
17003 * real.h (real_nextafter): Declare.
17004 * real.c (real_nextafter): New function.
17005 * fold-const-call.c (fold_const_nextafter): New function.
17006 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
17007 CASE_CFN_NEXTTOWARD.
17008 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
17009 even when arg1_mode is different from arg0_mode.
17011 2018-05-03 Nathan Sidwell <nathan@acm.org>
17013 * doc/extend.texi (Deprecated Features): Remove
17014 -ffriend-injection.
17015 (Backwards Compatibility): Likewise.
17016 * doc/invoke.texi (C++ Language Options): Likewise.
17017 (C++ Dialect Options): Likewise.
17019 2018-05-03 Jakub Jelinek <jakub@redhat.com>
17022 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
17023 _mm512_mask_mullox_epi64): New intrinsics.
17025 2018-05-03 Tom de Vries <tom@codesourcery.com>
17028 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
17029 dump files): Add offload-tree.
17031 2018-05-03 Richard Biener <rguenther@suse.de>
17033 PR tree-optimization/85615
17034 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
17035 to loops not nested in BBs loop father to avoid creating multi-entry
17038 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17040 PR tree-optimization/70291
17041 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
17042 arguments. Change return type to tree. Emit libcall as a new
17043 statement rather than replacing existing one when inplace_p is true.
17044 (expand_complex_multiplication_components): New function.
17045 (expand_complex_multiplication): Expand floating-point complex
17046 multiplication using the above.
17047 (expand_complex_division): Rename inner_type parameter to type.
17048 Update expand_complex_libcall call-site.
17049 (expand_complex_operations_1): Update expand_complex_multiplication
17050 and expand_complex_division call-sites.
17052 2018-05-02 Jakub Jelinek <jakub@redhat.com>
17055 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
17056 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
17057 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
17058 the highest significant bit of the shift count mask is clear. In
17059 check whether and[sq]i3 is needed verify that all significant bits
17060 of the shift count other than the highest are set.
17062 2018-05-02 Tom de Vries <tom@codesourcery.com>
17065 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
17066 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
17067 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
17068 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
17069 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
17070 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
17071 __builtin_goacc_parlevel_size.
17073 2018-05-02 Richard Biener <rguenther@suse.de>
17075 PR tree-optimization/85597
17076 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
17077 do not use split vect_get_vec_defs call but call vect_get_slp_defs
17080 2018-05-02 Tom de Vries <tom@codesourcery.com>
17083 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
17084 dump files): Add ltrans-tree.
17086 2018-05-02 Tom de Vries <tom@codesourcery.com>
17089 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
17090 dump files): Add wpa-ipa.
17092 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
17094 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
17095 powerpc*-*-linux*paired* target.
17096 * config/rs6000/750cl.h: Delete.
17097 * config/rs6000/paired.h: Delete.
17098 * config/rs6000/paired.md: Delete.
17099 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
17101 * config/rs6000/rs6000-builtin.def: Remove paired float support.
17102 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
17103 comment. Remove paired float support.
17104 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
17105 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
17107 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
17108 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
17110 * config/rs6000/rs6000.c: Remove paired float support.
17111 (paired_expand_vector_init, paired_expand_vector_move,
17112 paired_emit_vector_compare, paired_emit_vector_cond_expr,
17113 (paired_expand_lv_builtin, paired_expand_stv_builtin,
17114 paired_expand_builtin, paired_expand_predicate_builtin,
17115 paired_init_builtins): Delete.
17116 * config/rs6000/rs6000.h: Remove paired float support.
17117 * config/rs6000/rs6000.md: Remove paired float support.
17118 (move_from_CR_ov_bit): Delete.
17119 * config/rs6000/rs6000.opt (mpaired): Delete.
17120 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
17121 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
17123 2018-05-02 Richard Biener <rguenther@suse.de>
17125 PR middle-end/85567
17126 * gimplify.c (gimplify_save_expr): When in SSA form allow
17127 SAVE_EXPRs to compute to SSA vars.
17129 2018-05-02 Jakub Jelinek <jakub@redhat.com>
17132 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
17133 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
17134 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
17135 clobber operands[2], instead use a new pseudo. Formatting fixes.
17137 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
17139 PR tree-optimization/85586
17140 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
17141 exit early for statements in the same group if the accesses are
17144 2018-05-02 Tom de Vries <tom@codesourcery.com>
17147 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
17150 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
17152 PR tree-optimization/85143
17153 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
17155 2018-05-01 Tom de Vries <tom@codesourcery.com>
17158 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
17159 not found" error message.
17161 2018-05-01 Tom de Vries <tom@codesourcery.com>
17164 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
17165 * vec.c (test_ordered_remove_if): New function.
17166 (vec_c_tests): Call test_ordered_remove_if.
17167 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
17168 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
17169 * tree-vect-patterns.c (vect_pattern_recog_1): Use
17170 VEC_ORDERED_REMOVE_IF.
17172 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17174 PR tree-optimization/82665
17175 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
17176 pointer subtraction where arguments come from a memchr call.
17178 2018-05-01 Jakub Jelinek <jakub@redhat.com>
17180 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
17181 --push-state --as-needed and --pop-state instead of --as-needed and
17182 --no-as-needed if ld supports it.
17183 * configure: Regenerated.
17186 * doc/install.texi2html: Replace _002d with - and _002a with * in
17187 generated html files using sed.
17189 2018-04-30 David Malcolm <dmalcolm@redhat.com>
17192 * gcc-rich-location.c (blank_line_before_p): New function.
17193 (use_new_line): New function.
17194 (gcc_rich_location::add_fixit_insert_formatted): New function.
17195 * gcc-rich-location.h
17196 (gcc_rich_location::add_fixit_insert_formatted): New function.
17198 2018-04-30 David Malcolm <dmalcolm@redhat.com>
17200 * selftest.c (assert_streq): Rename "expected" and "actual" to
17201 "val1" and "val2". Extend NULL-handling to cover both inputs
17202 symmetrically, while still requiring both to be non-NULL for a pass.
17203 * selftest.h (assert_streq): Rename "expected" and "actual" to
17205 (ASSERT_EQ): Likewise.
17206 (ASSERT_EQ_AT): Likewise.
17207 (ASSERT_KNOWN_EQ): Likewise.
17208 (ASSERT_KNOWN_EQ_AT): Likewise.
17209 (ASSERT_NE): Likewise.
17210 (ASSERT_MAYBE_NE): Likewise.
17211 (ASSERT_MAYBE_NE_AT): Likewise.
17212 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
17213 the assertion to pass.
17214 (ASSERT_STREQ_AT): Likewise.
17216 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
17218 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
17219 interaction with -pie.
17221 2018-04-30 David Malcolm <dmalcolm@redhat.com>
17223 * selftest.h: Fix alphabetization of per-source-file selftest
17226 2018-04-30 Jason Merrill <jason@redhat.com>
17228 PR c++/61982 - dead stores to destroyed objects.
17229 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
17232 2018-04-30 Jason Merrill <jason@redhat.com>
17234 * tree.c (build_clobber): New.
17235 * tree.h: Declare it.
17236 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
17238 2018-04-30 David Malcolm <dmalcolm@redhat.com>
17240 * diagnostic-show-locus.c (layout::layout): Update for
17241 location_get_source_line returning a char_span.
17242 (struct char_span): Move to input.h.
17243 (struct correction): Update for fields in char_span becoming
17245 (struct source_line): Update for location_get_source_line
17246 returning a char_span.
17247 (layout::print_line): Likewise.
17248 * edit-context.c (edited_file::print_content): Likewise.
17249 (edited_file::print_diff_hunk): Likewise.
17250 (edited_file::print_run_of_changed_lines): Likewise.
17251 (edited_file::get_num_lines): Likewise.
17252 (edited_line::edited_line): Likewise.
17253 * final.c (asm_show_source): Likewise.
17254 * input.c (location_get_source_line): Convert return type
17255 from const char * to char_span, losing the final "line_len"
17257 (dump_location_info): Update for the above.
17258 (get_substring_ranges_for_loc): Likewise. Use a char_span
17259 when handling the literal within the line.
17260 (test_reading_source_line): Update for location_get_source_line
17261 returning a char_span.
17262 * input.h (class char_span): Move here from
17263 diagnostic-show-locus.c, converting from a struct to a class.
17264 Make data members private.
17265 (char_span::operator bool): New.
17266 (char_span::length): New.
17267 (char_span::get_buffer): New.
17268 (char_span::operator[]): New.
17269 (char_span::subspan): Make const.
17270 (char_span::xstrdup): New.
17271 (location_get_source_line): Convert return type from const char *
17272 to char_span, losing the final "line_size" param.
17274 2018-04-30 Jan Hubicka <jh@suse.cz>
17276 * lto-wrapper.c (ltrans_priorities): New static var.
17277 (cmp_priority): New.
17278 (run_gcc): Read priorities and if doing parallel build order
17279 the Makefile by them.
17281 2018-04-30 David Malcolm <dmalcolm@redhat.com>
17283 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
17285 2018-04-30 Richard Biener <rguenther@suse.de>
17287 * tree-cfg.c (verify_address): Remove base argument, add
17288 flag whether to check TREE_ADDRESSABLE and do that.
17289 (verify_expr): Remove.
17290 (verify_types_in_gimple_reference): Add pieces from verify_expr.
17291 (verify_gimple_assign_single): Likewise.
17292 (verify_gimple_switch): Likewise.
17293 (verify_expr_location_1): Dereference tp once. Add (disabled)
17294 piece from verify_expr.
17295 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
17297 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
17299 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
17301 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
17303 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
17304 (small_data_pattern): Likewise.
17305 (arc_rewrite_small_data): Likewise.
17306 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
17307 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
17308 (get_symbol_alignment): New function.
17309 (legitimate_small_data_address_p): Likewise.
17310 (legitimate_scaled_address): Update, call
17311 legitimate_small_data_address_p.
17312 (output_sdata): New static variable.
17313 (arc_print_operand): Update how we handle small data operands.
17314 (arc_print_operand_address): Likewise.
17315 (arc_legitimate_address_p): Update, use
17316 legitimate_small_data_address_p.
17317 (arc_rewrite_small_data_p): Remove.
17318 (arc_rewrite_small_data_1): Likewise.
17319 (arc_rewrite_small_data): Likewise.
17320 (small_data_pattern): Likewise.
17321 (compact_sda_memory_operand): Update to use
17322 legitimate_small_data_address_p and get_symbol_alignment.
17323 (prepare_move_operands): Don't rewite sdata pattern.
17324 (prepare_extend_operands): Remove.
17325 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
17327 (zero_extendqisi2): Likewise.
17328 (zero_extendhisi2): Likewise.
17329 (extendqihi2): Likewise.
17330 (extendqisi2): Likewise.
17331 (extendhisi2): Likewise.
17332 (addsi3): Likewise.
17333 (subsi3): Likewise.
17334 (andsi3): Likewise.
17335 * config/arc/constraints.md (Usd): Change it to memory constraint.
17337 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
17339 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
17340 as source of std instructions.
17341 * config/arc/arc.md (movsi_insn): Update pattern predicate to
17342 allow 6-bit constants as source for store instructions.
17343 (movdi_insn): Update instruction pattern to allow 6-bit constants
17344 as source for store instructions.
17346 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
17348 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
17350 2018-04-30 Nathan Sidwell <nathan@acm.org>
17351 Sandra Loosemore <sandra@codesourcery.com>
17353 * dumpfile.c (dump_open): Allow '-' for stdout.
17354 * doc/invoke.texi (Developer Options): Document dump filename
17355 determination early. Document stdin/stdout selection.
17357 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
17359 Microblaze Target: PIC data text relative
17361 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
17362 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
17364 * config/microblaze/microblaze.h (microblaze_constant_address_p):
17365 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
17366 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
17367 New addressing mode for data-text relative position indepenedent code.
17368 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
17369 'ADDRESS_SYMBOLIC_TXT_REL'.
17370 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
17371 (microblaze_legitimate_pic_operand): Exclude function calls from
17372 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
17373 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
17375 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
17376 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
17377 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
17378 for 'address + offset'.
17379 (microblaze_expand_prologue): Add new function prologue call for
17381 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
17382 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
17383 table in case of TARGET_PIC_DATA_TEXT_REL.
17384 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
17385 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
17386 Add new macros 'UNSPEC_TEXT',
17387 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
17388 + exclude function calls from 'UNSPEC_PLT' in case of data text
17390 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
17391 new target hook for generating address diff vector tables in case of
17393 * doc/tm.texi : Regenerate.
17394 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
17395 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
17396 of addr diff vector generation.
17397 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
17398 target hook definition.
17399 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
17400 Add default function for generate_pic_addr_diff_vec -> flag_pic.
17401 * doc/invoke.texi (Add new pic option): Add new microblaze pic
17402 option for data text relative.
17404 2018-04-30 Richard Biener <rguenther@suse.de>
17406 * tree-chrec.h (evolution_function_is_constant_p): Remove
17408 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
17410 2018-04-30 Richard Biener <rguenther@suse.de>
17413 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
17415 2018-04-30 Richard Biener <rguenther@suse.de>
17417 PR tree-optimization/28364
17418 PR tree-optimization/85275
17419 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
17420 copying first exit test.
17422 2018-04-28 Mark Wielaard <mark@klomp.org>
17424 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
17425 dwarf_version >= 5.
17426 (dwarf_AT): Handle DW_AT_addr_base.
17427 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
17429 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
17432 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
17433 (*ashl<dwi>3_doubleword_mask_1): Ditto.
17434 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
17435 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
17437 2018-04-28 Richard Biener <rguenther@suse.de>
17439 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
17440 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
17441 to reflect use. Only add interesting stmts.
17443 2018-04-27 Martin Jambor <mjambor@suse.cz>
17446 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
17447 the jump function allows for passing through aggregate values.
17449 2018-04-27 David Malcolm <dmalcolm@redhat.com>
17451 * input.h (in_system_header_at): Convert from macro to inline
17453 (from_macro_expansion_at): Likewise.
17454 (from_macro_definition_at): Likewise.
17456 2018-04-27 Jeff Law <law@redhat.com>
17458 * config.gcc: Mark tile* targets as deprecated/obsolete.
17460 2018-04-27 Richard Biener <rguenther@suse.de>
17462 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
17465 2018-04-27 Richard Biener <rguenther@suse.de>
17467 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
17469 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
17471 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
17472 with Yd constraint. Set "preferred_for_speed" attribute from
17473 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
17474 with Yd constraint.
17475 (*movdi_internal): Ditto.
17476 (movti_interunit splitters): Remove
17477 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
17478 (movdi_interunit splitters): Ditto.
17479 * config/i386/constraints.md (Ye): Remove.
17480 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
17482 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17485 * config/aarch64/constraints.md (Usg): Limit to 31.
17486 (Usj): Limit to 63.
17488 2018-04-27 Jakub Jelinek <jakub@redhat.com>
17490 PR tree-optimization/85529
17491 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
17492 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
17493 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
17494 zero extension or masking of the MSB bit.
17495 (optimize_range_tests): Add FIRST_BB argument, pass it through
17496 to optimize_range_tests_var_bound.
17497 (maybe_optimize_range_tests, reassociate_bb): Adjust
17498 optimize_range_tests callers.
17500 2018-04-26 Richard Biener <rguenther@suse.de>
17501 Jakub Jelinek <jakub@redhat.com>
17503 * cgraph.h (symbol_table): Just declare debug method here.
17504 * symtab.c (symbol_table::debug): Define.
17506 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
17508 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
17510 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
17512 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
17513 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
17514 (*movdi_internal): Substitute Yi and Yj constraint with x
17515 and Ym and Yn constraint with y constraint. Update "isa"
17516 attribute and set "preferred_for_speed" attribute from
17517 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
17518 (*movsi_internal): Ditto.
17519 (*movdf_internal): Ditto.
17520 (*movsf_internal): Ditto.
17521 (*zero_extendsidi2): Ditto.
17522 * config/i386/sse.md (vec_set<mode>_0): Ditto.
17523 (sse2_loadld): Ditto.
17524 (*vec_extract<ssevecmodelower>_0): Ditto.
17525 (*vec_extractv4si_0_zext_sse4): Ditto.
17526 (vec_concatv2di): Ditto.
17527 (*vec_dup<mode>): Ditto.
17528 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
17529 * config/i386/constraints.md (Yi): Remove.
17534 2018-04-26 Nathan Sidwell <nathan@acm.org>
17536 * dumpfile.c (dump_open): New.
17537 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
17538 (dump_finish): Detect stdio/stderr by value not name.
17540 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
17542 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
17544 2018-04-26 Tom de Vries <tom@codesourcery.com>
17547 * config/nvptx/nvptx.c (verify_neutering_jumps)
17548 (verify_neutering_labels): New function
17549 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
17551 2018-04-26 Tom de Vries <tom@codesourcery.com>
17554 * config/nvptx/nvptx.c (needs_neutering_p): New function.
17555 (nvptx_single): Use needs_neutering_p to skip over insns that do not
17558 2018-04-26 Richard Biener <rguenther@suse.de>
17559 Tom de Vries <tom@codesourcery.com>
17562 * lto-streamer-out.c (output_function): Fixup loops if required to match
17563 discovery done in the reader.
17565 2018-04-26 Richard Biener <rguenther@suse.de>
17567 PR tree-optimization/85116
17568 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
17569 have a loop exit from the single latch predecessor. Remove
17570 case of header with just condition.
17571 (ch_base::copy_headers): Exclude infinite loops from any
17573 (pass_ch::execute): Record exits.
17575 2018-04-26 Richard Biener <rguenther@suse.de>
17577 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
17578 prologue cost vector and pass it to vect_get_load_cost.
17579 (vect_get_peeling_costs_all_drs): Likewise.
17580 (vect_peeling_hash_get_lowest_cost): Likewise.
17581 (vect_enhance_data_refs_alignment): Likewise.
17583 2018-04-26 Richard Biener <rguenther@suse.de>
17585 PR middle-end/85450
17586 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
17587 checking of integer<->pointer conversions.
17588 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
17589 sign-/zero-extending pointer types.
17590 (expand_omp_for_static_chunk): Likewise.
17592 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
17593 Jean Lee <xiaoyur347@gmail.com>
17595 * config/mips/mips.c (mips_asan_shadow_offset): New function.
17596 (TARGET_ASAN_SHADOW_OFFSET): Define.
17597 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
17598 true for -fsanitize=address.
17600 2018-04-25 Mark Wielaard <mark@klomp.org>
17602 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
17605 2018-04-25 Jakub Jelinek <jakub@redhat.com>
17607 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
17608 than "alu", remove explicit "memory" and "imm_disp" attributes.
17609 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
17611 PR middle-end/85414
17612 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
17613 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
17614 gen_lowpart_no_emit.
17616 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
17619 * config/i386/i386.c (ix86_expand_builtin): Change memory
17620 operand to XI, extend p0 to Pmode.
17621 * config/i386/i386.md: Change unspec volatile and operand
17622 1 mode to XI, change operand 0 mode to P.
17624 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
17626 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
17627 GET_MODE_MASK before any checking.
17628 (nds32_can_use_bset_p): Likewise.
17629 (nds32_can_use_btgl_p): Likewise.
17631 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
17633 * config/nds32/nds32-doubleword.md: New define_split pattern for
17634 illegal register number.
17636 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
17638 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
17640 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
17642 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
17644 2018-04-25 Richard Biener <rguenther@suse.de>
17646 * lto-streamer.h (LTO_major_version): Bump to 8.
17648 2018-04-25 Jakub Jelinek <jakub@redhat.com>
17650 * BASE-VER: Set to 9.0.0.
17652 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
17654 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
17655 in __abskf2 and __powikf2.
17657 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17660 * config/aarch64/constraints.md (Usg, Usj): New constraints.
17661 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
17662 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
17663 Use the above on operand 2. Reindent.
17664 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
17666 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
17669 * common/config/i386/i386-common.c (ix86_handle_option): Don't
17671 * config/i386/i386.opt (mcet): Removed.
17672 * doc/install.texi: Remove -mcet documentation.
17673 * doc/invoke.texi: Likewise.
17675 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
17678 * doc/install.texi: Remove -mcet from bootstrap-cet.
17680 2018-04-24 Jakub Jelinek <jakub@redhat.com>
17683 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
17684 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
17688 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
17689 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
17690 containing a CONST_VECTOR.
17692 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
17694 * doc/install.texi: Update newlib dependency for nvptx.
17696 2018-04-24 Jakub Jelinek <jakub@redhat.com>
17699 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
17700 instead of INTVAL when shifting x left.
17702 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
17704 PR tree-optimization/85478
17705 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
17706 vect_grouped_store_supported for single element vectors.
17708 2018-04-24 Richard Biener <rguenther@suse.de>
17711 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
17712 load cost increase to the case of non-constant step.
17714 2018-04-24 Jakub Jelinek <jakub@redhat.com>
17717 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
17718 destination if any_malformed_asm.
17720 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
17722 PR middle-end/85496
17723 * expr.c (store_field): In the bitfield case, if the value comes from
17724 a function call and is returned in registers by means of a PARALLEL,
17725 do not change the mode of the temporary unless BLKmode and VOIDmode.
17727 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
17729 PR rtl-optimization/85423
17730 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
17731 dependencies to debug insns when the previous insn is non-debug.
17733 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
17735 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
17736 enums into a single definition.
17737 (fls): Fix predicates and printing.
17740 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
17742 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
17743 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
17744 and short u6 immediate.
17745 (check_if_valid_sleep_operand): Remove.
17746 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
17748 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
17750 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
17751 flag_always_save_lp condition.
17752 * config/nds32/nds32.opt (malways-save-lp): New option.
17754 2018-04-22 Shiva Chen <shiva0217@gmail.com>
17756 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
17757 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
17758 * config/nds32/nds32.h
17759 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
17760 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
17762 2018-04-22 Shiva Chen <shiva0217@gmail.com>
17764 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
17765 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
17767 2018-04-22 Shiva Chen <shiva0217@gmail.com>
17768 Chung-Ju Wu <jasonwucj@gmail.com>
17770 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
17772 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
17773 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
17775 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
17777 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
17779 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
17781 * config/nds32/nds32-protos.h (nds32_data_alignment,
17782 nds32_local_alignment): Declare.
17783 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
17784 nds32_local_alignment): New functions.
17785 (TARGET_CONSTANT_ALIGNMENT): Define.
17786 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
17788 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
17790 * config/nds32/nds32.c
17791 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
17792 (TARGET_MODES_TIEABLE_P): Likewise.
17794 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
17796 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
17797 level Ofast and Og.
17799 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
17800 Chung-Ju Wu <jasonwucj@gmail.com>
17802 * config/nds32/constants.md (unspec_volatile_element): Add enum values
17803 for unaligned access.
17804 * config/nds32/nds32-intrinsic.c: Implementation of expanding
17806 * config/nds32/nds32-intrinsic.md: Likewise.
17807 * config/nds32/nds32_intrinsic.h: Likewise.
17808 * config/nds32/nds32.h (nds32_builtins): Likewise.
17809 * config/nds32/nds32.opt (munaligned-access): New option.
17810 * config/nds32/nds32.c (nds32_asm_file_start): Display
17811 flag_unaligned_access status.
17813 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
17815 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
17816 -mno-relax is present.
17817 * config/riscv/linux.h (LINK_SPEC): Ditto.
17819 2018-04-20 Martin Sebor <msebor@redhat.com>
17822 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
17824 (gimple_fold_builtin_stxcpy_chk): Same.
17825 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
17827 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
17830 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
17831 __powikf2 when long double is IEEE 128-bit.
17833 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
17835 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
17836 step to make sure stack always aligned.
17838 2018-04-20 Carl Love <cel@us.ibm.com>
17841 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
17842 size check for arg0.
17844 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
17845 Tom de Vries <tom@codesourcery.com>
17848 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
17849 Emit insns for calls too.
17850 (nvptx_find_par): Always look for worker-level predecessor insn.
17851 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
17853 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
17854 (nvptx_process_pars): Propagate frames for calls.
17856 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
17859 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
17861 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
17862 (ix86_handle_option): Don't handle OPT_mibt.
17863 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
17865 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
17867 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
17868 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
17869 (ix86_target_macros): Define __CET__ with flag_cf_protection
17870 for -fcf-protection.
17871 * config/i386/i386.c (isa2_opts): Remove -mibt.
17872 * config/i386/i386.h (TARGET_IBT): Removed.
17873 (TARGET_IBT_P): Likewise.
17874 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
17875 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
17876 * config/i386/i386.opt (mcet): Update help message.
17877 (mshstk): Likewise.
17879 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
17880 -mcet as an alias for -mshstk.
17882 2018-04-20 Richard Biener <rguenther@suse.de>
17884 PR middle-end/85475
17885 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
17886 complexity by forcing a single use of the multiply operand.
17888 2018-04-20 Martin Jambor <mjambor@suse.cz>
17891 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
17892 recursion dependency to only apply to non-clones.
17894 2018-04-20 Martin Jambor <mjambor@suse.cz>
17897 * ipa-cp.c (create_specialized_node): Check that clones of
17898 self-recursive edges exist during IPA-CP.
17900 2018-04-19 Toon Moene <toon@moene.org>
17902 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
17905 2018-04-19 Jakub Jelinek <jakub@redhat.com>
17907 PR tree-optimization/85467
17908 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
17909 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
17910 VECTOR_CST element to type.
17912 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
17915 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
17916 * config/i386/i386.md (builtin_setjmp_setup): Removed.
17917 (builtin_longjmp): Likewise.
17918 (save_stack_nonlocal): New pattern.
17919 (restore_stack_nonlocal): Likewise.
17921 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
17924 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
17925 Replace ASM_OUTPUT_LABEL with fprintf.
17927 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
17930 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
17931 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
17932 * config/i386/i386-c.c (ix86_target_macros_internal): Also
17933 define __IBT__ and __SHSTK__ for -fcf-protection.
17934 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
17936 (ix86_trampoline_init): Likewise.
17937 (x86_output_mi_thunk): Likewise.
17938 (ix86_notrack_prefixed_insn_p): Likewise.
17939 (ix86_option_override_internal): Don't disallow -fcf-protection.
17940 * config/i386/i386.md (rdssp<mode>): Also enable for
17942 (incssp<mode>): Likewise.
17943 (nop_endbr): Likewise.
17944 * config/i386/i386.opt (mcet): Change help message to built-in
17947 (mshstk): Likewise.
17948 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
17949 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
17950 enable CET built-in functions.
17952 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
17954 * common/config/i386/i386-common.c
17955 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
17956 OPTION_MASK_ISA_MOVDIRI_UNSET,
17957 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
17958 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
17959 * config.gcc (movdirintrin.h): New header.
17960 * config/i386/cpuid.h (bit_MOVDIRI,
17961 bit_MOVDIR64B): New bits.
17962 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
17964 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
17965 (VOID, PVOID, PCVOID)): New function types.
17966 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
17967 __builtin_ia32_directstoreu_u64,
17968 __builtin_ia32_movdir64b): New builtins.
17969 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
17970 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
17972 (ix86_valid_target_attribute_inner_p): Ditto.
17973 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
17974 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
17975 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
17976 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
17977 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
17978 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
17979 (movdiri<mode>, movdir64b_<mode>): New.
17980 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
17981 * config/i386/immintrin.h: Include movdirintrin.h.
17982 * config/i386/movdirintrin.h: New file.
17983 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
17985 2018-04-19 Richard Biener <rguenther@suse.de>
17987 PR middle-end/85455
17988 * cfg.c (clear_bb_flags): When loop state says we have
17989 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
17991 2018-04-19 Richard Biener <rguenther@suse.de>
17993 PR tree-optimization/84737
17994 * tree-vect-data-refs.c (vect_copy_ref_info): New function
17995 copying restrict info.
17996 (vect_setup_realignment): Use it.
17997 * tree-vectorizer.h (vect_copy_ref_info): Declare.
17998 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
17999 the first DR to all generated stores.
18000 (vectorizable_load): Likewise for loads.
18002 2018-04-19 Jakub Jelinek <jakub@redhat.com>
18004 PR tree-optimization/85446
18005 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
18006 the integral and pointer types to have the same precision.
18008 * doc/install.texi: Document --disable-cet being the default and
18011 2018-04-18 Martin Liska <mliska@suse.cz>
18013 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
18016 2018-04-18 Martin Liska <mliska@suse.cz>
18019 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
18022 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
18023 arguments if they are comparable.
18025 2018-04-18 Martin Liska <mliska@suse.cz>
18028 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
18031 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
18034 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
18037 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
18038 ENDBR after calling __morestack.
18040 2018-04-18 David Malcolm <dmalcolm@redhat.com>
18043 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
18044 by using gcc_base_ver to generate a gcc_driver_version, and use
18045 it when generating GCC_DRIVER_NAME.
18046 * configure: Regenerate.
18048 2018-04-18 Jakub Jelinek <jakub@redhat.com>
18051 * config.gcc: Obsolete powerpc*-*-*spe*.
18053 2018-04-17 Jakub Jelinek <jakub@redhat.com>
18056 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
18057 (stabstr_D): Change type of unum from unsigned int to
18058 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
18061 2018-04-17 Jim Wilson <jimw@sifive.com>
18064 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
18065 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
18066 Set arg_pointer_offset after using pretend_args_size.
18068 2018-04-17 Jakub Jelinek <jakub@redhat.com>
18070 PR rtl-optimization/85431
18071 * dse.c (record_store): Ignore zero width stores.
18074 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
18075 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
18076 __builtin_stack_restore rather than after it.
18077 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
18078 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
18079 argument instead of virtual_dynamic_stack_rtx.
18081 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
18083 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
18085 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
18086 Add note to error message to explain internal mapping of overloaded
18087 built-in function name to non-overloaded built-in function name.
18088 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
18091 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
18094 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
18095 where the inputs overlap with the output.
18097 2018-04-17 Jakub Jelinek <jakub@redhat.com>
18099 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
18100 (=v, v) alternative and explicit "memory" attribute.
18101 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
18102 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
18104 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
18105 "sselog1" type instead of "sselog".
18106 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
18107 "sselog". Remove explicit "memory" attribute.
18108 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
18109 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
18111 (vec_extract_hi_v32hi): Merge all alternatives into one, use
18112 "sselog1" type instead of "sselog". Remove explicit "memory"
18114 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
18115 use "sselog1" type instead of "sselog". Remove explicit "memory"
18117 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
18118 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
18120 (vec_extract_hi_v64qi): Merge all alternatives into one, use
18121 "sselog1" type instead of "sselog". Remove explicit "memory"
18123 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
18124 use "sselog1" type instead of "sselog". Remove explicit "memory"
18128 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
18130 PR middle-end/85414
18131 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
18134 2018-04-17 Martin Jambor <mjambor@suse.cz>
18137 * ipa-cp.c (create_specialized_node): Call
18138 expand_all_artificial_thunks if necessary.
18140 2018-04-17 Martin Liska <mliska@suse.cz>
18143 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
18144 in message, remote space in between '_G' and '('.
18146 2018-04-17 Jakub Jelinek <jakub@redhat.com>
18149 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
18150 avx512f_vmcmp<mode>3<round_saeonly_name>,
18151 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
18152 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
18153 avx512f_rndscale<mode><round_saeonly_name>,
18154 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
18155 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
18156 Use %<iptr>2 instead of %2 for -masm=intel.
18157 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
18158 avx512f_vcvttss2usi<round_saeonly_name>,
18159 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
18161 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
18162 avx512f_vcvttsd2usi<round_saeonly_name>,
18163 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
18164 Use %q1 instead of %1 for -masm=intel.
18165 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
18166 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
18167 of %3 for -masm=intel.
18168 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
18170 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
18172 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
18174 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
18175 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
18177 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
18179 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
18180 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
18181 %g1 and one with %0 and %1.
18182 (avx512er_vmrcp28<mode><round_saeonly_name>,
18183 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
18184 %1 for -masm=intel.
18185 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
18186 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
18187 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
18188 of %0 and %{%4%} for -masm=intel.
18189 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
18190 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
18191 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
18192 order of %0 and %{%5%}%{z%} for -masm=intel.
18194 2018-04-17 Jan Hubicka <jh@suse.cz>
18197 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
18199 2018-04-17 Martin Liska <mliska@suse.cz>
18202 * multiple_target.c (create_dispatcher_calls): Set apostrophes
18203 for target_clone error message. Make default implementation
18204 clone to be a local declaration.
18205 (separate_attrs): Add new argument and check for an empty
18207 (expand_target_clones): Handle it.
18208 (ipa_target_clone): Make redirection just for target_clones
18211 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
18212 Tom de Vries <tom@codesourcery.com>
18214 PR middle-end/84955
18215 * omp-expand.c (expand_oacc_for): Add dummy false branch for
18216 tiled basic blocks without omp continue statements.
18218 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
18221 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
18222 vec_extract expression as having side effects to make sure it gets
18225 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
18228 * config/i386/i386.c (get_builtin_code_for_version): Check
18231 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
18234 * config.gcc: Support "skylake".
18235 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
18237 * config/i386/i386.c (m_SKYLAKE): Define.
18238 (processor_target_table): Add "skylake".
18239 (ix86_option_override_internal): Add "skylake".
18240 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
18241 PROCESSOR_CANNONLAKE.
18242 (get_builtin_code_for_version): Fix priority for
18243 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
18244 PROCESSOR_SKYLAKE-AVX512.
18245 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
18246 (processor_type): Add PROCESSOR_SKYLAKE.
18248 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
18249 Jason Merrill <jason@redhat.com>
18252 * convert.c (convert_to_integer_1): Use direct recursion for
18253 enumeral types and types with a precision less than the number
18254 of bits in their mode.
18256 2018-04-16 Julia Koval <julia.koval@intel.com>
18259 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
18260 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
18262 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
18265 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
18266 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
18267 and -mno-direct-move.
18269 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
18272 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
18273 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
18274 Ensure negative shifts result in {0}.
18276 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
18278 PR rtl-optimization/79916
18279 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
18280 regs (if any) to define how to gnerate SD moves when LRA is in
18283 2018-04-13 Jakub Jelinek <jakub@redhat.com>
18285 PR rtl-optimization/85393
18286 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
18287 * except.c (expand_dw2_landing_pad_for_region): Make static.
18288 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
18289 a label and unconditional jump to old_bb, rather than
18290 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
18293 PR rtl-optimization/85376
18294 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
18295 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
18296 instead of a specific value.
18298 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
18299 Bin Cheng <bin.cheng@arm.com>
18301 PR tree-optimization/82965
18302 PR tree-optimization/83991
18303 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
18304 by_profile_only parameter.
18305 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
18306 information if the loop was predicted to iterate too many times.
18307 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
18309 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
18312 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
18315 2018-04-13 Martin Liska <mliska@suse.cz>
18316 Jakub Jelinek <jakub@redhat.com>
18318 PR middle-end/81657
18319 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
18320 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
18321 * builtins.c (expand_builtin_memory_copy_args): Use
18322 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
18323 handle dest_addr == pc_rtx.
18325 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
18328 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
18329 asked to not generate direct moves.
18330 (fix_trunc<mode>si2_stfiwx): Similar.
18331 (fix_trunc<mode>si2_internal): Similar.
18333 2018-04-12 Jakub Jelinek <jakub@redhat.com>
18336 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
18337 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
18338 lookup if dest in some wider mode is known to be const0_rtx and
18339 if so, record permanent equivalence for it to be ZERO_EXTEND of
18340 the narrower mode destination.
18342 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
18344 * lto-streamer-out.c (output_function): Revert 259346.
18345 * omp-expand.c (expand_oacc_for): Likewise.
18347 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
18349 PR rtl-optimization/85354
18350 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
18351 * sel-sched.c (sel_global_init): ... here.
18353 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
18356 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
18357 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
18358 mode for PE-COFF targets.
18359 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
18360 (i386_pe_asm_lto_end): Likewise.
18361 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
18362 (TARGET_ASM_LTO_END): Likewise.
18363 * config/i386/winnt.c (saved_debug_info_level): New static variable.
18364 (i386_pe_asm_lto_start): New function.
18365 (i386_pe_asm_lto_end): Likewise.
18367 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
18368 Richard Biener <rguenther@suse.de>
18370 PR middle-end/84955
18371 * lto-streamer-out.c (output_function): Fix CFG loop state before
18373 * omp-expand.c (expand_oacc_for): Handle calls to internal
18374 functions like regular functions.
18376 2018-04-12 Richard Biener <rguenther@suse.de>
18379 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
18380 for the early LTO debug to properly generate references to it
18381 during DIE emission. Do not re-use that for the skeleton for
18383 (dwarf2out_early_finish): Likewise.
18385 2018-04-12 Jakub Jelinek <jakub@redhat.com>
18388 * config/i386/sse.md
18389 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
18390 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
18391 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
18392 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
18393 and output is a reg, avoid creating invalid lowpart subreg, but
18394 instead split into a 512-bit move. Don't split if not AVX512VL,
18395 input is xmm16+ reg and output is a mem.
18396 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
18397 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
18398 xmm16+ reg and output is a mem.
18400 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
18402 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
18403 also for flag_dwarf2_cfi_asm.
18405 2018-04-12 Jakub Jelinek <jakub@redhat.com>
18407 PR rtl-optimization/85342
18408 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
18409 a bool scalar var inside of the loop instead. Don't try to update
18410 recog_data.operand after failed apply_change_group.
18412 2018-04-12 Tom de Vries <tom@codesourcery.com>
18415 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
18416 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
18417 array with flexible array member as array without given dimension.
18418 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
18419 argument for undefined param to true.
18421 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
18424 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
18425 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
18426 from PowerPC section.
18427 * config/rs6000/sysv4.opt (mcall-): Improve help text.
18428 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
18429 help text that is too long.
18430 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
18431 help text that is too long.
18432 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
18433 help text that is too long.
18435 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
18437 * config/alpha/alpha.md (stack_probe_internal): Rename
18438 from "probe_stack". Update all callers.
18440 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
18442 PR rtl-optimization/84566
18443 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
18444 sched_macro_fuse_insns.
18446 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
18449 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
18450 (compute_block_dependences): ... from here.
18452 2018-04-11 Jakub Jelinek <jakub@redhat.com>
18454 PR tree-optimization/85331
18455 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
18456 from int to HOST_WIDE_INT.
18458 2018-04-11 Martin Jambor <mjambor@suse.cz>
18461 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
18462 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
18463 not the same as the source val.
18464 (cgraph_edge_brings_value_p): New parameter.
18465 (gather_edges_for_value): Pass destination value to
18466 cgraph_edge_brings_value_p.
18467 (perhaps_add_new_callers): Likewise.
18468 (get_info_about_necessary_edges): Likewise and exclude values brought
18469 only by self-recursive edges.
18470 (create_specialized_node): Redirect only clones of self-calling edges.
18471 (+self_recursive_pass_through_p): New function.
18472 (find_more_scalar_values_for_callers_subset): Use it.
18473 (find_aggregate_values_for_callers_subset): Likewise.
18474 (known_aggs_to_agg_replacement_list): Removed.
18475 (decide_whether_version_node): Re-calculate known constants for all
18476 remaining context clones.
18478 2018-04-11 Richard Biener <rguenther@suse.de>
18481 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
18482 from early DWARF output.
18483 (dwarf2out_early_finish): Output line info unconditionally into
18484 early DWARF and add reference to it.
18486 2018-04-11 Jakub Jelinek <jakub@redhat.com>
18489 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
18490 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
18491 other than V2DFmode using iptr mode attribute.
18492 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
18494 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
18496 PR rtl-optimization/84659
18497 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
18499 2018-04-11 Jakub Jelinek <jakub@redhat.com>
18502 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
18504 (output_loc_list): Pass address of a dummy size variable even in the
18505 locview handling loop.
18506 (index_location_lists): Add comment on why skip_loc_list_entry can't
18509 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
18512 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
18515 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
18518 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
18519 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
18520 and -mstring-compare-inline-limit.
18522 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
18525 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
18526 for stack clash protection in a register whenever we need it to be in
18529 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
18531 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
18532 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
18534 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
18537 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
18539 (mlong-double-): Ditto.
18540 * config/rs6000/sysv4.opt (msdata=): Ditto.
18541 (mtls-size=): Ditto.
18543 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
18545 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
18546 erroneous entries for
18547 "vector int vec_ldl (int, long int *)", and
18548 "vector unsigned int vec_ldl (int, unsigned long int *)".
18549 Add comments and entries for
18550 "vector bool char vec_ldl (int, bool char *)",
18551 "vector bool short vec_ldl (int, bool short *)",
18552 "vector bool int vec_ldl (int, bool int *)",
18553 "vector bool long long vec_ldl (int, bool long long *)",
18554 "vector pixel vec_ldl (int, pixel *)",
18555 "vector long long vec_ldl (int, long long *)",
18556 "vector unsigned long long vec_ldl (int, unsigned long long *)".
18557 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
18558 type tree bool_long_long_type_node and correct definition of
18559 bool_V2DI_type_node to make reference to this new type tree.
18560 (rs6000_mangle_type): Replace erroneous reference to
18561 bool_long_type_node with bool_long_long_type_node.
18562 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
18563 comments to emphasize sign distinctions for char and int types and
18564 replace RS6000_BTI_bool_long constant with
18565 RS6000_BTI_bool_long_long constant. Also add comment to restrict
18566 use of RS6000_BTI_pixel.
18567 (bool_long_type_node): Remove this macro definition.
18568 (bool_long_long_type_node): New macro definition
18570 2018-04-10 Jakub Jelinek <jakub@redhat.com>
18572 PR rtl-optimization/85300
18573 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
18574 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
18575 simplify_unary_operation fails.
18577 2018-04-10 Martin Liska <mliska@suse.cz>
18579 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
18580 cgraph_edge and ipa_ref.
18582 2018-04-10 Jakub Jelinek <jakub@redhat.com>
18586 * config/i386/sse.md
18587 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
18588 computation of the VEC_MERGE selector from mask.
18589 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
18590 Fix decoding of the VEC_MERGE selector into mask.
18592 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
18594 PR tree-optimization/85286
18595 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
18597 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
18599 * final.c (final_1): Set insn_last_address as well as
18600 insn_current_address.
18602 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18605 * explow.c (emit_stack_probe): Call validize_mem on memory location
18606 before passing it to gen_probe_stack. Create address operand and
18607 legitimize it for the probe_stack_address case.
18609 2018-04-09 Jan Hubicka <jh@suse.cz>
18612 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
18613 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
18614 * tree.c (free_lang_data_in_type): Fix handling of binfos;
18616 (free_lang_data): Rebuild type inheritance graph.
18618 2018-04-09 Martin Sebor <msebor@redhat.com>
18620 * invoke.texi (-finline-small-functions): Mention other optimization
18622 (-findirect-inlining, -fpartial-inlining): Same.
18623 (-finline-functions-called-once): Same.
18624 (-freorder-blocks-and-partition): Same.
18626 2018-04-09 Jan Hubicka <jh@suse.cz>
18629 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
18630 jumps; choose last target that matches the criteria (i.e.
18631 no partition changes for non-crossing jumps).
18632 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
18633 support for redirecting crossing jumps to non-crossing.
18635 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
18637 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
18638 also for naked functions.
18640 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
18642 * config/arc/arc.md (add_shift): New pattern.
18643 (add_shift2): Likewise.
18644 (sub_shift): Likewise.
18645 (sub_shift_cmp0_noout): Likewise.
18646 (compare_si_ashiftsi): Likewise.
18647 (xbfu_cmp0_noout): New combine pattern.
18648 (xbfu_cmp0"): Likewise.
18649 (movsi_set_cc_insn): Place the predicable variant first.
18650 (commutative_binary_cmp0_noout): Remove clobber.
18651 (commutative_binary_cmp0): New pattern.
18652 (noncommutative_binary_cmp0): Likewise.
18653 (noncommutative_binary_cmp0_noout): Likewise.
18654 (noncommutative_binary_comparison_result_used): Removed.
18655 (rsub_cmp0): New pattern.
18656 (rsub_cmp0_noout): Likewise.
18657 (extzvsi): Changed, keep only meaningful variants.
18658 (SQH, SEZ): New iterators.
18659 (SQH_postfix): New mode attribute.
18660 (SEZ_prefix): New code attribute.
18661 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
18662 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
18663 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
18664 of numerical value.
18665 (noncommutative_operator): Check the availability of barrel
18668 2018-04-09 Richard Biener <rguenther@suse.de>
18670 PR tree-optimization/85284
18671 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
18672 Only use the niter constraining form of simple_iv when the exit
18673 is always executed.
18675 2018-04-09 Tom de Vries <tom@codesourcery.com>
18678 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
18679 (define_expand "*memory_barrier"): New define_expand.
18680 (define_insn "memory_barrier"): New insn.
18682 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
18684 PR rtl-optimization/80463
18685 PR rtl-optimization/83972
18686 PR rtl-optimization/83480
18688 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
18689 correct producer for the insn.
18690 (tidy_control_flow): Fixup seqnos in case of debug insns.
18692 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
18694 PR rtl-optimization/83913
18696 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
18697 different sched-times when merging exprs.
18699 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
18701 PR rtl-optimization/83962
18703 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
18704 tidy_fallthru_edge and tidy_control_flow.
18706 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
18708 PR rtl-optimization/83530
18710 * sel-sched.c (force_next_insn): New global variable.
18711 (remove_insn_for_debug): When force_next_insn is true, also leave only
18712 next insn in the ready list.
18713 (sel_sched_region): When the region wasn't scheduled, make another pass
18714 over it with force_next_insn set to 1.
18716 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
18718 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
18720 * config/nds32/constants.md (unspec_volatile_element): Add enum values
18721 for interrupt control.
18722 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
18723 functions for interrupt control.
18724 * config/nds32/nds32-intrinsic.md: Likewise.
18725 * config/nds32/nds32_intrinsic.h: Likewise.
18726 * config/nds32/nds32.h (nds32_builtins): Likewise.
18728 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
18730 * config/nds32/nds32.c (nds32_init_machine_status,
18731 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
18732 strict_aligned_p field.
18733 (nds32_expand_to_rtl_hook): New function.
18734 (TARGET_EXPAND_TO_RTL_HOOK): Define.
18735 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
18737 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
18738 Chung-Ju Wu <jasonwucj@gmail.com>
18740 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
18741 * config/nds32/nds32-n7.md: New file.
18742 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
18743 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
18745 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
18746 * config/nds32/nds32.md (pipeline_model): Add n7.
18747 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
18748 * config/nds32/pipelines.md: Include n7 settings.
18750 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
18751 Chung-Ju Wu <jasonwucj@gmail.com>
18753 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
18754 * config/nds32/nds32-e8.md: New file.
18755 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
18756 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
18758 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
18759 * config/nds32/nds32.md (pipeline_model): Add e8.
18760 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
18761 * config/nds32/pipelines.md: Include e8 settings.
18763 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
18764 Chung-Ju Wu <jasonwucj@gmail.com>
18766 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
18767 * config/nds32/nds32-n8.md: New file.
18768 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
18769 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
18771 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
18772 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
18773 * config/nds32/nds32.md (pipeline_model): Add n8.
18774 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
18775 * config/nds32/pipelines.md: Include n8 settings.
18777 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
18778 Chung-Ju Wu <jasonwucj@gmail.com>
18780 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
18781 * config/nds32/nds32-n9-2r1w.md: New file.
18782 * config/nds32/nds32-n9-3r2w.md: New file.
18783 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
18784 nds32_register_ports): New or modify for cpu n9.
18785 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
18787 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
18788 * config/nds32/nds32-utils.c: New file.
18789 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
18790 TARGET_MUL_SLOW): Define.
18791 * config/nds32/nds32.md (pipeline_model): New attribute.
18792 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
18793 New options that support cpu n9.
18794 * config/nds32/pipelines.md: Include n9 settings.
18795 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
18797 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
18799 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
18800 information if necessary.
18801 (output_cond_branch_compare_zero): Likewise.
18802 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
18803 (nds32_target_alignment): Refine for alignment.
18804 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
18805 (FUNCTION_BOUNDARY): Modify.
18806 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
18808 * config/nds32/nds32.opt (malways-align, malign-functions): New.
18810 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
18812 * config/nds32/constants.md (unspec_volatile_element): Add values for
18813 TLB operation and data prefetch.
18814 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
18815 functions for TLB operation and data prefetch.
18816 * config/nds32/nds32-intrinsic.md: Likewise.
18817 * config/nds32/nds32_intrinsic.h: Likewise.
18818 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
18819 (nds32_print_operand): Likewise.
18820 * config/nds32/nds32.h (nds32_builtins): Likewise.
18822 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
18823 Andrew Pinski <pinsika@gcc.gnu.org>
18825 PR middle-end/82976
18826 * match.pd: Use constant_boolean_node of correct type instead of
18827 boolean_true_node or boolean_false_node for simplifying
18828 pointer comparisons to zero.
18830 2018-04-07 Jakub Jelinek <jakub@redhat.com>
18832 PR tree-optimization/80021
18833 * tree.c (verify_type_variant): Make error call in verify_variant_match
18834 translatable and remove final full stop.
18836 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
18838 * config/nds32/constants.md (unspec_volatile_element): Add
18839 UNSPEC_VOLATILE_EH_RETURN.
18840 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
18841 nds32_output_stack_pop): Support dwarf exception handling process.
18842 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
18843 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
18844 exception handling process.
18845 (nds32_compute_stack_frame): Likewise.
18846 (nds32_return_addr_rtx): Likewise.
18847 (nds32_initial_elimination_offset): Likewise.
18848 (nds32_expand_prologue): Likewise.
18849 (nds32_expand_epilogue): Likewise.
18850 (nds32_dynamic_chain_address): New function.
18851 * config/nds32/nds32.h (machine_function): Add fields for dwarf
18852 exception handling.
18853 (DYNAMIC_CHAIN_ADDRESS): Define.
18854 (EH_RETURN_DATA_REGNO): Define.
18855 (EH_RETURN_STACKADJ_RTX): Define.
18856 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
18857 patterns for dwarf exception handling.
18859 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
18861 * config/nds32/nds32.h: Clean up obsolete macros.
18863 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
18865 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
18866 Add enum values for particular instructions.
18867 * config/nds32/nds32-intrinsic.c: Implementation of expanding
18868 particular intrinsic functions.
18869 * config/nds32/nds32-intrinsic.md: Likewise.
18870 * config/nds32/nds32_intrinsic.h: Likewise.
18871 * config/nds32/nds32.h (nds32_builtins): Likewise.
18872 * config/nds32/nds32.md (type): Add pbsad and pbsada.
18873 (btst, ave): New patterns for particular instructions.
18875 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
18877 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
18878 Add enum values for atomic load/store and memory sync.
18879 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
18881 * config/nds32/nds32-intrinsic.md: Likewise.
18882 * config/nds32/nds32_intrinsic.h: Likewise.
18883 * config/nds32/nds32.h (nds32_builtins): Likewise.
18885 2018-04-07 Jakub Jelinek <jakub@redhat.com>
18887 PR tree-optimization/85257
18888 * fold-const.c (native_encode_vector): If not all elts could fit
18889 and off is -1, return 0 rather than offset.
18890 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
18891 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
18892 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
18893 adjust buffer in native_interpret_expr call.
18895 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
18897 * config/nds32/constants.md (unspec_volatile_element): Add cache
18898 control enum values.
18899 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
18900 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
18901 * config/nds32/nds32.c (nds32_cctl_names): New.
18902 (nds32_print_operand): Handle cache control register names.
18903 * config/nds32/nds32.h (nds32_builtins): New enum values.
18904 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
18906 * config/nds32/nds32.md (type): Add mmu.
18907 * config/nds32/pipelines.md (simple_insn): Add mmu.
18909 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
18911 * config/nds32/nds32.md (type): Remove call.
18912 * config/nds32/pipelines.md (simple_insn): Likewise.
18914 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
18916 * config/nds32/constants.md (unspec_volatile_element): Add
18917 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
18918 UNSPEC_VOLATILE_FMFCFG.
18919 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
18920 description for fmfcfg and fmfcsr.
18921 (bdesc_1arg): Add fmtcsr.
18922 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
18923 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
18924 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
18925 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
18926 unspec_fmfcfg): New patterns.
18927 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
18928 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
18929 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
18930 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
18931 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
18932 __nds32__fmfcfg): Define.
18934 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
18936 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
18937 intrinsic register names.
18938 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
18939 intrinsic register enum values and macros.
18941 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
18943 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
18944 for load/store addressing form.
18945 (nds32_print_operand_address): Likewise.
18947 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
18950 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
18951 based on LABEL_REF. Remove useless assertion.
18952 (pic_address_needs_scratch): Fix formatting.
18953 (sparc_legitimize_pic_address): Minor tweaks.
18954 (sparc_delegitimize_address): Adjust assertion accordingly.
18955 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
18956 into symbolic_operand.
18957 (movsi_high_pic_label_ref): Likewise.
18958 (movsi_lo_sum_pic_label_ref): Likewise.
18959 (movdi_pic_label_ref): Likewise.
18960 (movdi_high_pic_label_ref): Likewise.
18961 (movdi_lo_sum_pic_label_ref): Likewise.
18963 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
18965 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
18966 custom LIB_SPEC setup.
18968 2018-04-06 Ruslan Bukin <br@bsdpad.com>
18969 Kito Cheng <kito.cheng@gmail.com>
18971 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
18972 * config/riscv/freebsd.h: New.
18974 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
18976 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
18977 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
18980 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
18981 Kito Cheng <kito.cheng@gmail.com>
18983 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
18984 nds32_output_call, nds32_symbol_binds_local_p): New functions.
18985 * config/nds32/nds32-protos.h (nds32_output_call,
18986 nds32_output_return): Declare.
18987 * config/nds32/nds32.md: Refine all the call and return patterns.
18989 2018-04-06 Jakub Jelinek <jakub@redhat.com>
18992 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
18993 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
18995 PR rtl-optimization/84872
18996 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
18997 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
18998 EDGE_CROSSING edge.
19000 2018-04-06 Tamar Christina <tamar.christina@arm.com>
19002 * expr.c (copy_blkmode_to_reg): Revert 254862.
19003 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
19005 2018-04-06 Richard Biener <rguenther@suse.de>
19007 PR middle-end/85244
19008 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
19009 after seeing a component reference with an adjacent field. Treat
19010 refs to arrays at struct end of external decls similar to
19011 refs to unconstrained commons.
19013 2018-04-06 Jakub Jelinek <jakub@redhat.com>
19016 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
19017 look through SAVE_EXPRs with non-side-effects argument. Adjust
19019 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
19022 2018-04-06 Richard Biener <rguenther@suse.de>
19024 PR middle-end/85180
19025 * alias.c (find_base_term): New wrapper around find_base_term
19026 unwinding CSELIB_VAL_PTR changes.
19027 (find_base_term): Do not restore CSELIB_VAL_PTR during the
19030 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
19032 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
19034 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
19035 constant definitions.
19036 ("nop"): lr 0,0 -> nopr r0
19037 ("nop_lr0", "nop_lr1"): New insn definitions.
19039 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
19041 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
19042 NDS32_V3PUSH_AVAILABLE_P macro.
19044 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
19045 Chung-Ju Wu <jasonwucj@gmail.com>
19047 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
19048 (nds32*-*-*): Add float and fpu_config into supported_defaults.
19049 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
19050 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
19051 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
19052 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
19053 * config/nds32/constraints.md: New constraints and checking for hard
19054 float configuration.
19055 * config/nds32/iterators.md: New mode iterator and attribute for hard
19056 float configuration.
19057 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
19059 * config/nds32/nds32-fpu.md: New file.
19060 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
19061 deal with hard float code generation.
19062 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
19064 (abi_type, float_reg_number): New enum type.
19065 * config/nds32/nds32-predicates.c: New predicates for hard float.
19066 * config/nds32/nds32-protos.h: Declare functions for hard float.
19067 * config/nds32/nds32.c: Implementation for hard float configuration.
19068 * config/nds32/nds32.h: Definitions for hard float configuration.
19069 * config/nds32/nds32.md: Include hard float machine description and
19070 modify patterns for hard float configuration.
19071 * config/nds32/nds32.opt: New options for hard float configuration.
19072 * config/nds32/predicates.md: New predicates for hard float
19075 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
19077 * common/config/nds32/nds32-common.c
19078 (nds32_option_optimization_table): Enable -mreleax-hint by default.
19080 2018-04-05 Jakub Jelinek <jakub@redhat.com>
19082 PR middle-end/85195
19083 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
19084 CONSTRUCTOR_ELT (ctor, ...)->value.
19086 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
19089 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
19091 2018-04-05 Tom de Vries <tom@codesourcery.com>
19094 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
19097 2018-04-05 Shiva Chen <shiva0217@gmail.com>
19098 Kito Cheng <kito.cheng@gmail.com>
19100 * config/nds32/constraints.md (U33): Fine-tune checking condition.
19101 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
19102 * config/nds32/nds32.h (nds32_16bit_address_type): Add
19103 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
19105 2018-04-05 Shiva Chen <shiva0217@gmail.com>
19106 Kito Cheng <kito.cheng@gmail.com>
19108 * config/nds32/constraints.md (Ufe): New memory constraint.
19109 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
19110 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
19111 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
19113 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
19114 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
19116 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19118 * config/nds32/nds32.md: Use optimize_size in the condition for
19119 alu-shift instructions.
19121 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19123 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
19125 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19127 * config/nds32/nds32.md (negsi2): Refine pattern.
19129 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
19130 Chung-Ju Wu <jasonwucj@gmail.com>
19132 * config/nds32/iterators.md (shift_rotate): New code iterator.
19133 (shift): New code attribute.
19134 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
19135 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
19136 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
19137 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
19138 bit-wise operations.
19139 (andsi3, *andsi3): Ditto.
19140 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
19141 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
19142 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
19143 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
19144 nds32_ior_operand, nds32_xor_operand): New predicates.
19146 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19148 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
19149 (addsi3, subsi3): ... this.
19151 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19153 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
19155 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19157 * config/nds32/nds32.md: Adjust indention.
19159 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
19161 * config/nds32/nds32.md (feature): New attribute.
19163 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
19165 * config/nds32/nds32.md (subtype): New attribute.
19167 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
19170 * config/arm/arm-builtins.c (arm_expand_builtin): Change
19171 expansion to perform a bitwise AND of the argument followed by a
19172 boolean negation of the result.
19174 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
19176 PR rtl-optimization/84878
19177 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
19178 the basic block. Assert the use reference is not artificial and that
19179 it has an associated insn.
19181 2018-04-04 Michael Matz <matz@suse.de>
19183 * builtins.c (compute_objsize): Pass correct operand
19184 to array_at_struct_end_p.
19186 2018-04-04 Richard Biener <rguenther@suse.de>
19189 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
19190 from contexts for DINFO_LEVEL_TERSE and below.
19192 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
19194 * config/nds32/nds32-doubleword.md (move_<mode>): Require
19195 resiter_operand condition.
19196 * config/nds32/nds32.md (*move<mode>): Ditto.
19198 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
19199 Monk Chiang <sh.chiang04@gmail.com>
19201 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
19203 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
19205 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
19207 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
19208 Kito Cheng <kito.cheng@gmail.com>
19210 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
19211 nds32_cond_code_str, output_cond_branch,
19212 output_cond_branch_compare_zero, nds32_expand_cbranch,
19213 nds32_expand_cstore, nds32_expand_movcc,
19214 nds32_output_cbranchsi4_equality_zero,
19215 nds32_output_cbranchsi4_equality_reg,
19216 nds32_output_cbranchsi4_equality_reg_or_const_int,
19217 nds32_output_cbranchsi4_greater_less_zero: New functions.
19218 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
19219 nds32_expand_cstore, nds32_expand_movcc,
19220 nds32_output_cbranchsi4_equality_zero,
19221 nds32_output_cbranchsi4_equality_reg,
19222 nds32_output_cbranchsi4_equality_reg_or_const_int,
19223 nds32_output_cbranchsi4_greater_less_zero): Declare.
19224 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
19225 nds32_rimm11s_operand): New predicates.
19226 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
19227 * config/nds32/nds32.md: Rewrite all the branch and conditional move
19230 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
19232 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
19233 * config/nds32/nds32.md: Ditto.
19234 * config/nds32/pipelines.md: Ditto.
19236 2018-04-04 Richard Biener <rguenther@suse.de>
19238 PR tree-optimization/85168
19239 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
19240 propagating abnormals.
19242 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
19244 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
19246 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
19247 Kito Cheng <kito.cheng@gmail.com>
19249 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
19250 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
19251 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
19252 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
19253 * config/nds32/nds32.md (sibcall_internal): New.
19254 (sibcall_register): Remove.
19255 (sibcall_immediate): Remove.
19256 (sibcall_value_internal): New.
19257 (sibcall_value_register): Remove.
19258 (sibcall_value_immediate): Remove.
19259 * config/nds32/predicates.md (nds32_general_register_operand): New.
19260 (nds32_call_address_operand): New.
19262 2018-04-03 Jakub Jelinek <jakub@redhat.com>
19264 PR rtl-optimization/85167
19265 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
19266 bb_defs if *split_p, instead preinitialize it to NULL.
19268 PR tree-optimization/85156
19269 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
19270 evaluating the argument multiple times.
19272 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
19274 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
19276 (_mm_cvtpd_ps): Likewise.
19277 (_mm_cvttpd_epi32): Likewise.
19278 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
19279 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
19280 vector, pixel, and bool following altivec.h include.
19282 2018-04-03 Martin Sebor <msebor@redhat.com>
19284 * doc/extend.texi (Common Function Attributes): Clarify.
19285 (const attribute): Likewise.
19286 (pure attribute): Likewise.
19288 2018-04-03 Jakub Jelinek <jakub@redhat.com>
19291 * config/i386/i386.c (ix86_expand_vector_set): Use
19292 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
19294 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
19296 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
19297 instructions when changing rounding bits to preserve precision bits
19298 in the x87 control word.
19300 2018-04-03 Martin Liska <mliska@suse.cz>
19302 PR tree-optimization/82491
19303 * rtl.h (strip_offset_and_add): Replace += suboffset with
19304 poly_uint64 () + suboffset.
19306 2018-03-29 Martin Liska <mliska@suse.cz>
19307 Martin Jambor <mjambor@suse.cz>
19310 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
19311 param_type is not an integral or pointer type.
19313 2018-04-03 Richard Biener <rguenther@suse.de>
19315 * sese.h (recompute_all_dominators): Remove.
19317 2018-04-02 Martin Sebor <msebor@redhat.com>
19319 * doc/invoke.texi (-Wrestrict): Fix typos.
19321 2018-04-02 Jim Wilson <jimw@sifive.com>
19323 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
19324 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
19325 (<optab>di3, <optab>si3_extend): Likewise.
19326 (<optab>si3_mask, <optab>si3_mask_1): New.
19327 (<optab>di3_mask, <optab>di3_mask_1): New.
19328 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
19329 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
19330 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
19332 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
19334 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
19337 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
19339 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
19340 (nds32_canonicalize_comparison): New function.
19342 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
19343 Kito Cheng <kito.cheng@gmail.com>
19344 Kuan-Lin Chen <kuanlinchentw@gmail.com>
19346 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
19347 * config/nds32/constants.md (unspec_volatile_element): Add
19348 UNSPEC_VOLATILE_RELAX_GROUP.
19349 * config/nds32/nds32-relax-opt.c: New file.
19350 * config/nds32/nds32-predicates.c
19351 (nds32_symbol_load_store_p): New function.
19352 * config/nds32/nds32-protos.h
19353 (nds32_symbol_load_store_p): Declare function.
19354 (make_pass_nds32_relax_opt): Declare new rtl pass function.
19355 * config/nds32/nds32.c
19356 (nds32_register_pass): New function to register pass.
19357 (nds32_register_passes): New function to register passes.
19358 * config/nds32/nds32.md (relax_group): New pattern.
19359 * config/nds32/nds32.opt (mrelax-hint): New option.
19360 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
19362 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
19364 * config/nds32/t-nds32: Modify files dependency.
19366 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
19368 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
19369 (PROFILE_HOOK): Define its implementation.
19371 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
19373 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
19374 type and 32-bit size.
19376 2018-04-01 Jakub Jelinek <jakub@redhat.com>
19378 PR middle-end/85090
19379 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
19380 (V_128_256): New mode iterator.
19381 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
19382 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
19383 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
19385 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
19386 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
19388 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
19391 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
19392 NaN inputs correctly.
19394 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
19397 * config/rs6000/vsx.md (??r): New mode attribute.
19398 (*vsx_mov<mode>_64bit): Use it.
19399 (*vsx_mov<mode>_32bit): Likewise.
19401 2018-03-30 Martin Sebor <msebor@redhat.com>
19403 PR tree-optimization/84818
19404 * builtins.c (check_access): Use warning_n.
19406 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
19409 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
19411 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
19414 2018-03-30 Julia Koval <julia.koval@intel.com>
19417 * x86-tune.def (movx, partial_reg_dependency): Enable for
19420 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
19422 PR inline-asm/84985
19423 * lra-constraints.c (process_alt_operands): Move setting
19424 this_alternative_matches below.
19426 2018-03-29 Martin Liska <mliska@suse.cz>
19429 * doc/invoke.texi: Document how LTO works with debug info.
19430 Describe auto-load support of binutils. Mention 'x86-64'
19431 as valid option value of -march option.
19433 2018-03-29 Jakub Jelinek <jakub@redhat.com>
19435 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
19438 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
19439 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
19440 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
19443 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
19446 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
19447 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
19448 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
19449 for RS6000_BTM_POWERPC64.
19450 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
19451 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
19452 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
19455 (DIVDEU): Likewise.
19457 2018-03-28 Carl Love <cel@us.ibm.com>
19460 2017-09-27 Carl Love <cel@us.ibm.com>
19462 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
19463 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
19464 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
19467 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
19469 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
19470 instead of __vector bool.
19471 (_mm_max_pu8): Likewise.
19472 (_mm_min_pi16): Likewise.
19474 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
19477 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
19478 (DIVWEUO): Likewise.
19479 (DIVDEO): Likewise.
19480 (DIVDEUO): Likewise.
19481 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
19482 DIVWEUO and DIVDEUO.
19483 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
19484 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
19485 (div_extend): Likewise.
19486 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
19488 (__builtin_divweuo): Likewise.
19489 (__builtin_divdeo): Likewise.
19490 (__builtin_divdeuo): Likewise.
19492 2018-03-28 Jakub Jelinek <jakub@redhat.com>
19495 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
19496 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
19498 PR tree-optimization/82004
19499 * gimple-match-head.c (optimize_pow_to_exp): New function.
19500 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
19501 Don't fold to exp if optimize_pow_to_exp is false.
19503 2018-03-28 Martin Liska <mliska@suse.cz>
19506 * calls.c (initialize_argument_information): Fix trailing space.
19507 * common.opt: Fix typo and provide better explanation for
19508 -fsanitize-coverage option.
19509 * config/i386/i386.opt: Fix typo.
19511 2018-03-28 Jakub Jelinek <jakub@redhat.com>
19512 Martin Liska <mliska@suse.cz>
19515 * gimplify.c (asan_poison_variable): Don't do the check for
19516 gimplify_omp_ctxp here.
19517 (gimplify_decl_expr): Do it here.
19518 (gimplify_target_expr): Likewise.
19520 2018-03-28 Martin Liska <mliska@suse.cz>
19523 * config/i386/i386.c (ix86_function_arg_advance): Do not call
19524 chkp_type_bounds_count if MPX is not enabled.
19526 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
19528 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
19530 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
19533 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
19534 function to create the function decl for complex long double
19535 multiply and divide for -mabi=ieeelongdouble.
19536 (init_float128_ieee): Call it.
19538 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
19541 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
19542 -fcf-protection=branch -mibt.
19543 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
19545 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
19548 * config/arm/arm.c (arm_valid_symbolic_address): Handle
19549 arm_word_relocations.
19551 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
19554 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
19555 extern array declarations.
19557 2018-03-27 Richard Biener <rguenther@suse.de>
19559 PR middle-end/84067
19560 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
19561 explicit single_use checks.
19563 2018-03-27 Richard Biener <rguenther@suse.de>
19565 PR tree-optimization/85082
19566 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
19569 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
19571 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
19572 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
19573 Turn on fasynchronous-unwind-tables and funwind-tables.
19575 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
19578 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
19579 (*bmi_blsr_<mode>_ccz): Ditto.
19581 2018-03-26 Tom de Vries <tom@codesourcery.com>
19583 PR tree-optimization/85063
19584 * omp-general.c (offloading_function_p): New function. Factor out
19586 * omp-offload.c (pass_omp_target_link::gate): ... here.
19587 * omp-general.h (offloading_function_p): Declare.
19588 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
19589 with attribute omp declare target for offloading functions.
19591 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
19593 PR tree-optimization/84005
19594 * tree-data-ref.h (get_base_for_alignment): Declare.
19595 * tree-data-ref.c (get_base_for_alignment_1): New function.
19596 (get_base_for_alignment): Likewise.
19597 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
19598 get_base_for_alignment to find a suitable base object, instead
19599 of always using drb->base_address.
19601 2018-03-23 Jakub Jelinek <jakub@redhat.com>
19603 PR inline-asm/85022
19604 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
19605 known size by default.
19607 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
19609 PR inline-asm/85030
19610 * lra-constraints.c (process_alt_operands): Don't match BLKmode
19611 and non BLKmode operands.
19613 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
19616 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
19617 Clean up attributes.
19619 2018-03-23 Richard Biener <rguenther@suse.de>
19622 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
19623 we are going to emit early debug for LTO.
19625 2018-03-23 Jakub Jelinek <jakub@redhat.com>
19627 PR inline-asm/85034
19628 * function.c (match_asm_constraints_1): Don't optimize if input
19629 doesn't satisfy general_operand predicate for output's mode.
19631 PR inline-asm/85022
19632 * alias.c (write_dependence_p): Don't require for x_canonicalized
19633 non-VOIDmode if x has VOIDmode.
19636 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
19637 just don't try to optimize it rather than assert it never happens.
19639 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
19641 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
19642 macro expansions for definition of ST_INTERNAL_<mode> and
19643 LD_INTERNAL_<mode> builtins.
19644 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
19646 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
19648 (altivec_expand_st_builtin): Likewise.
19649 (altivec_expand_builtin): Remove calls to deleted functions.
19650 (rs6000_address_for_altivec): Delete this function.
19651 * config/rs6000/vector.md: Remove expands for
19652 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
19654 2018-03-22 Sudakshina Das <sudi.das@arm.com>
19657 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
19658 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
19659 re-computing once computed.
19660 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
19661 (arm_init_machine_status): Initialize
19662 machine->static_chain_stack_bytes.
19664 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
19667 * doc/extend.texi: Add four new prototypes for vec_ld.
19668 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
19669 definitions for more logical presentation.
19670 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
19671 entries for V1TI variants of __builtin_altivec_ld builtin.
19672 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
19673 handling of V1TI variant of LVX icode pattern.
19674 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
19675 (rs6000_gimple_fold_builtin): Likewise.
19676 (altivec_init_builtins): Add code to define
19677 __builtin_altivec_lvx_v1ti function.
19679 2018-03-22 Jakub Jelinek <jakub@redhat.com>
19681 PR inline-asm/84941
19682 * function.c (match_asm_constraints_1): Don't do the optimization
19683 if input isn't a REG, SUBREG, MEM or constant.
19685 2018-03-22 Tom de Vries <tom@codesourcery.com>
19687 PR tree-optimization/84956
19688 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
19689 bb_has_abnormal_pred.
19691 2018-03-22 Jakub Jelinek <jakub@redhat.com>
19694 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
19695 DECL_INITIAL (decl) to decl at the end.
19696 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
19697 adjust the comment.
19699 2018-03-21 Joseph Myers <joseph@codesourcery.com>
19701 * doc/extend.texi (__builtin_tgmath): Document when complex
19702 integer types are treated as _Complex _Float64.
19704 2018-03-21 Tom de Vries <tom@codesourcery.com>
19706 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
19708 2018-03-21 Jakub Jelinek <jakub@redhat.com>
19710 PR tree-optimization/84960
19711 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
19712 if it is ENTRY block, move them into single succ of ENTRY in that case.
19714 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
19716 PR tree-optimization/84811
19717 * poly-int.h (poly_span_traits): Remove the T3 parameter and
19718 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
19719 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
19720 (known_subrange_p): Update accordingly. Cast each value involved
19721 in the size comparison, rather than casting the result of the
19724 2018-03-21 Jakub Jelinek <jakub@redhat.com>
19726 PR tree-optimization/84982
19727 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
19728 by flipping the least significant bit rather than all bits from
19729 bitpos to bitpos + bitsize - 1.
19731 2018-03-21 Nathan Sidwell <nathan@acm.org>
19733 * doc/extend.texi (Deprecated Features): Remove mention of
19734 long-deleted deprecations.
19736 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
19739 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
19740 * configure: Regenerate.
19742 2018-03-21 Tom de Vries <tom@codesourcery.com>
19744 PR tree-optimization/83126
19745 * tree-parloops.c (num_phis): New function.
19746 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
19748 2018-03-21 Nathan Sidwell <nathan@acm.org>
19750 * doc/extend.texi (Deprecated Features): Update deprecated flags,
19751 mention anon-struct/union members and trailing attributes.
19753 2018-03-21 Bin Cheng <bin.cheng@arm.com>
19755 PR tree-optimization/84969
19756 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
19757 builtin memset partitions if they set different rhs values.
19759 2018-03-21 Jakub Jelinek <jakub@redhat.com>
19761 PR rtl-optimization/84989
19762 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
19763 VEC_DUPLICATE with scalar result mode.
19765 2018-03-21 Martin Liska <mliska@suse.cz>
19768 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
19769 not intended return statement.
19771 2018-03-21 Martin Liska <mliska@suse.cz>
19774 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
19775 (chkp_find_bound_slots_1): Limit number of iterations.
19777 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
19780 * Minor grammar fixes for x86 options.
19782 2018-03-20 Jakub Jelinek <jakub@redhat.com>
19785 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
19786 holding REG_CFA_RESTORE notes, instead turn them into a USE.
19788 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
19791 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
19792 (altivec_lvx_<mode>_1op): Likewise.
19793 (altivec_stvx_<mode>_2op): Likewise.
19794 (altivec_stvx_<mode>_1op): Likewise.
19795 (altivec_lvx_<VM2:mode>): New define_expand.
19796 (altivec_stvx_<VM2:mode>): Likewise.
19797 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
19798 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
19799 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
19800 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
19801 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
19802 (rs6000_gen_lvx): Likewise.
19803 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
19804 (altivec_expand_stv_builtin): Likewise.
19805 (altivec_expand_builtin): Likewise.
19806 * config/rs6000/vector.md: Likewise.
19808 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
19811 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
19814 2018-03-20 Richard Biener <rguenther@suse.de>
19817 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
19818 sign-conversions as zero, fall back to standard scalar_stmt
19821 2018-03-20 Martin Liska <mliska@suse.cz>
19824 * predict.c (rebuild_frequencies): Handle case when we have
19825 PROFILE_ABSENT, but flag_guess_branch_prob is false.
19827 2018-03-20 Jakub Jelinek <jakub@redhat.com>
19830 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
19831 flag_section_anchors.
19832 * varasm.c (use_blocks_for_decl_p): Remove hack for
19833 dw2_force_const_mem.
19836 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
19838 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
19839 be created, use lowpart_subreg of operands[0] rather than operands[0]
19841 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
19842 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
19843 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
19844 and n constraint instead of aarch64_shift_imm_di and Usd.
19845 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
19846 (*aarch64_<optab>_reg_minus<mode>3): ... this.
19848 2018-03-20 Sudakshina Das <sudi.das@arm.com>
19851 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
19852 to favor GPR over NEON registers.
19853 (<shift>di3_neon): Likewise.
19855 2018-03-20 Tom de Vries <tom@codesourcery.com>
19858 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
19859 (nvptx_process_pars): Emit bar.sync asap and alap.
19861 2018-03-20 Tom de Vries <tom@codesourcery.com>
19864 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
19865 seen_label if seen_label is already set.
19867 2018-03-20 Jakub Jelinek <jakub@redhat.com>
19870 * config/i386/i386.c (fold_builtin_cpu): For features above 31
19871 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
19872 Use 1U instead of 1. Formatting fixes.
19875 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
19876 instead of TREE_TYPE (s1) for the return value.
19878 2018-03-19 Jakub Jelinek <jakub@redhat.com>
19880 PR tree-optimization/84946
19881 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
19882 bitsize + bitsize in poly_uint64 rather than poly_int64.
19885 * dwarf2asm.c: Include fold-const.c.
19886 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
19887 of decl rather than decl itself.
19889 PR rtl-optimization/84643
19890 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
19892 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
19895 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
19896 calling assemble_variable.
19898 2018-03-19 Sudakshina Das <sudi.das@arm.com>
19901 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
19902 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
19904 2018-03-19 Jim Wilson <jimw@sifive.com>
19907 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
19908 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
19909 (riscv_first_stack_step): Likewise.
19910 (riscv_option_override): Use STACK_BOUNDARY instead of
19911 MIN_STACK_BOUNDARY.
19912 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
19913 MIN_STACK_BOUNDARY.
19914 (BIGGEST_ALIGNMENT): Set to 128.
19915 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
19916 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
19919 2018-03-19 Richard Biener <rguenther@suse.de>
19921 PR tree-optimization/84933
19922 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
19923 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
19925 2018-03-19 Richard Biener <rguenther@suse.de>
19927 PR tree-optimization/84859
19928 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
19929 (cond_if_else_store_replacement): Perform sinking operation on
19930 single-store BBs regardless of MAX_STORES_TO_SINK setting.
19931 Generalize what a BB with a single eligible store is.
19933 2018-03-19 Richard Biener <rguenther@suse.de>
19935 PR tree-optimization/84929
19936 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
19937 chrec_is_positive against non-chrec arg.
19939 2018-03-19 Tamar Christina <tamar.christina@arm.com>
19942 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
19944 2018-03-18 Martin Liska <mliska@suse.cz>
19946 PR rtl-optimization/84635
19947 * regrename.c (build_def_use): Use matches_mode only when
19950 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
19952 PR tree-optimization/84913
19953 * tree-vect-loop.c (vectorizable_reduction): Don't try to
19954 vectorize chains of COND_EXPRs.
19956 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
19958 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
19960 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
19962 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
19964 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
19966 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
19968 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
19969 Kito Cheng <kito.cheng@gmail.com>
19971 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
19972 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
19973 (nds32_adjust_reg_alloc_order): New function.
19974 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
19976 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
19978 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
19979 nds32_print_operand, nds32_print_operand_address): Use
19980 HOST_WIDE_INT_PRINT_DEC instead.
19982 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
19984 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
19986 2018-03-17 Jakub Jelinek <jakub@redhat.com>
19989 * config/i386/i386.c (initial_ix86_tune_features,
19990 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
19991 unsigned long long.
19992 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
19993 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
19994 rather than 1u << ix86_tune. Formatting fix.
19995 (ix86_option_override_internal): Change ix86_arch_mask from
19996 unsigned int to unsigned HOST_WIDE_INT, initialize to
19997 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
19998 (ix86_function_specific_restore): Likewise.
20000 2018-03-16 Jakub Jelinek <jakub@redhat.com>
20003 * postreload.c (reload_combine_recognize_pattern): Perform
20004 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
20005 truncate_int_for_mode the result for the destination's mode.
20008 * hsa-gen.c (mem_type_for_type): Fix comment typo.
20009 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
20011 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
20014 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
20017 * lra-assigns.c (lra_split_hard_reg_for): Don't use
20018 regno_allocno_class_array and sorted_pseudos.
20019 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
20020 insns where regno is used.
20022 2018-03-16 Martin Liska <mliska@suse.cz>
20025 * multiple_target.c (create_dispatcher_calls): Redirect
20026 reference in the symbol table.
20028 2018-03-16 Martin Liska <mliska@suse.cz>
20031 * multiple_target.c (create_dispatcher_calls): Redirect also
20034 2018-03-16 Jakub Jelinek <jakub@redhat.com>
20038 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
20039 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
20040 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
20042 2018-03-16 Julia Koval <julia.koval@intel.com>
20044 * doc/invoke.texi (Skylake Server): Add CLWB.
20045 Cannonlake): Remove CLWB.
20047 2018-03-16 Jakub Jelinek <jakub@redhat.com>
20049 PR tree-optimization/84841
20050 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
20052 (FLOAT_ONE_CONST_TYPE): Define.
20053 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
20054 (sort_by_operand_rank): Put entries with higher constant_type last
20055 rather than first to match comments.
20057 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
20059 * config/nios2/nios2.md (movsi_internal): Fix thinko in
20062 2018-03-15 Jakub Jelinek <jakub@redhat.com>
20065 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
20066 check and use address of target always.
20068 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
20071 * config/i386/i386.c (indirect_thunk_needed): Update comments.
20072 (indirect_thunk_bnd_needed): Likewise.
20073 (indirect_thunks_used): Likewise.
20074 (indirect_thunks_bnd_used): Likewise.
20075 (indirect_return_needed): New.
20076 (indirect_return_bnd_needed): Likewise.
20077 (output_indirect_thunk_function): Add a bool argument for
20079 (output_indirect_thunk_function): Don't generate alias for
20080 function return thunk.
20081 (ix86_code_end): Call output_indirect_thunk_function to generate
20082 function return thunks.
20083 (ix86_output_function_return): Set indirect_return_bnd_needed
20084 and indirect_return_needed instead of indirect_thunk_bnd_needed
20085 and indirect_thunk_needed.
20087 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
20089 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
20090 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
20091 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
20093 2018-03-15 David Malcolm <dmalcolm@redhat.com>
20094 Paul Hua <paul.hua.gm@gmail.com>
20097 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
20099 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
20101 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
20102 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
20103 resp. SFmode cases.
20105 2018-03-15 Tamar Christina <tamar.christina@arm.com>
20108 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
20109 instead of GET_MODE_SIZE when comparing Units.
20111 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
20114 * varasm.c (hash_section): Return an unchangeble hash value
20115 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
20116 Return !aarch64_can_use_per_function_literal_pools_p ().
20118 2018-03-15 Jakub Jelinek <jakub@redhat.com>
20121 * optabs.c (emit_conditional_move): Pass address of cmode's copy
20122 rather than address of cmode as last argument to prepare_cmp_insn.
20124 2018-03-15 Julia Koval <julia.koval@intel.com>
20126 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
20127 F_AVX512VNNI, F_AVX512BITALG): New.
20129 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
20132 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
20133 insn for floating-point loads and stores.
20135 2018-03-14 Carl Love <cel@us.ibm.com>
20137 * config/rs6000/rs6000-c.c: Add macro definitions for
20138 ALTIVEC_BUILTIN_VEC_PERMXOR.
20139 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
20140 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
20141 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
20142 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
20144 * config/doc/extend.texi: Add prototypes for vec_permxor.
20146 2018-03-14 David Malcolm <dmalcolm@redhat.com>
20149 * diagnostic-show-locus.c (class layout_point): Convert m_line
20150 from int to linenum_type.
20151 (line_span::comparator): Use linenum "compare" function when
20152 comparing line numbers.
20153 (test_line_span): New function.
20154 (layout_range::contains_point): Convert param "row" from int to
20156 (layout_range::intersects_line_p): Likewise.
20157 (layout::will_show_line_p): Likewise.
20158 (layout::print_source_line): Likewise.
20159 (layout::should_print_annotation_line_p): Likewise.
20160 (layout::print_annotation_line): Likewise.
20161 (layout::print_leading_fixits): Likewise.
20162 (layout::annotation_line_showed_range_p): Likewise.
20163 (struct line_corrections): Likewise for field m_row.
20164 (line_corrections::line_corrections): Likewise for param "row".
20165 (layout::print_trailing_fixits): Likewise.
20166 (layout::get_state_at_point): Likewise.
20167 (layout::get_x_bound_for_row): Likewise.
20168 (layout::print_line): Likewise.
20169 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
20170 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
20171 * input.c (selftest::test_linenum_comparisons): New function.
20172 (selftest::input_c_tests): Call it.
20173 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
20174 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
20175 * selftest.h (ASSERT_GT): New macro.
20176 (ASSERT_GT_AT): New macro.
20177 (ASSERT_LT): New macro.
20178 (ASSERT_LT_AT): New macro.
20180 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
20182 PR rtl-optimization/84780
20183 * combine.c (distribute_links): Don't make a link based on pc_rtx.
20185 2018-03-14 Martin Liska <mliska@suse.cz>
20187 * tree.c (record_node_allocation_statistics): Use
20188 get_stats_node_kind.
20189 (get_stats_node_kind): New function extracted from
20190 record_node_allocation_statistics.
20191 (free_node): Use get_stats_node_kind.
20193 2018-03-14 Richard Biener <rguenther@suse.de>
20195 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
20196 that the value-set of ANTIC_IN doesn't grow.
20199 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
20201 (BB_VISITED_WITH_VISITED_SUCCS): New define.
20202 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
20204 2018-03-14 Julia Koval <julia.koval@intel.com>
20206 * config.gcc (icelake-client, icelake-server): New.
20208 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
20209 (initial_ix86_arch_features): Ditto.
20210 (PTA_SKYLAKE): Add SGX.
20211 (PTA_ICELAKE): Remove.
20212 (PTA_ICELAKE_CLIENT): New.
20213 (PTA_ICELAKE_SERVER): New.
20214 (ix86_option_override_internal): Split up icelake on icelake client and
20216 (get_builtin_code_for_version): Ditto.
20217 (fold_builtin_cpu): Ditto.
20218 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
20219 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
20220 * config/i386/i386.h (processor_type): Ditto.
20221 * doc/invoke.texi: Ditto.
20223 2018-03-14 Jakub Jelinek <jakub@redhat.com>
20226 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
20227 INTEGER_CST offset, add it together with bitpos / 8 and
20228 sign extend based on POINTER_SIZE.
20232 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
20235 * config/i386/constraints.md (Yc): New register constraint.
20236 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
20237 Use Yc constraint for alternative 2 of operand 0. Remove
20238 preferred_for_speed attribute.
20240 2018-03-14 Richard Biener <rguenther@suse.de>
20242 PR tree-optimization/84830
20243 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
20244 with the old one to avoid oscillations.
20246 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
20249 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
20251 (assign_by_spills): Return a flag of reload assignment failure.
20252 Do not process the reload assignment failures. Do not spill other
20253 reload pseudos if they has the same reg class. Update n if
20255 (lra_assign): Add a return arg. Set up from the result of
20256 assign_by_spills call.
20257 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
20258 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
20259 usage_insns if it is not NULL.
20260 (spill_hard_reg_in_range): New function.
20261 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
20262 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
20263 function prototypes.
20264 (lra_assign): Change prototype.
20265 * lra.c (lra): Add code to deal with fails by splitting hard reg
20268 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
20270 * config/riscv/riscv.opt (mrelax): New option.
20271 * config/riscv/riscv.c (riscv_file_start): Emit ".option
20272 "norelax" when riscv_mrelax is disabled.
20273 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
20275 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
20278 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
20279 reassociation for int modes.
20281 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
20283 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
20284 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
20286 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
20287 * config/aarch64/aarch64-sve.md
20288 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
20289 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
20290 (*extend<mode><Vwide>2): Rename to...
20291 (aarch64_sve_extend<mode><Vwide>2): ...this.
20292 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
20293 renaming the old pattern to...
20294 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
20296 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
20297 define_expand, renaming the old pattern to...
20298 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
20299 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
20300 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
20301 account when deciding which SVE instruction the optab should use.
20302 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
20304 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
20306 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
20307 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
20308 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
20309 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
20310 (tlsdesc_small_<mode>): Turn a define_expand and use
20311 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
20312 (tlsdesc_small_advsimd_<mode>): ...this.
20313 (tlsdesc_small_sve_<mode>): New pattern.
20315 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
20317 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
20318 (UNSPEC_UMUL_HIGHPART): New constants.
20319 (MUL_HIGHPART): New int iteraor.
20320 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
20321 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
20323 (*<su>mul<mode>3_highpart): New define_insn.
20325 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
20328 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
20331 2018-03-13 Martin Liska <mliska@suse.cz>
20334 * (sem_item_optimizer::sem_item_optimizer): Initialize new
20336 (sem_item_optimizer::~sem_item_optimizer): Release it.
20337 (sem_item_optimizer::merge_classes): Register variable aliases.
20338 (sem_item_optimizer::fixup_pt_set): New function.
20339 (sem_item_optimizer::fixup_points_to_sets): Likewise.
20340 * ipa-icf.h: Declare new variables and functions.
20342 2018-03-13 Jakub Jelinek <jakub@redhat.com>
20344 PR middle-end/84834
20345 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
20346 integer_pow2p@2 and test integer_pow2p in condition.
20347 (A < 0 ? C : 0): Similarly for @1.
20349 PR middle-end/84831
20350 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
20351 characters starting at p contain '\0' character, don't look beyond
20355 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
20356 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
20359 * reg-stack.c (change_stack): Change update_end var from int to
20360 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
20361 also call set_block_for_insn on the newly added insns and rescan.
20364 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
20365 on the last operand.
20368 * tree.c (stabilize_reference_1): Return save_expr (e) for
20369 STATEMENT_LIST even if it doesn't have side-effects.
20371 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
20373 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
20375 2018-03-12 Renlin Li <renlin.li@arm.com>
20377 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
20378 aarch64_output_scalar_simd_mov_immediate.
20380 2018-03-12 Martin Sebor <msebor@redhat.com>
20382 PR tree-optimization/83456
20383 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
20384 for perfectly overlapping calls to memcpy.
20385 (gimple_fold_builtin_memory_chk): Same.
20386 (gimple_fold_builtin_strcpy): Handle no-warning.
20387 (gimple_fold_builtin_stxcpy_chk): Same.
20388 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
20390 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
20392 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
20393 parameter. Use it for SFmode.
20394 (rs6000_function_arg_advance_1): Adjust.
20395 (rs6000_function_arg): Adjust.
20396 (rs6000_gimplify_va_arg): Pass false for that new parameter.
20398 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
20400 PR rtl-optimization/84169
20401 PR rtl-optimization/84780
20402 * combine.c (can_combine_p): Check for a 2-insn combination whether
20403 the destination register is used between the two insns, too.
20405 2018-03-12 Richard Biener <rguenther@suse.de>
20407 PR tree-optimization/84803
20408 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
20409 for refs DR analysis didn't process.
20411 2018-03-12 Richard Biener <rguenther@suse.de>
20413 PR tree-optimization/84777
20414 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
20415 force-vectorize loops ignore whether we are optimizing for size.
20417 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
20419 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
20420 (TARGET_MD_ASM_ADJUST): Define.
20422 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
20423 Kito Cheng <kito.cheng@gmail.com>
20424 Chung-Ju Wu <jasonwucj@gmail.com>
20426 * config/nds32/nds32.c (nds32_compute_stack_frame,
20427 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
20428 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
20429 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
20430 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
20431 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
20432 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
20433 * config/nds32/nds32.md (prologue, epilogue): Use macro
20434 NDS32_V3PUSH_AVAILABLE_P to do checking.
20436 2018-03-11 Jakub Jelinek <jakub@redhat.com>
20439 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
20440 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
20441 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
20442 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
20443 addition of most attributes on !orig_type_die or the attribute not
20444 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
20446 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
20447 Chung-Ju Wu <jasonwucj@gmail.com>
20449 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
20450 __NDS32_VH__ macro.
20451 * config/nds32/nds32.opt (mvh): New option.
20453 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
20454 Chung-Ju Wu <jasonwucj@gmail.com>
20456 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
20458 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
20459 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
20462 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
20463 Chung-Ju Wu <jasonwucj@gmail.com>
20465 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
20467 * config/nds32/nds32-multiple.md (strlensi): New pattern.
20468 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
20470 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
20471 Kito Cheng <kito.cheng@gmail.com>
20472 Chung-Ju Wu <jasonwucj@gmail.com>
20474 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
20475 UNSPEC_FFMISM and UNSPEC_FLMISM.
20476 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
20477 for ffb, ffmism and flmism.
20478 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
20479 (unspec_ffmism): Ditto.
20480 (unspec_flmism): Ditto.
20481 (nds32_expand_builtin_impl): Check if string extension is available.
20482 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
20483 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
20485 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
20488 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
20491 * lra-assigns.c (assign_by_spills): Return a flag of reload
20492 assignment failure. Do not process the reload assignment
20493 failures. Do not spill other reload pseudos if they has the same
20495 (lra_assign): Add a return arg. Set up from the result of
20496 assign_by_spills call.
20497 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
20498 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
20499 usage_insns if it is not NULL.
20500 (spill_hard_reg_in_range): New function.
20501 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
20502 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
20503 function prototypes.
20504 (lra_assign): Change prototype.
20505 * lra.c (lra): Add code to deal with fails by splitting hard reg
20508 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
20511 * config/i386/i386.opt: Replace Enforcment with Enforcement.
20513 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
20516 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
20517 (dw_val_node): Add val_symbolic_view.
20518 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
20519 (symview_upper_bound): New.
20520 (new_line_info_table): Initialize symviews_since_reset.
20521 (dwarf2out_source_line): Count symviews_since_reset and set
20522 symview_upper_bound.
20523 (dw_val_equal_p): Handle symview.
20524 (add_AT_symview): New.
20525 (print_dw_val): Handle symview.
20526 (attr_checksum, attr_checksum_ordered): Likewise.
20527 (same_dw_val_p, size_of_die): Likewise.
20528 (value_format, output_die): Likewise.
20529 (add_high_low_attributes): Use add_AT_symview for entry_view.
20530 (dwarf2out_finish): Reset symview_upper_bound, clear
20533 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
20536 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
20537 Add strict argument and use it.
20538 (rs6000_split_multireg_move): Update for new strict argument.
20539 (mem_operand_gpr): Disallow all non-offsettable addresses.
20540 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
20542 2018-03-09 Jakub Jelinek <jakub@redhat.com>
20545 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
20546 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
20547 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
20550 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
20551 decl, use remap_type if we want to use the type.
20553 2018-03-09 Martin Sebor <msebor@redhat.com>
20555 PR tree-optimization/84526
20556 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
20558 (builtin_access::generic_overlap): Be prepared to handle non-array
20561 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
20563 PR rtl-optimization/84682
20564 * lra-constraints.c (process_address_1): Check is_address flag
20565 for address constraints.
20566 (process_alt_operands): Likewise.
20567 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
20568 preprocess_constraints.
20569 * recog.h (preprocess_constraints): Add oploc parameter.
20571 * recog.c (preprocess_constraints): Test address_operand for
20572 CT_ADDRESS constraints.
20574 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
20577 * lra-assigns.c (assign_by_spills): Return a flag of reload
20578 assignment failure. Do not process the reload assignment
20579 failures. Do not spill other reload pseudos if they has the same
20581 (lra_assign): Add a return arg. Set up from the result of
20582 assign_by_spills call.
20583 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
20584 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
20585 usage_insns if it is not NULL.
20586 (spill_hard_reg_in_range): New function.
20587 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
20588 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
20589 function prototypes.
20590 (lra_assign): Change prototype.
20591 * lra.c (lra): Add code to deal with fails by splitting hard reg
20594 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20597 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
20598 Accept complain bool parameter. Only emit errors if it is true.
20599 (arm_parse_cpu_option_name): Likewise.
20600 (arm_target_thumb_only): Adjust callers of the above.
20601 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
20602 prototype to take a default true bool parameter.
20603 (arm_parse_arch_option_name): Likewise.
20605 2018-03-09 David Malcolm <dmalcolm@redhat.com>
20606 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
20610 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
20611 * configure: Regenerate.
20612 * configure.ac ("linker --version-script option"): New.
20613 ("linker soname option"): New.
20615 2018-03-09 Richard Biener <rguenther@suse.de>
20617 PR tree-optimization/84775
20618 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
20619 immediate uses of predicate stmts and mark them modified.
20622 PR tree-optimization/84178
20623 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
20625 (version_loop_for_if_conversion): Delay update_ssa call.
20626 (tree_if_conversion): Delay update_ssa until after predicate
20629 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
20632 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
20633 when the function accesses prior frames.
20635 2018-03-08 Jakub Jelinek <jakub@redhat.com>
20638 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
20639 gen_llsym, otherwise call maybe_gen_llsym.
20641 PR inline-asm/84742
20642 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
20643 has ',' character inside of it.
20645 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20648 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
20649 as clobbering CC_REGNUM.
20651 2018-03-08 Richard Biener <rguenther@suse.de>
20653 PR middle-end/84552
20654 * tree-scalar-evolution.c: Include tree-into-ssa.h.
20655 (follow_copies_to_constant): Do not follow SSA names registered
20658 2018-03-08 Richard Biener <rguenther@suse.de>
20660 PR tree-optimization/84178
20661 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
20663 (version_loop_for_if_conversion): Delay update_ssa call.
20664 (tree_if_conversion): Delay update_ssa until after predicate
20667 2018-03-08 David Malcolm <dmalcolm@redhat.com>
20669 PR tree-optimization/84178
20670 * tree-if-conv.c (release_bb_predicate): Remove the
20671 the assertion that the stmts have NULL use_ops.
20672 Discard the statements, asserting that they haven't
20673 yet been added to a BB.
20675 2018-03-08 Richard Biener <rguenther@suse.de>
20677 PR tree-optimization/84746
20678 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
20679 (phi_translate): Pass in destination ANTIC_OUT set.
20680 (phi_translate_1): Likewise. For a simplified result lookup
20681 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
20682 (phi_translate_set): Adjust.
20683 (do_pre_regular_insertion): Likewise.
20684 (do_pre_partial_partial_insertion): Likewise.
20686 2018-03-08 Martin Liska <mliska@suse.cz>
20688 PR gcov-profile/84735
20689 * doc/gcov.texi: Document usage of profile files.
20690 * gcov-io.h: Document changes in the format.
20692 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
20696 * dwarf2out.c (struct dw_line_info_table): Update comments for
20698 (FORCE_RESET_NEXT_VIEW): New.
20699 (FORCE_RESETTING_VIEW_P): New.
20700 (RESETTING_VIEW_P): Check for -1 too.
20701 (ZERO_VIEW_P): Likewise.
20702 (new_line_info_table): Force-reset next view.
20703 (dwarf2out_begin_function): Likewise.
20704 (dwarf2out_source_line): Simplify zero_view_p initialization.
20705 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
20706 view directly. Omit view when omitting .loc at line 0.
20708 2018-03-08 Jakub Jelinek <jakub@redhat.com>
20710 PR tree-optimization/84740
20711 * tree-switch-conversion.c (process_switch): Call build_constructors
20712 only if info.phi_count is non-zero.
20714 PR tree-optimization/84739
20715 * tree-tailcall.c (find_tail_calls): Check call arguments against
20716 DECL_ARGUMENTS (current_function_decl) rather than
20717 DECL_ARGUMENTS (func) when checking for tail recursion.
20719 2018-03-07 Jakub Jelinek <jakub@redhat.com>
20721 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
20722 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
20723 Volker Reichelt's entry and add entries for people that perform
20724 GCC fuzzy testing and report numerous bugs.
20726 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
20729 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
20730 readonly data in sdata, if that is disabled.
20731 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
20732 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
20733 -mreadonly-in-sdata option.
20735 2018-03-07 Martin Sebor <msebor@redhat.com>
20737 PR tree-optimization/84468
20738 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
20739 basic block when looking for nul assignment.
20741 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
20744 * except.h (output_function_exception_table): Adjust prototype.
20745 * except.c (output_function_exception_table): Remove FNNAME parameter
20746 and add SECTION parameter. Ouput one part of the table at a time.
20747 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
20748 the first part of the exception table and emit unwind directives.
20749 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
20750 (i386_pe_seh_cold_init): Likewise.
20751 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
20752 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
20753 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
20754 (ix86_output_call_insn): Emit a nop in one more case for SEH.
20755 * config/i386/winnt.c: Include except.h.
20756 (struct seh_frame_state): Add reg_offset, after_prologue and
20757 in_cold_section fields.
20758 (i386_pe_seh_end_prologue): Set seh->after_prologue.
20759 (i386_pe_seh_cold_init): New function.
20760 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
20761 to seh->in_cold_section.
20762 (seh_emit_push): Record the offset of the push.
20763 (seh_emit_save): Record the offet of the save.
20764 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
20765 Test seh->after_prologue to disregard the epilogue.
20766 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
20767 (i386_pe_end_cold_function): New function.
20769 2018-03-07 Jakub Jelinek <jakub@redhat.com>
20772 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
20773 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
20776 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
20778 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
20779 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
20781 PR middle-end/84723
20782 * multiple_target.c: Include tree-inline.h and intl.h.
20783 (expand_target_clones): Diagnose and fail if node->definition and
20784 !tree_versionable_function_p (node->decl).
20786 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
20788 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
20790 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
20791 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
20792 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
20794 2018-03-06 Jakub Jelinek <jakub@redhat.com>
20797 * combine.c (try_combine): Use reg_or_subregno instead of handling
20798 just paradoxical SUBREGs and REGs.
20800 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
20802 * config/arc/arc.c (arc_finalize_pic): Remove function.
20803 (arc_must_save_register): We use single base PIC register, remove
20804 checks to save/restore the PIC register.
20805 (arc_expand_prologue): Likewise.
20806 * config/arc/arc-protos.h (arc_set_default_type_attributes):
20808 (arc_verify_short): Likewise.
20809 (arc_attr_type): Likewise.
20810 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
20811 (walk_stores): Likewise.
20812 (arc_address_cost): Make it static.
20813 (arc_verify_short): Likewise.
20814 (branch_dest): Likewise.
20815 (arc_attr_type): Likewise.
20816 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
20817 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
20818 (arc_final_prescan_insn): Remove inserting the nops due to
20819 hardware hazards. It is done in reorg step.
20820 (insn_length_variant_t): Remove.
20821 (insn_length_parameters_t): Likewise.
20822 (arc_insn_length_parameters): Likewise.
20823 (arc_get_insn_variants): Likewise.
20824 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
20826 2018-03-06 Jakub Jelinek <jakub@redhat.com>
20828 PR inline-asm/84683
20829 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
20832 PR tree-optimization/84687
20833 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
20835 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
20837 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
20839 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
20840 Rename to ppc_speculation_barrier.
20841 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
20842 __builtin_ppc_speculation_barrier.
20844 2018-03-05 Jakub Jelinek <jakub@redhat.com>
20847 * combine.c (combine_simplify_rtx): Don't try to simplify if
20848 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
20851 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
20853 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
20854 to 32 bytes when compiling for POWER9.
20856 2018-03-05 Jakub Jelinek <jakub@redhat.com>
20859 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
20860 regparm >= 3 with no arg reg available also for calls with
20861 flag_force_indirect_call. Pass decl to ix86_function_regparm.
20864 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
20866 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
20868 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
20871 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
20873 2018-03-05 Richard Biener <rguenther@suse.de>
20875 PR tree-optimization/84486
20876 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
20877 When inserting a __builtin_assume_aligned call set the LHS
20878 SSA name alignment info accordingly.
20880 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
20882 PR tree-optimization/84114
20883 * config/aarch64/aarch64.c (aarch64_reassociation_width)
20884 Avoid reassociation of FLOAT_MODE addition.
20886 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
20888 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
20889 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
20890 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
20891 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
20892 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
20893 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
20894 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
20896 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
20897 __builtin_ia32_wbinvd): New builtins.
20898 (SPECIAL_ARGS2): New.
20899 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
20900 (SPECIAL_ARGS2): New.
20901 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
20902 (ix86_valid_target_attribute_inner_p): Ditto.
20903 (ix86_init_mmx_sse_builtins): Add special_args2.
20904 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
20905 TARGET_WBNOINVD_P): New.
20906 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
20907 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
20908 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
20909 * config/i386/immintrin.h (_wbinvd): New intrinsic.
20910 * config/i386/pconfigintrin.h: New file.
20911 * config/i386/wbnoinvdintrin.h: Ditto.
20912 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
20914 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
20916 2018-03-05 Richard Biener <rguenther@suse.de>
20918 PR tree-optimization/84670
20919 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
20921 (BB_VISITED_WITH_VISITED_SUCCS): New define.
20922 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
20923 (compute_antic_aux): Only assert the number of values in ANTIC_IN
20924 doesn't grow if all successors (recursively) were visited at least
20927 2018-03-05 Richard Biener <rguenther@suse.de>
20929 PR tree-optimization/84650
20930 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
20931 if executed in the loop pipeline.
20933 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
20935 * doc/configfiles.texi (Configuration Files): Move info about
20936 conditionalizing $target-protos.h to...
20937 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
20938 differs from $target-protos.h.
20940 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
20941 Chung-Ju Wu <jasonwucj@gmail.com>
20943 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
20944 * config/nds32/nds32-multiple.md (setmemsi): Define.
20945 * config/nds32/nds32-memory-manipulation.c
20946 (nds32_gen_dup_4_byte_to_word_value): New.
20947 (emit_setmem_word_loop): New.
20948 (emit_setmem_byte_loop): New.
20949 (nds32_expand_setmem_loop): New.
20950 (nds32_expand_setmem_loop_v3m): New.
20951 (nds32_expand_setmem_unroll): New.
20952 (nds32_expand_setmem): New.
20954 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
20955 Chung-Ju Wu <jasonwucj@gmail.com>
20957 * config/nds32/nds32-memory-manipulation.c
20958 (nds32_emit_load_store): New.
20959 (nds32_emit_post_inc_load_store): New.
20960 (nds32_emit_mem_move): New.
20961 (nds32_emit_mem_move_block): New.
20962 (nds32_expand_movmemsi_loop_unknown_size): New.
20963 (nds32_expand_movmemsi_loop_known_size): New.
20964 (nds32_expand_movmemsi_loop): New.
20965 (nds32_expand_movmemsi_unroll): New.
20966 (nds32_expand_movmemqi): Rename ...
20967 (nds32_expand_movmemsi): ... to this.
20968 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
20969 (movmemsi): ... to this.
20970 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
20971 (nds32_expand_movmemsi): ... to this.
20973 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
20974 Monk Chiang <sh.chiang04@gmail.com>
20975 Chung-Ju Wu <jasonwucj@gmail.com>
20977 * config/nds32/nds32-protos.h
20978 (nds32_expand_load_multiple): New arguments.
20979 (nds32_expand_store_multiple): Ditto.
20980 (nds32_valid_multiple_load_store): Rename ...
20981 (nds32_valid_multiple_load_store_p): ... to this.
20982 * config/nds32/nds32-memory-manipulation.c
20983 (nds32_expand_load_multiple): Refine implementation.
20984 (nds32_expand_store_multiple): Ditto.
20985 * config/nds32/nds32-multiple.md
20986 (load_multiple): Update nds32_expand_load_multiple interface.
20987 (store_multiple): Update nds32_expand_store_multiple interface.
20988 * config/nds32/nds32-predicates.c
20989 (nds32_valid_multiple_load_store): Rename ...
20990 (nds32_valid_multiple_load_store_p): ... to this and refine
20992 * config/nds32/predicates.md
20993 (nds32_load_multiple_and_update_address_operation): New predicate.
20994 (nds32_store_multiple_and_update_address_operation): New predicate.
20996 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
20997 Chung-Ju Wu <jasonwucj@gmail.com>
20999 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
21000 (combo): New attribute.
21001 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
21003 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
21005 * config/nds32/nds32.opt: Change -mcmodel= default value.
21007 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
21008 Monk Chiang <sh.chiang04@gmail.com>
21009 Chung-Ju Wu <jasonwucj@gmail.com>
21011 * config/nds32/constants.md (unspec_element): New enum.
21012 * config/nds32/constraints.md (Umw): New constraint.
21013 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
21014 * config/nds32/nds32-intrinsic.md: Likewise.
21015 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
21016 (nds32_valid_smw_lwm_base_p): New.
21017 (nds32_output_smw_single_word): New.
21018 (nds32_output_lmw_single_word): New.
21019 (nds32_expand_unaligned_load): New.
21020 (nds32_expand_unaligned_store): New.
21021 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
21022 (nds32_output_smw_single_word): Declare.
21023 (nds32_output_lmw_single_word): Declare.
21024 (nds32_expand_unaligned_load): Declare.
21025 (nds32_expand_unaligned_store): Declare.
21026 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
21027 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
21028 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
21029 NDS32_BUILTIN_UASTORE_DW.
21030 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
21033 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
21034 Kito Cheng <kito.cheng@gmail.com>
21035 Chung-Ju Wu <jasonwucj@gmail.com>
21037 * config/nds32/nds32-intrinsic.c
21038 (nds32_expand_builtin_null_ftype_reg): Delete.
21039 (nds32_expand_builtin_reg_ftype_imm): Ditto.
21040 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
21041 (nds32_read_argument): New.
21042 (nds32_legitimize_target): Ditto.
21043 (nds32_legitimize_argument): Ditto.
21044 (nds32_check_constant_argument): Ditto.
21045 (nds32_expand_unop_builtin): Ditto.
21046 (nds32_expand_unopimm_builtin): Ditto.
21047 (nds32_expand_binop_builtin): Ditto.
21048 (nds32_builtin_decl_impl): Ditto.
21049 (builtin_description): Ditto.
21050 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
21051 (nds32_init_builtins_impl): Ditto.
21052 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
21053 (nds32_builtin_decl): New.
21054 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
21055 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
21057 2018-03-02 Jeff Law <law@redhat.com>
21059 * reorg.c (stop_search_p): Handle DEBUG_INSN.
21060 (redundant_insn, fill_simple_delay_slots): Likewise.
21061 (fill_slots_from_thread): Likewise.
21062 * resource.c (mark_referenced_resources): Likewise.
21063 (mark_set_resources, find_dead_or_set_registers): Likewise.
21065 2018-03-02 Jakub Jelinek <jakub@redhat.com>
21067 * substring-locations.h (format_warning_va): Formatting fix for
21068 ATTRIBUTE_GCC_DIAG.
21069 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
21071 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
21072 * substring-locations.c: Include intl.h.
21073 (format_warning_va): Turned into small wrapper around
21074 format_warning_n_va, renamed to ...
21075 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
21076 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
21078 (format_warning_at_substring_n): New function.
21079 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
21080 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
21081 format_warning_at_substring with just a shorter name instead of
21082 const function pointer.
21083 (fmtwarn_n): New function.
21084 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
21085 appropriate, get rid of all the fmtstr temporaries, move conditionals
21086 with G_() wrapped string literals directly into fmtwarn arguments,
21087 cast dir.len to (int), formatting fixes.
21089 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
21091 * doc/invoke.texi: Remove "Cilk Plus" references.
21093 2018-03-02 Jakub Jelinek <jakub@redhat.com>
21094 Richard Biener <rguenther@suse.de>
21097 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
21098 for error or warning attributes if CALL_FROM_THUNK_P is set.
21101 2018-03-02 Jakub Jelinek <jakub@redhat.com>
21104 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
21105 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
21108 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
21109 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
21111 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
21112 instead of -1U in last predictors element's probability member.
21114 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
21117 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
21118 arguments if they are comparable.
21120 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
21122 PR tree-optimization/84634
21123 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
21124 masks and masked_loop_p with a single loop_masks, making sure it's
21125 null for bb vectorization.
21127 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
21129 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
21130 (vect_analyze_data_ref_access): Use loop->safe_len rather than
21131 loop->force_vectorize to check whether there is no alias.
21133 2018-03-02 Jakub Jelinek <jakub@redhat.com>
21136 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
21138 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
21140 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
21141 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
21142 instead of a loop around prev_real_insn.
21143 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
21146 PR inline-asm/84625
21147 * config/i386/i386.c (ix86_print_operand): Use conditional
21148 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
21151 2018-03-02 Richard Biener <rguenther@suse.de>
21153 PR tree-optimization/84427
21154 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
21155 (bitmap_set_subtract_values): Rewrite to handle multiple
21158 (prune_clobbered_mems): Likewise.
21159 (phi_translate): Take edge instead of pred/phiblock.
21160 (phi_translate_1): Likewise.
21161 (phi_translate_set): Likewise. Insert all translated
21162 exprs for a value into the set, keeping possibly multiple
21163 expressions per value.
21164 (compute_antic_aux): Adjust for phi_translate changes.
21165 When intersecting union the expressions and prune those
21166 not in the final value set, keeping possibly multiple
21167 expressions per value. Do not use value-insertion
21168 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
21169 all expressions. Add verification that the value-sets
21170 only shrink during iteration.
21171 (compute_partial_antic_aux): Adjust for the phi_translate changes.
21172 (do_pre_regular_insertion): Likewise.
21173 (do_pre_partial_partial_insertion): Likewise.
21175 2018-03-02 Richard Biener <rguenther@suse.de>
21178 * config/darwin.c (saved_debug_info_level): New static global.
21179 (darwin_asm_lto_start): Disable debug info generation for LTO out.
21180 (darwin_asm_lto_end): Restore debug info generation settings.
21182 2018-03-01 Martin Liska <mliska@suse.cz>
21185 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
21186 volatile arguments.
21188 2018-03-01 Richard Biener <rguenther@suse.de>
21191 * dwarf2out.c (gen_variable_die): Properly handle late VLA
21192 type annotation with LTO when debug was disabled at compile-time.
21194 2018-03-01 Matthew Fortune <mfortune@gmail.com>
21196 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
21198 (mips_final_postscan_insn): Likewise.
21200 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
21202 PR rtl-optimization/84528
21203 * alias.c (init_alias_target): Add commentary.
21204 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
21205 a unique base value if the frame pointer is not eliminated
21206 to the stack pointer.
21208 2018-03-01 Tom de Vries <tom@codesourcery.com>
21210 PR rtl-optimization/83327
21211 * lra-int.h (hard_regs_spilled_into): Declare.
21212 * lra.c (hard_regs_spilled_into): Define.
21213 (init_reg_info): Init hard_regs_spilled_into.
21214 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
21215 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
21216 (process_bb_lives): Handle hard_regs_spilled_into.
21217 (lra_create_live_ranges_1): Before doing liveness propagation, clear
21218 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
21220 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
21222 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
21223 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
21224 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
21225 * config/rs6000/aix72.h: New file.
21227 2018-02-28 Jakub Jelinek <jakub@redhat.com>
21229 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
21230 instead of warning_at with conditional singular and plural messages
21234 * stor-layout.c (update_alignment_for_field): For
21235 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
21236 && !DECL_PACKED (field), do the alignment update, just use
21237 only desired_align instead of MAX (type_align, desired_align)
21239 (place_field): Don't do known_align < desired_align handling
21240 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
21241 is non-NULL, instead do it after rli->prev_field handling and
21242 only if not within a bitfield word. For DECL_PACKED (field)
21243 use type_align of BITS_PER_UNIT.
21245 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
21247 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
21248 superfluous parentheses and trailing spaces.
21250 2018-02-28 Richard Biener <rguenther@suse.de>
21252 PR tree-optimization/84584
21253 * graphite-scop-detection.c (scop_detection::add_scop): Discard
21254 SCoPs with fake exit edge.
21256 2018-02-28 Martin Liska <mliska@suse.cz>
21259 * timevar.c (timer::print): Fix format to properly print 100%
21262 2018-02-28 Richard Biener <rguenther@suse.de>
21264 PR middle-end/84607
21265 * genmatch.c (capture_info::walk_match): Do not mark
21266 captured expressions without operands as expr_p given
21267 they act more like predicates and should be subject to
21268 "lost tail" side-effect preserving.
21270 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
21272 PR rtl-optimization/81611
21273 * auto-inc-dec.c (attempt_change): Move dead note from
21274 mem_insn if it's the next use of regno
21275 (find_address): Take address use of reg holding
21276 non-incremented value. Add parm to limit search to the named
21278 (merge_in_block): Attempt to use a mem insn that is the next
21279 use of the original regno.
21281 2018-02-27 Martin Sebor <msebor@redhat.com>
21284 * doc/invoke.texi (-Wmissing-attributes): New option.
21285 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
21287 2018-02-27 Martin Sebor <msebor@redhat.com>
21289 PR translation/84207
21290 * diagnostic-core.h (warning_n, error_n, inform_n): Change
21291 n argument to unsigned HOST_WIDE_INT.
21292 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
21293 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
21294 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
21295 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
21297 2018-02-27 Richard Biener <rguenther@suse.de>
21299 PR tree-optimization/84512
21300 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
21301 Do not use the estimate returned from record_stmt_cost for
21302 the scalar iteration cost but sum properly using add_stmt_cost.
21304 2018-02-27 Richard Biener <rguenther@suse.de>
21306 PR tree-optimization/84466
21307 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
21308 Adjust last change to less strictly validate use operands.
21310 2018-02-27 Martin Liska <mliska@suse.cz>
21312 PR gcov-profile/84548
21313 * gcov.c (process_file): Allow partial overlap and consider it
21314 also as group functions.
21315 (output_lines): Properly calculate range of lines for a group.
21317 2018-02-27 Martin Liska <mliska@suse.cz>
21319 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
21320 'ggc' suffixes. Change first column width.
21321 (timer::print): Fix formatting of the column.
21323 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
21325 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
21326 preserve inline entry blocks for the sake of debug inline
21327 entry point markers alone.
21328 (remove_unused_locals): Suggest in comments a better place to
21329 force the preservation of inline entry blocks that are
21330 otherwise unused, but do not preserve them.
21332 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
21334 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
21336 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
21339 * config/i386/constraints.md (Bs): Replace
21340 ix86_indirect_branch_register with
21341 TARGET_INDIRECT_BRANCH_REGISTER.
21343 * config/i386/i386.md (indirect_jump): Likewise.
21344 (tablejump): Likewise.
21345 (*sibcall_memory): Likewise.
21346 (*sibcall_value_memory): Likewise.
21347 Peepholes of indirect call and jump via memory: Likewise.
21348 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
21349 (*sibcall_value_GOT_32): Likewise.
21350 * config/i386/predicates.md (indirect_branch_operand): Likewise.
21351 (GOT_memory_operand): Likewise.
21352 (call_insn_operand): Likewise.
21353 (sibcall_insn_operand): Likewise.
21354 (GOT32_symbol_operand): Likewise.
21355 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
21357 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
21359 PR rtl-optimization/83496
21360 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
21361 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
21362 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
21363 redundant insn, if any.
21364 (relax_delay_slots): Likewise.
21365 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
21367 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
21369 PR tree-optimization/83965
21370 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
21371 that grouped statements are part of a reduction chain. Return
21372 true if the statement is not marked as a reduction itself but
21373 is part of a group.
21374 (vect_recog_dot_prod_pattern): Don't check whether the statement
21375 is part of a group here.
21376 (vect_recog_sad_pattern): Likewise.
21377 (vect_recog_widen_sum_pattern): Likewise.
21379 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
21382 * final.c (rest_of_clean_state): Also look for calls inside sequences.
21384 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
21387 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
21389 (ix86_output_indirect_function_return): New prototype.
21390 (ix86_split_simple_return_pop_internal): Likewise.
21391 * config/i386/i386.c (indirect_return_via_cx): New.
21392 (indirect_return_via_cx_bnd): Likewise.
21393 (indirect_thunk_name): Handle return va CX_REG.
21394 (output_indirect_thunk_function): Create alias for
21395 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
21396 (ix86_output_indirect_jmp): Remove the bool argument.
21397 (ix86_output_indirect_function_return): New function.
21398 (ix86_split_simple_return_pop_internal): Likewise.
21399 * config/i386/i386.md (*indirect_jump): Don't pass false
21400 to ix86_output_indirect_jmp.
21401 (*tablejump_1): Likewise.
21402 (simple_return_pop_internal): Change it to define_insn_and_split.
21403 Call ix86_split_simple_return_pop_internal to split it for
21404 -mfunction-return=.
21405 (simple_return_indirect_internal): Call
21406 ix86_output_indirect_function_return instead of
21407 ix86_output_indirect_jmp.
21409 2018-02-26 Jakub Jelinek <jakub@redhat.com>
21412 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
21413 memset and value initialization afterwards.
21415 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
21417 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
21419 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
21422 * common/config/aarch64/aarch64-common.c
21423 (aarch_option_optimization_table[]): Switch
21424 off fomit-frame-pointer
21426 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
21427 Chung-Ju Wu <jasonwucj@gmail.com>
21429 * config/nds32/nds32-multiple.md (load_multiple): Disallow
21431 (store_multiple): Ditto.
21433 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
21435 * config.gcc: Add --with-cpu support for nds32 target.
21436 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
21437 * config/nds32/nds32.opt: Add -mcpu= option.
21439 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
21441 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
21442 isel=yes): Warn for these deprecated options.
21444 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
21446 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
21447 ISA_2_5_MASKS_EMBEDDED.
21449 2018-02-23 Jakub Jelinek <jakub@redhat.com>
21451 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
21452 p->max as pointers rather than using iterative_hash_expr.
21454 2018-02-23 Carl Love <cel@us.ibm.com>
21456 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
21457 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
21459 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
21460 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
21461 P8V_BUILTIN_VEC_VUNSIGNED2.
21463 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
21466 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
21467 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
21469 * lra-constraints.c (curr_insn_transform): Set up
21470 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
21472 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
21473 * lra-eliminations.c (spill_pseudos): Ditto.
21474 (process_insn_for_elimination): Ditto.
21475 * lra-lives.c (reg_early_clobber_p): Use the new macros.
21476 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
21477 LRA_NON_CLOBBERED_ALT.
21479 2018-02-22 Martin Sebor <msebor@redhat.com>
21481 PR tree-optimization/84480
21482 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
21483 to maybe_diag_stxncpy_trunc. Call it.
21484 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
21485 from gimple_fold_builtin_strcpy. Print inlining stack.
21486 (handle_builtin_stxncpy): Print inlining stack.
21487 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
21489 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
21492 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
21493 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
21494 and -fcheck-pointer-bounds are used together.
21495 (indirect_thunk_prefix): New enum.
21496 (indirect_thunk_need_prefix): New function.
21497 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
21498 "_nt" instead of "_bnd" for NOTRACK prefix.
21499 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
21500 (output_indirect_thunk_function): Likewise.
21502 (ix86_code_end): Update output_indirect_thunk_function calls.
21503 (ix86_output_indirect_branch_via_reg): Replace
21504 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
21505 (ix86_output_indirect_branch_via_push): Likewise.
21506 (ix86_output_function_return): Likewise.
21507 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
21508 incompatible with -fcf-protection=branch and
21509 -fcheck-pointer-bounds.
21511 2018-02-22 Steve Ellcey <sellcey@cavium.com>
21514 * config/aarch64/aarch64.c (aarch64_print_address_internal):
21515 Change gcc_assert call to output_operand_lossage.
21517 2018-02-22 Steve Ellcey <sellcey@cavium.com>
21519 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
21521 2018-02-22 DJ Delorie <dj@redhat.com>
21522 Sebastian Perta <sebastian.perta@renesas.com>
21523 Oleg Endo <olegendo@gcc.gnu.org>
21525 * config/rx/rx.c (rx_rtx_costs): New function.
21526 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
21528 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
21530 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
21532 2018-02-22 Martin Liska <mliska@suse.cz>
21535 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
21536 Add "native" as a possible value.
21538 2018-02-22 Martin Liska <mliska@suse.cz>
21541 * config/i386/i386.c (ix86_option_override_internal):
21542 Add "native" as a possible value for -march and -mtune.
21544 2018-02-22 Jakub Jelinek <jakub@redhat.com>
21547 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
21548 to all type variants.
21550 PR tree-optimization/84503
21551 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
21552 width as info->bitpos + info->bitsize - start.
21553 (merged_store_group::merge_overlapping): Simplify width computation.
21554 (check_no_overlap): New function.
21555 (imm_store_chain_info::try_coalesce_bswap): Compute expected
21556 start + width and last_order of the group, fail if check_no_overlap
21558 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
21559 to group if check_no_overlap fails.
21561 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
21563 * config/rs6000/altivec.md: Delete contraint arguments to
21564 define_expand, define_split, and define_peephole2, and in
21565 define_insn_and_split if always unused.
21566 * config/rs6000/darwin.md: Ditto.
21567 * config/rs6000/dfp.md: Ditto.
21568 * config/rs6000/rs6000.md: Ditto.
21569 * config/rs6000/sync.md: Ditto.
21570 * config/rs6000/vector.md: Ditto.
21571 * config/rs6000/vsx.md: Ditto.
21573 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
21575 * config/rs6000/altivec.md: Write output control strings as braced
21576 blocks instead of double-quoted strings.
21577 * config/rs6000/darwin.md: Ditto.
21578 * config/rs6000/rs6000.md: Ditto.
21579 * config/rs6000/vector.md: Ditto.
21580 * config/rs6000/vsx.md: Ditto.
21582 2018-02-21 Jason Merrill <jason@redhat.com>
21584 PR c++/84314 - ICE with templates and fastcall attribute.
21585 * attribs.c (build_type_attribute_qual_variant): Remove assert.
21587 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
21589 * ipa-cp.c (determine_versionability): Fix comment typos.
21591 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
21594 * ipa-cp.c (determine_versionability): Do not version functions caling
21597 2018-02-21 Martin Liska <mliska@suse.cz>
21600 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
21601 Add "native" as a possible value.
21602 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
21603 the macro when native cpu detection is available.
21605 2018-02-21 Martin Liska <mliska@suse.cz>
21608 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
21609 Add "native" as a possible value.
21610 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
21611 when native cpu detection is available.
21613 2018-02-21 Jakub Jelinek <jakub@redhat.com>
21614 Martin Sebor <msebor@redhat.com>
21616 PR tree-optimization/84478
21617 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
21619 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
21620 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
21621 support which is conservatively correct, for 2 only stay conservative
21622 for maxlen. Formatting and comment capitalization fixes. Add STRICT
21623 argument to the 2 argument get_range_strlen, adjust 6 arg
21624 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
21626 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
21627 (gimple_fold_builtin_strlen): Pass true as last argument to
21630 2018-02-20 Martin Sebor <msebor@redhat.com>
21632 PR middle-end/84095
21633 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
21634 (builtin_memref::set_base_and_offset): Same. Handle inner references.
21635 (builtin_memref::builtin_memref): Factor out parts into
21636 set_base_and_offset and call it.
21638 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
21640 PR middle-end/84406
21641 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
21642 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
21643 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
21644 search at the associated MODE_INT.
21646 2018-02-20 Jeff Law <law@redhat.com>
21648 PR middle-end/82123
21649 PR tree-optimization/81592
21650 PR middle-end/79257
21651 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
21652 for range data rather than using global data.
21653 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
21654 range data rather than using global data.
21655 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
21656 pass it to children as needed.
21657 (struct directive::fmtresult): Similarly.
21658 (struct directive::set_width): Similarly.
21659 (struct directive::set_precision): Similarly.
21660 (format_integer, format_directive, parse_directive): Similarly.
21661 (format_none): Accept unnamed vr_values parameter.
21662 (format_percent, format_floating, format_character): Similarly.
21663 (format_string, format_plain): Similarly.
21664 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
21665 the EVRP range analyzer for range data rather than using global data.
21666 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
21667 gimple-ssa-evrp-analyze.h
21668 (class sprintf_dom_walker): Add after_dom_children member function.
21669 Add evrp_range_analyzer member.
21670 (sprintf_dom_walker::before_dom_children): Call into the EVRP
21671 range analyzer as needed.
21672 (sprintf_dom_walker::after_dom_children): New member function.
21673 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
21675 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
21676 (evrp_range_analyzer::pop_to_marker): Likewise.
21678 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
21680 PR tree-optimization/84419
21681 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
21682 with the required type if its current type is compatible but
21685 2018-02-20 Jakub Jelinek <jakub@redhat.com>
21687 PR middle-end/82004
21688 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
21689 after vectorization.
21691 2018-02-20 Martin Liska <mliska@suse.cz>
21694 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
21695 possible values if we don't have a hint.
21697 2018-02-20 Martin Liska <mliska@suse.cz>
21701 * final.c (shorten_branches): Build align_tab array with one
21703 * opts.c (finish_options): Add alignment option limit check.
21704 (MAX_CODE_ALIGN): Likewise.
21705 (MAX_CODE_ALIGN_VALUE): Likewise.
21706 * doc/invoke.texi: Document maximum allowed option value for
21707 all -falign-* options.
21709 2018-02-19 Jakub Jelinek <jakub@redhat.com>
21712 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
21713 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
21714 * var-tracking.c (emit_note_insn_var_location): Remove all references
21715 to NOTE_INSN_CALL_ARG_LOCATION.
21716 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
21717 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
21718 Use copy_rtx_if_shared.
21719 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
21720 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
21721 (dwarf2out_var_location): Remove handling of
21722 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
21724 * final.c (final_scan_insn): Remove all references to
21725 NOTE_INSN_CALL_ARG_LOCATION.
21726 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
21727 before dumping final insns.
21728 * except.c (emit_note_eh_region_end): Remove all references to
21729 NOTE_INSN_CALL_ARG_LOCATION.
21730 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
21731 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
21732 * config/arc/arc.c (hwloop_optimize): Likewise.
21733 * config/arm/arm.c (create_fix_barrier): Likewise.
21734 * config/s390/s390.c (s390_chunkify_start): Likewise.
21735 * config/sh/sh.c (find_barrier): Likewise.
21736 * config/i386/i386.c (rest_of_insert_endbranch,
21737 ix86_seh_fixup_eh_fallthru): Likewise.
21738 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
21739 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
21740 * config/frv/frv.c (frv_function_prologue): Likewise.
21741 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
21743 (note_outside_basic_block_p): Remove all references to
21744 NOTE_INSN_CALL_ARG_LOCATION.
21745 * gengtype.c (adjust_field_rtx_def): Likewise.
21746 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
21748 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
21749 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
21752 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
21755 PR tree-optimization/84452
21756 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
21757 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
21760 2018-02-19 Martin Liska <mliska@suse.cz>
21763 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
21765 2018-02-19 Martin Liska <mliska@suse.cz>
21766 Richard Sandiford <richard.sandiford@linaro.org>
21768 PR tree-optimization/82491
21769 * gimple-fold.c (get_base_constructor): Make earlier bail out
21772 2018-02-19 Carl Love <cel@us.ibm.com>
21774 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
21775 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
21777 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
21778 P8V_BUILTIN_VEC_NEG.
21780 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
21782 * config/rl78/rl78.md (movdf): New define expand.
21784 2018-02-19 Martin Liska <mliska@suse.cz>
21787 * doc/invoke.texi: Fix typo.
21788 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
21790 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
21792 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
21793 handle rs6000_single_float and rs6000_double_float specially for
21796 2018-02-16 Jeff Law <law@redhat.com>
21798 * config/rx/rx.c (add_pop_cfi_notes): New function.;
21799 (pop_regs): Use it.
21801 2018-02-16 Jakub Jelinek <jakub@redhat.com>
21804 * ipa-inline.c (inline_small_functions): Fix a typo.
21806 2018-02-16 Nathan Sidwell <nathan@acm.org>
21808 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
21810 2018-02-16 Carl Love <cel@us.ibm.com>
21812 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
21813 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
21814 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
21815 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
21816 expansion to P8V_BUILTIN_VEC_FLOAT2.
21818 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
21820 PR rtl-optimization/70023
21821 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
21822 src_regno into account.
21824 2018-02-16 Carl Love <cel@us.ibm.com>
21826 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
21827 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
21828 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
21829 * config/rs6000/rs6000.c: Remove case statements for
21830 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
21831 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
21832 and P9V_BUILTIN_VEC_VINSERT4B.
21833 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
21834 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
21835 * config/rs6000/vsx.md:
21836 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
21839 2018-02-16 Carl Love <cel@us.ibm.com>
21841 * config/rs6000/altivec.h: Add builtin names vec_extract4b
21843 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
21845 * config/rs6000/rs6000-c.c: Add the definitions for
21846 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
21847 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
21848 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
21849 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
21850 definition for insert4b and define insn *insert3b_internal.
21851 * doc/extend.texi: Add documentation for vec_extract4b.
21853 2018-02-16 Nathan Sidwell <nathan@acm.org>
21855 * doc/extend.texi (Backwards Compatibility): Mention friend
21856 injection. Note for-scope is deprecated.
21857 * doc/invoke.texi (-ffriend-injection): Deprecate.
21859 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
21861 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
21862 that moved to I2, also allow destinations that are a paradoxical
21863 subreg (instead of a normal reg).
21865 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
21868 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
21871 2018-02-16 Richard Biener <rguenther@suse.de>
21873 PR tree-optimization/84037
21874 PR tree-optimization/84016
21876 * config/i386/i386.c (ix86_builtin_vectorization_cost):
21877 Adjust vec_construct for the fact we need additional higher latency
21878 128bit inserts for AVX256 and AVX512 vector builds.
21879 (ix86_add_stmt_cost): Scale vector construction cost for
21882 2018-02-16 Richard Biener <rguenther@suse.de>
21884 PR tree-optimization/84417
21885 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
21886 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
21887 (non_rewritable_lvalue_p): Likewise, use poly-ints.
21889 2018-02-16 Martin Liska <mliska@suse.cz>
21892 * internal-fn.def (ASAN_CHECK): Set proper flags.
21893 (ASAN_MARK): Likewise.
21895 2018-02-16 Julia Koval <julia.koval@intel.com>
21897 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
21898 from PTA_CANNONLAKE.
21900 2018-02-16 Jakub Jelinek <jakub@redhat.com>
21903 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
21904 Use ++iter rather than iter++ for std::list iterators.
21905 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
21906 defer deleting them until all nodes in the forest are processed. Do
21907 free even leaf nodes. Change to_process into auto_vec.
21910 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
21911 * vec.h (vec_default_construct): Use memset instead of placement new
21912 if BROKEN_VALUE_INITIALIZATION is defined.
21913 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
21914 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
21917 PR rtl-optimization/83723
21918 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
21919 * lra.c (lra_substitute_pseudo): Likewise. If true, use
21920 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
21922 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
21924 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
21926 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
21928 PR rtl-optimization/81443
21929 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
21930 from inner REGs to paradoxical SUBREGs.
21932 2018-02-16 Richard Biener <rguenther@suse.de>
21934 PR tree-optimization/84399
21935 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
21936 For operands we can analyze at their definition make sure we can
21937 analyze them at each use as well.
21939 2018-02-16 Richard Biener <rguenther@suse.de>
21941 PR tree-optimization/84190
21942 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
21943 volatile accesses if the decl isn't volatile.
21945 2018-02-15 Jason Merrill <jason@redhat.com>
21947 PR c++/84314 - ICE with templates and fastcall attribute.
21948 * attribs.c (build_type_attribute_qual_variant): Don't clobber
21949 TYPE_CANONICAL on an existing type.
21951 2018-02-15 Jakub Jelinek <jakub@redhat.com>
21953 PR tree-optimization/84383
21954 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
21955 dstoff nor call operand_equal_p if dstbase is NULL.
21957 PR tree-optimization/84334
21958 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
21959 also a CONSTANT_CLASS_P, punt.
21961 2018-02-14 Jim Wilson <jimw@sifive.com>
21963 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
21964 first SMALL_OPERAND check. New local min_second_step. Move assert
21965 to where locals are set. Add TARGET_RVC support.
21966 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
21968 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
21970 * doc/invoke.texi: Correct -Wformat-overflow code sample.
21972 2018-02-14 Martin Sebor <msebor@redhat.com>
21974 PR tree-optimization/83698
21975 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
21976 arrays constrain the offset range to their bounds.
21977 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
21978 (builtin_access::overlap): Avoid setting the size of overlap if it's
21980 (maybe_diag_overlap): Also consider arrays when deciding what values
21981 of offsets to include in diagnostics.
21983 2018-02-14 Martin Sebor <msebor@redhat.com>
21986 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
21987 that correspond to the kind of a declaration.
21989 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
21992 * config/pa/pa.md: Load address of PIC label using the linkage table
21993 if the label is nonlocal.
21995 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
21997 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
21998 warning message if user requests -maltivec=be.
21999 * doc/invoke.texi: Document deprecation of -maltivec=be.
22001 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
22004 * config/rs6000/rs6000-c.c: Update definitions for
22005 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
22006 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
22008 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
22011 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
22012 add _get_ssp intrinsics. Remove argument from
22013 __builtin_ia32_rdssp[d|q].
22014 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
22015 * config/i386/i386-builtin.def: Remove argument from
22016 __builtin_ia32_rdssp[d|q].
22017 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
22018 ix86_expand_special_args_builtin for _rdssp[d|q].
22019 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
22020 Clear register before usage.
22021 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
22022 Add documentation for new _get_ssp and _inc_ssp intrinsics.
22024 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
22026 PR tree-optimization/84357
22027 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
22028 operand 1 of an ARRAY_REF too.
22030 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
22033 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
22034 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
22036 (set_of_reg): New struct.
22037 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
22038 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
22039 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
22041 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
22042 Split into bitclr, bitset, bitinvert patterns if appropriate.
22043 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
22044 use rx_fuse_in_memory_bitop.
22045 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
22046 to named insn, correct maximum insn length.
22048 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
22051 * machmode.def: Define a complex mode for PARTIAL_INT.
22052 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
22054 * doc/rtl.texi: Document CSPImode.
22055 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
22057 (msp430_hard_regno_nregs_with_padding): Likewise.
22059 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
22062 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
22064 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
22066 PR rtl-optimization/84169
22067 * combine.c (try_combine): New variable split_i2i3. Set it to true if
22068 we generated a parallel as new i3 and we split that to new i2 and i3
22069 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
22070 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
22071 those to i2, not i1. Partially rewrite this scan code.
22073 2018-02-13 Jakub Jelinek <jakub@redhat.com>
22076 * stor-layout.c (place_field): For variable length fields, adjust
22077 offset_align afterwards not just based on the field's alignment,
22078 but also on the size.
22080 PR middle-end/84309
22081 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
22082 of exps and logs in the use_exp2 case.
22084 2018-02-13 Jeff Law <law@redhat.com>
22086 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
22087 entry for "vector".
22089 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
22092 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
22096 * common.opt (gas-loc-support, gas-locview-support): New.
22097 (ginline-points, ginternal-reset-location-views): New.
22098 * doc/invoke.texi: Document them. Use @itemx where intended.
22099 (gvariable-location-views): Adjust.
22100 * target.def (reset_location_view): New.
22101 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
22102 (TARGET_RESET_LOCATION_VIEW): New.
22103 * doc/tm.texi: Rebuilt.
22104 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
22105 (dwarf2out_default_as_locview_support): New.
22106 (output_asm_line_debug_info): Use option variables.
22107 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
22108 (output_loc_list): Likewise.
22109 (add_high_low_attributes): Check option variables.
22110 Don't output entry view attribute in strict mode.
22111 (gen_inlined_subroutine_die): Check option variables.
22112 (dwarf2out_inline_entry): Likewise.
22113 (init_sections_and_labels): Likewise.
22114 (dwarf2out_early_finish): Likewise.
22115 (maybe_reset_location_view): New, from...
22116 (dwarf2out_var_location): ... here. Call it.
22117 * debug.h (dwarf2out_default_as_loc_support): Declare.
22118 (dwarf2out_default_as_locview_support): Declare.
22119 * hooks.c (hook_int_rtx_insn_0): New.
22120 * hooks.h (hook_int_rtx_insn_0): Declare.
22121 * toplev.c (process_options): Take -gas-loc-support and
22122 -gas-locview-support from dwarf2out. Enable
22123 -gvariable-location-views by default only with locview
22124 assembler support. Enable -ginternal-reset-location-views by
22125 default only if the target defines the corresponding hook.
22126 Enable -ginline-points by default if location views are
22127 enabled; force it disabled if statement frontiers are
22129 * tree-inline.c (expand_call_inline): Check option variables.
22130 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
22132 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
22134 PR tree-optimization/84321
22135 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
22136 handling. Also check whether the anti-range contains any values
22137 that satisfy the mask; switch to a VR_RANGE if not.
22139 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
22142 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
22144 2018-02-13 Martin Jambor <mjambor@suse.cz>
22147 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
22148 of call statements, also set location of a load to a temporary.
22150 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
22152 * config/rl78/rl78.c (add_vector_labels): New function.
22153 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
22154 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
22155 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
22156 which checks that no arguments are passed.
22157 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
22158 * doc/extend.texi: Documentation for the new attribute.
22160 2018-02-13 Andreas Schwab <schwab@suse.de>
22162 * config/riscv/linux.h (CPP_SPEC): Define.
22164 2018-02-13 Jakub Jelinek <jakub@redhat.com>
22167 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
22168 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
22169 OPTION_MASK_ISA_AES as first argument to def_builtin_const
22170 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
22171 instead of OPTION_MASK_ISA_PCLMUL as first argument to
22172 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
22173 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
22174 temporarily for AES and PCLMUL builtins.
22176 PR tree-optimization/84339
22177 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
22178 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
22181 PR middle-end/84309
22182 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
22183 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
22184 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
22186 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
22188 * omp-simd-clone.h: New file.
22189 * omp-simd-clone.c: Include omp-simd-clone.h.
22190 (expand_simd_clones): No longer static.
22191 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
22192 cgraph.h and omp-simd-clone.h.
22193 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
22194 (vect_recog_widen_shift_pattern): Formatting fix.
22195 (vect_pattern_recog_1): Don't check optab for calls.
22198 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
22199 operands[2] into a REG before using gen_lowpart on it.
22201 2018-02-12 Jeff Law <law@redhat.com>
22204 * config/sh/sh.c (find_barrier): Consider a sibling call
22207 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
22208 successfully back substituting a reg.
22210 2018-02-12 Richard Biener <rguenther@suse.de>
22212 PR tree-optimization/84037
22213 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
22214 parameter, move visited init to caller.
22215 (vect_slp_analyze_operations): Separate cost from validity
22216 check, initialize visited once for all instances.
22217 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
22219 * tree-vect-stmts.c (vect_model_simple_cost): Make early
22221 (vect_model_promotion_demotion_cost): Likewise.
22222 (vectorizable_bswap): Guard cost modeling with !slp_node
22223 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
22225 (vectorizable_call): Likewise.
22226 (vectorizable_conversion): Likewise.
22227 (vectorizable_assignment): Likewise.
22228 (vectorizable_shift): Likewise.
22229 (vectorizable_operation): Likewise.
22230 (vectorizable_store): Likewise.
22231 (vectorizable_load): Likewise.
22232 (vectorizable_condition): Likewise.
22233 (vectorizable_comparison): Likewise.
22235 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
22238 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
22239 (ASAN_MARK): Fix fnspec to account for return value, change pointer
22240 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
22242 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
22244 PR middle-end/83665
22245 * params.def (inline-min-speedup): Increase from 8 to 15.
22246 (max-inline-insns-auto): Decrease from 40 to 30.
22247 * ipa-split.c (consider_split): Add some buffer for function to
22248 be considered inlining candidate.
22249 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
22252 2018-02-12 Richard Biener <rguenther@suse.de>
22254 PR tree-optimization/84037
22255 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
22256 matched stmts if we cannot swap the non-matched ones.
22258 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
22260 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
22261 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
22262 _mm_maskz_scalef_round_ss): New intrinsics.
22263 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
22264 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
22265 __builtin_ia32_scalefss_round): Remove.
22266 (__builtin_ia32_scalefsd_mask_round,
22267 __builtin_ia32_scalefss_mask_round): New intrinsics.
22268 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
22269 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
22270 ((match_operand:VF_128 2 "<round_nimm_predicate>"
22271 "<round_constraint>")): Changed to ...
22272 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
22273 "<round_scalar_constraint>")): ... this.
22274 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
22275 %0, %1, %2<round_op3>}"): Changed to ...
22276 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
22277 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
22278 %2<round_scalar_mask_op3>}"): ... this.
22279 * config/i386/subst.md (round_scalar_nimm_predicate): New.
22281 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
22283 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
22284 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
22285 (_mm_maskz_sqrt_round_ss): New intrinsics.
22286 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
22287 (__builtin_ia32_sqrtsd_mask_round)
22288 (__builtin_ia32_sqrtss_mask_round): New builtins.
22289 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
22290 (__builtin_ia32_sqrtss_round): Remove.
22291 (__builtin_ia32_sqrtsd_mask_round)
22292 (__builtin_ia32_sqrtss_mask_round): New builtins.
22293 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
22294 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
22295 ((match_operand:VF_128 1 "vector_operand"
22296 "xBm,<round_constraint>")): Changed to ...
22297 ((match_operand:VF_128 1 "vector_operand"
22298 "xBm,<round_scalar_constraint>")): ... this.
22299 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
22300 %0, %2, %<iptr>1<round_op3>}): Changed to ...
22301 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
22302 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
22303 %<iptr>1<round_scalar_mask_op3>}): ... this.
22304 ((set_attr "prefix" "<round_prefix>")): Changed to ...
22305 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
22307 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
22310 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
22311 Cast vec_cmpeq result to correct type.
22312 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
22313 Cast vec_cmpgt result to correct type.
22315 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
22317 * final.c (final_scan_insn_1): Renamed from...
22318 (final_scan_insn): ... this. New wrapper, to recover
22319 seen from the outermost call in recursive ones.
22320 * config/sparc/sparc.c (output_return): Drop seen from call.
22321 (output_sibcall): Likewise.
22322 * config/visium/visium.c (output_branch): Likewise.
22324 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
22326 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
22329 2018-02-10 Alan Modra <amodra@gmail.com>
22332 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
22333 Specify LR as an input.
22335 2018-02-10 Jakub Jelinek <jakub@redhat.com>
22338 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
22339 remove_member_access_dummy_vars): New functions.
22340 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
22341 lower_omp_1, execute_lower_omp): Use them.
22343 PR rtl-optimization/84308
22344 * shrink-wrap.c (spread_components): Release todo vector.
22346 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
22348 PR rtl-optimization/57193
22349 * ira-color.c (struct allocno_color_data): Add member
22350 conflict_allocno_hard_prefs.
22351 (update_conflict_allocno_hard_prefs): New.
22352 (bucket_allocno_compare_func): Add a preference based on
22353 conflict_allocno_hard_prefs.
22354 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
22355 (color_allocnos): Remove a dead code. Initiate
22356 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
22358 2018-02-09 Jakub Jelinek <jakub@redhat.com>
22361 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
22362 constraint from =wa to wa. Avoid a subreg on the output operand,
22363 instead use a pseudo and subreg it in a move.
22364 (p9_xxbrd_<mode>): Changed to ...
22365 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
22366 (p9_xxbrd_v2df): New expander.
22367 (p9_xxbrw_<mode>): Changed to ...
22368 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
22369 (p9_xxbrw_v4sf): New expander.
22371 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
22373 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
22375 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
22378 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
22379 multiply in 32-bit mode.
22380 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
22381 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
22384 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
22386 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
22387 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
22388 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
22389 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
22391 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
22394 * dwarf2out.c (is_trivial_indirect_ref): New function.
22395 (dwarf2out_late_global_decl): Do not generate a location
22396 attribute for variables that have a non-trivial DECL_VALUE_EXPR
22397 and that are not defined in the current unit.
22399 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
22401 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
22402 instead of a libcall for UNORDERED.
22404 2018-02-09 Tamar Christina <tamar.christina@arm.com>
22407 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
22408 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
22410 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
22413 * config/s390/s390.c (s390_set_current_function): Invoke
22414 s390_indirect_branch_settings also if fndecl didn't change.
22416 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
22418 * config/rs6000/rs6000.md (blockage): Set length to zero.
22420 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
22422 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
22424 2018-02-09 Jakub Jelinek <jakub@redhat.com>
22427 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
22428 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
22432 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
22433 PARALLEL incoming that failed vt_get_decl_and_offset check.
22435 PR middle-end/84237
22436 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
22437 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
22439 (get_variable_section): For decls in named .bss* sections pass true as
22440 second argument to bss_initializer_p.
22442 2018-02-09 Marek Polacek <polacek@redhat.com>
22443 Jakub Jelinek <jakub@redhat.com>
22446 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
22447 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
22448 Sync some changes from cxx_fold_indirect_ref.
22450 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
22452 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
22454 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
22455 (BLOCK_INLINE_ENTRY_LABEL): New.
22456 (dwarf2out_var_location): Disregard inline entry markers.
22457 (inline_entry_data): New struct.
22458 (inline_entry_data_hasher): New hashtable type.
22459 (inline_entry_data_hasher::hash): New.
22460 (inline_entry_data_hasher::equal): New.
22461 (inline_entry_data_table): New variable.
22462 (add_high_low_attributes): Add DW_AT_entry_pc and
22463 DW_AT_GNU_entry_view attributes if a pending entry is found
22464 in inline_entry_data_table. Add old entry_pc attribute only
22465 if debug nonbinding markers are disabled.
22466 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
22467 markers are enabled.
22468 (block_within_block_p, dwarf2out_inline_entry): New.
22469 (dwarf2out_finish): Check that no entries remained in
22470 inline_entry_data_table.
22471 * final.c (reemit_insn_block_notes): Handle inline entry notes.
22472 (final_scan_insn, notice_source_line): Likewise.
22473 (rest_of_clean_state): Skip inline entry markers.
22474 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
22476 * gimple.c (gimple_build_debug_inline_entry): New.
22477 * gimple.h (enum gimple_debug_subcode): Add
22478 GIMPLE_DEBUG_INLINE_ENTRY.
22479 (gimple_build_debug_inline_entry): Declare.
22480 (gimple_debug_inline_entry_p): New.
22481 (gimple_debug_nonbind_marker_p): Adjust.
22482 * insn-notes.def (INLINE_ENTRY): New.
22483 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
22484 inline entry marker notes.
22485 (print_insn): Likewise.
22486 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
22487 (INSN_DEBUG_MARKER_KIND): Likewise.
22488 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
22489 * tree-inline.c (expand_call_inline): Build and insert
22490 debug_inline_entry stmt.
22491 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
22492 inline entry blocks early, if nonbind markers are enabled.
22493 (dump_scope_block): Dump fragment info.
22494 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
22495 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
22496 (gimple_build_debug_inline_entry): New.
22497 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
22498 Enable/disable inline entry points too.
22499 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
22500 (DEBUG_INSN): Describe inline entry markers.
22502 * common.opt (gvariable-location-views): New.
22503 (gvariable-location-views=incompat5): New.
22504 * config.in: Rebuilt.
22505 * configure: Rebuilt.
22506 * configure.ac: Test assembler for view support.
22507 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
22508 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
22509 * dwarf2out.c (var_loc_view): New typedef.
22510 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
22511 (dwarf2out_locviews_in_attribute): New.
22512 (dwarf2out_locviews_in_loclist): New.
22513 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
22514 (enum dw_line_info_opcode): Add LI_adv_address.
22515 (struct dw_line_info_table): Add view.
22516 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
22517 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
22518 (zero_view_p): New variable.
22519 (ZERO_VIEW_P): New macro.
22520 (output_asm_line_debug_info): New.
22521 (struct var_loc_node): Add view.
22522 (add_AT_view_list, AT_loc_list): New.
22523 (add_var_loc_to_decl): Add view param. Test it against last.
22524 (new_loc_list): Add view params. Record them.
22525 (AT_loc_list_ptr): Handle loc and view lists.
22526 (view_list_to_loc_list_val_node): New.
22527 (print_dw_val): Handle dw_val_class_view_list.
22528 (size_of_die): Likewise.
22529 (value_format): Likewise.
22530 (loc_list_has_views): New.
22531 (gen_llsym): Set vl_symbol too.
22532 (maybe_gen_llsym, skip_loc_list_entry): New.
22533 (dwarf2out_maybe_output_loclist_view_pair): New.
22534 (output_loc_list): Output view list or entries too.
22535 (output_view_list_offset): New.
22536 (output_die): Handle dw_val_class_view_list.
22537 (output_dwarf_version): New.
22538 (output_compilation_unit_header): Use it.
22539 (output_skeleton_debug_sections): Likewise.
22540 (output_rnglists, output_line_info): Likewise.
22541 (output_pubnames, output_aranges): Update version comments.
22542 (output_one_line_info_table): Output view numbers in asm comments.
22543 (dw_loc_list): Determine current endview, pass it to new_loc_list.
22544 Call maybe_gen_llsym.
22545 (loc_list_from_tree_1): Adjust.
22546 (add_AT_location_description): Create view list attribute if
22547 needed, check it's absent otherwise.
22548 (convert_cfa_to_fb_loc_list): Adjust.
22549 (maybe_emit_file): Call output_asm_line_debug_info for test.
22550 (dwarf2out_var_location): Reset views as needed. Precompute
22551 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
22552 attribute. Set view.
22553 (new_line_info_table): Reset next view.
22554 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
22555 (dwarf2out_source_line): Likewise. Output view resets and labels to
22556 the assembler, or select appropriate line info opcodes.
22557 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
22558 (optimize_string_length): Catch it. Adjust.
22559 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
22560 dw_val_class_view_list, and remove it if no longer needed.
22561 (hash_loc_list): Hash view numbers.
22562 (loc_list_hasher::equal): Compare them.
22563 (optimize_location_lists): Check whether a view list symbol is
22564 needed, and whether the locview attribute is present, and
22565 whether they match. Remove the locview attribute if no longer
22567 (index_location_lists): Call skip_loc_list_entry for test.
22568 (dwarf2out_finish): Call output_asm_line_debug_info for test.
22569 Use output_dwarf_version.
22570 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
22571 (struct dw_val_node): Add val_view_list.
22572 * final.c (SEEN_NEXT_VIEW): New.
22573 (set_next_view_needed): New.
22574 (clear_next_view_needed): New.
22575 (maybe_output_next_view): New.
22576 (final_start_function): Rename to...
22577 (final_start_function_1): ... this. Take pointer to FIRST,
22578 add SEEN parameter. Emit param bindings in the initial view.
22579 (final_start_function): Reintroduce SEEN-less interface.
22580 (final): Rename to...
22581 (final_1): ... this. Take SEEN parameter. Output final pending
22582 next view at the end.
22583 (final): Reintroduce seen-less interface.
22584 (final_scan_insn): Output pending next view before switching
22585 sections or ending a block. Mark the next view as needed when
22586 outputting variable locations. Notify debug backend of section
22587 changes, and of location view changes.
22588 (rest_of_handle_final): Adjust.
22589 * toplev.c (process_options): Autodetect value for debug variable
22590 location views option. Warn on incompat5 without -gdwarf-5.
22591 * doc/invoke.texi (gvariable-location-views): New.
22592 (gvariable-location-views=incompat5): New.
22593 (gno-variable-location-views): New.
22595 2018-02-08 David Malcolm <dmalcolm@redhat.com>
22597 PR tree-optimization/84136
22598 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
22599 that the result of find_edge is non-NULL.
22601 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
22604 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
22605 storing integer register in SImode. Fix cost of 256 and 512
22606 byte aligned SSE register store.
22608 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
22610 * config/i386/i386.c (ix86_multiplication_cost): Fix
22611 multiplication cost for TARGET_AVX512DQ.
22613 2018-02-08 Marek Polacek <polacek@redhat.com>
22615 PR tree-optimization/84238
22616 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
22619 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
22621 PR tree-optimization/84265
22622 * tree-vect-stmts.c (vectorizable_store): Don't treat
22623 VMAT_CONTIGUOUS accesses as grouped.
22624 (vectorizable_load): Likewise.
22626 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
22628 PR tree-optimization/81635
22629 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
22630 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
22631 (test_round_for_mask): New functions.
22632 (wide_int_cc_tests): Call test_round_for_mask.
22633 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
22634 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
22635 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
22636 range returned by get_range_info.
22638 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
22641 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
22642 * symtab.c: Include builtins.h
22643 (symtab_node::output_to_lto_symbol_table_p): Move here
22644 from lto-streamer-out.c:output_symbol_p.
22645 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
22646 (output_symbol_p): Move all logic to symtab.c
22647 (produce_symtab): Update.
22649 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
22651 * config/s390/s390-opts.h (enum indirect_branch): Define.
22652 * config/s390/s390-protos.h (s390_return_addr_from_memory)
22653 (s390_indirect_branch_via_thunk)
22654 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
22655 (enum s390_indirect_branch_type): Define.
22656 * config/s390/s390.c (struct s390_frame_layout, struct
22657 machine_function): Remove.
22658 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
22659 (indirect_branch_table_label_no, indirect_branch_table_name):
22661 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
22662 (enum s390_indirect_branch_option): Define.
22663 (s390_return_addr_from_memory): New function.
22664 (s390_handle_string_attribute): New function.
22665 (s390_attribute_table): Add new attribute handler.
22666 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
22667 (s390_indirect_branch_via_thunk): New function.
22668 (s390_indirect_branch_via_inline_thunk): New function.
22669 (s390_function_ok_for_sibcall): When jumping via thunk disallow
22670 sibling call optimization for non z10 compiles.
22671 (s390_emit_call): Force indirect branch target to be a single
22672 register. Add r1 clobber for non-z10 compiles.
22673 (s390_emit_epilogue): Emit return jump via return_use expander.
22674 (s390_reorg): Handle JUMP_INSNs as execute targets.
22675 (s390_option_override_internal): Perform validity checks for the
22676 new command line options.
22677 (s390_indirect_branch_attrvalue): New function.
22678 (s390_indirect_branch_settings): New function.
22679 (s390_set_current_function): Invoke s390_indirect_branch_settings.
22680 (s390_output_indirect_thunk_function): New function.
22681 (s390_code_end): Implement target hook.
22682 (s390_case_values_threshold): Implement target hook.
22683 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
22685 * config/s390/s390.h (struct s390_frame_layout)
22686 (struct machine_function): Move here from s390.c.
22687 (TARGET_INDIRECT_BRANCH_NOBP_RET)
22688 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
22689 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
22690 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
22691 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
22692 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
22693 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
22694 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
22695 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
22696 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
22697 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
22698 (mnemonic attribute): Add values which aren't recognized
22700 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
22701 pattern for branch conversion. Fix mnemonic attribute.
22702 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
22703 indirect branch via thunk if requested.
22704 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
22705 ("*indirect_jump"): Disable for branch conversion using out of
22707 ("indirect_jump_via_thunk<mode>_z10")
22708 ("indirect_jump_via_thunk<mode>")
22709 ("indirect_jump_via_inlinethunk<mode>_z10")
22710 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
22711 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
22712 ("casesi_jump_via_inlinethunk<mode>_z10")
22713 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
22714 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
22715 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
22716 ("*indirect2_jump"): Disable for branch conversion.
22717 ("casesi_jump"): Turn into expander and expand patterns for branch
22719 ("return_use"): New expander.
22720 ("*return"): Emit return via thunk and rename it to ...
22721 ("*return<mode>"): ... this one.
22722 * config/s390/s390.opt: Add new options and and enum for the
22725 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
22727 * lra-constraints.c (match_reload): Unconditionally use
22728 gen_lowpart_SUBREG, rather than selecting between that
22729 and equivalent gen_rtx_SUBREG code.
22731 2018-02-08 Richard Biener <rguenther@suse.de>
22733 PR tree-optimization/84233
22734 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
22735 changed flag instead of boguously re-using phi_inserted.
22737 2018-02-08 Martin Jambor <mjambor@suse.cz>
22739 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
22740 static local variables.
22742 2018-02-08 Richard Biener <rguenther@suse.de>
22744 PR tree-optimization/84278
22745 * tree-vect-stmts.c (vectorizable_store): When looking for
22746 smaller vector types to perform grouped strided loads/stores
22747 make sure the mode is supported by the target.
22748 (vectorizable_load): Likewise.
22750 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
22752 * config/aarch64/aarch64.c (aarch64_components_for_bb):
22753 Increase LDP/STP opportunities by adding adjacent callee-saves.
22755 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
22757 PR rtl-optimization/84068
22758 PR rtl-optimization/83459
22759 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
22761 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
22763 PR tree-optimization/84224
22764 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
22765 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
22766 non-zero arguments.
22768 2018-02-07 Iain Sandoe <iain@codesourcery.com>
22771 * config/rs6000/altivec.md (*restore_world): Remove LR use.
22772 * config/rs6000/predicates.md (restore_world_operation): Adjust op
22773 count, remove one USE.
22775 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
22777 * doc/install.texi (Configuration): Document the
22778 --with-long-double-format={ibm,ieee} PowerPC configuration
22782 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
22783 Convert from define_expand to be define_insn_and_split. Rework
22784 float/double/_Float128 conversions to QI/HI/SImode to work with
22785 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
22786 conversions to QI/HImode types did a store and then a load to
22787 truncate the value. For conversions to VSX registers, don't split
22788 the insn, instead emit the code directly. Use the code iterator
22789 any_fix to combine signed and unsigned conversions.
22790 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
22791 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
22792 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
22793 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
22794 (fix_<mode>di2_hw): Likewise.
22795 (fixuns_<mode>di2_hw): Likewise.
22796 (fix_<mode>si2_hw): Likewise.
22797 (fixuns_<mode>si2_hw): Likewise.
22798 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
22799 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
22800 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
22801 fix<uns>_trunc<SFDF:mode>si2_p8.
22802 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
22803 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
22804 (fix<uns>_<mode>_mem): Likewise.
22805 (fctiw<u>z_<mode>_mem): Likewise.
22806 (fix<uns>_<mode>_mem): Likewise.
22807 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
22808 the register allocator from doing a direct move to the GPRs to do
22809 a store, and instead use the ISA 3.0 store byte/half-word from
22810 vector register instruction. For IEEE 128-bit floating point,
22811 also optimize stores of 32-bit ints.
22812 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
22814 2018-02-07 Alan Hayward <alan.hayward@arm.com>
22816 * genextract.c (push_pathstr_operand): New function to support
22818 (walk_rtx): Call push_pathstr_operand.
22819 (print_path): Support [a-zA-Z].
22821 2018-02-07 Richard Biener <rguenther@suse.de>
22823 PR tree-optimization/84037
22824 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
22825 (cse_and_gimplify_to_preheader): Declare.
22826 (vect_get_place_in_interleaving_chain): Likewise.
22827 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
22829 (_loop_vec_info::~_loop_vec_info): Delete it.
22830 (cse_and_gimplify_to_preheader): New function.
22831 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
22832 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
22833 (vectorizable_load): Likewise. For grouped stores always base
22834 the IV on the first element.
22835 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
22836 condition before gimplifying.
22838 2018-02-07 Jakub Jelinek <jakub@redhat.com>
22840 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
22841 *DIV_EXPR and *MOD_EXPR.
22843 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
22846 * config/i386/i386.c (ix86_option_override_internal): Mask out
22847 the CF_SET bit when checking -fcf-protection.
22849 2018-02-07 Tom de Vries <tom@codesourcery.com>
22852 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
22855 2018-02-07 Richard Biener <rguenther@suse.de>
22857 PR tree-optimization/84204
22858 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
22861 PR tree-optimization/84205
22862 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
22863 special-case isl_ast_op_zdiv_r.
22865 PR tree-optimization/84223
22866 * graphite-scop-detection.c (gather_bbs::before_dom_children):
22867 Only add conditions from within the region.
22868 (gather_bbs::after_dom_children): Adjust.
22870 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
22873 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
22874 * config/avr/avr.md: Only post-reload split REG-REG moves if
22875 either register is GENERAL_REG_P.
22877 2018-02-07 Jakub Jelinek <jakub@redhat.com>
22879 PR tree-optimization/84235
22880 * tree-ssa-scopedtables.c
22881 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
22882 if the subtraction is performed in floating point type where NaNs are
22883 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
22884 build 1. Formatting fix.
22886 2018-02-06 Jakub Jelinek <jakub@redhat.com>
22889 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
22890 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
22891 and skip it regardless of bb boundaries. Use CALL_P macro,
22892 don't test INSN_P (insn) together with CALL_P or JUMP_P check
22893 unnecessarily, formatting fix.
22895 2018-02-06 Michael Collison <michael.collison@arm.com>
22897 * config/arm/thumb2.md:
22898 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
22899 (*thumb_mov_notscc): Ditto.
22901 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
22904 * config/rs6000/rs6000.md (su code attribute): Use "u" for
22905 unsigned_fix, not "s".
22907 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
22909 * configure.ac (gcc_fn_eh_frame_ro): New function.
22910 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
22911 correct .eh_frame permissions.
22912 * configure: Regenerate.
22914 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
22916 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
22917 irrelevant options.
22919 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
22921 * config/rs6000/rs6000.c (rs6000_option_override_internal):
22922 Display warning message for -mno-speculate-indirect-jumps.
22924 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
22926 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
22928 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
22930 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
22932 PR tree-optimization/84225
22933 * tree-eh.c (find_trapping_overflow): Only call
22934 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
22936 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
22939 * config/i386/i386.c: Reimplement the check of possible options
22940 -mibt/-mshstk conbination. Change error messages.
22941 * doc/invoke.texi: Fix a typo: remove extra '='.
22943 2018-02-06 Marek Polacek <polacek@redhat.com>
22945 PR tree-optimization/84228
22946 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
22948 2018-02-06 Tamar Christina <tamar.christina@arm.com>
22951 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
22952 emitted arch directives.
22953 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
22954 __ARM_FEATURE_COPROC before changing architectures.
22956 2018-02-06 Richard Biener <rguenther@suse.de>
22958 * config/i386/i386.c (print_reg): Fix typo.
22959 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
22961 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
22963 * configure: Regenerate.
22965 2018-02-05 Martin Sebor <msebor@redhat.com>
22967 PR tree-optimization/83369
22968 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
22971 2018-02-05 Martin Liska <mliska@suse.cz>
22973 * doc/invoke.texi: Cherry-pick upstream r323995.
22975 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
22977 * ira.c (ira_init_register_move_cost): Adjust comment.
22979 2018-02-05 Martin Liska <mliska@suse.cz>
22981 PR gcov-profile/84137
22982 * doc/gcov.texi: Fix typo in documentation.
22984 2018-02-05 Martin Liska <mliska@suse.cz>
22986 PR gcov-profile/83879
22987 * doc/gcov.texi: Document necessity of --dynamic-list-data when
22988 using dlopen functionality.
22990 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
22992 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
22993 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
22994 _mm_maskz_range_ss, _mm_mask_range_round_ss,
22995 _mm_maskz_range_round_ss): New intrinsics.
22996 (__builtin_ia32_rangesd128_round)
22997 (__builtin_ia32_rangess128_round): Remove.
22998 (__builtin_ia32_rangesd128_mask_round,
22999 __builtin_ia32_rangess128_mask_round): New builtins.
23000 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
23001 __builtin_ia32_rangess128_round): Remove.
23002 (__builtin_ia32_rangesd128_mask_round,
23003 __builtin_ia32_rangess128_mask_round): New builtins.
23004 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
23005 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
23006 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
23007 "<round_saeonly_constraint>")): Changed to ...
23008 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
23009 "<round_saeonly_scalar_constraint>")): ... this.
23010 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
23011 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
23012 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
23013 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
23014 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
23016 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
23018 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
23020 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
23021 Remove all values except native, 8540 and 8548.
23023 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
23025 * config/i386/i386.c (ix86_output_function_return): Pass
23026 INVALID_REGNUM, instead of -1, as invalid register number to
23027 indirect_thunk_name and output_indirect_thunk.
23029 2018-02-02 Julia Koval <julia.koval@intel.com>
23031 * config.gcc: Add -march=icelake.
23032 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
23033 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
23034 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
23035 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
23036 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
23037 (processor_target_table): Add icelake.
23038 (ix86_option_override_internal): Handle new PTAs.
23039 (get_builtin_code_for_version): Handle icelake.
23040 (M_INTEL_COREI7_ICELAKE): New.
23041 (fold_builtin_cpu): Handle icelake.
23042 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
23043 * doc/invoke.texi: Add -march=icelake.
23045 2018-02-02 Julia Koval <julia.koval@intel.com>
23047 * config/i386/i386.c (ix86_option_override_internal): Change flags type
23048 to wide_int_bitmask.
23049 * wide-int-bitmask.h: New.
23051 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
23054 * config/i386/i386.md: Replace Pmode with word_mode in
23055 builtin_setjmp_setup and builtin_longjmp to support x32.
23057 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
23061 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
23063 (rs6000_supported_cpu_names): New static variable.
23064 (linux_cpu_translation_table): Likewise.
23065 (elf_platform) <cpu>: Define new static variable and use it.
23066 Translate kernel AT_PLATFORM name to canonical name if needed.
23067 Error if platform name is unknown.
23069 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
23072 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
23074 2018-02-01 Jeff Law <law@redhat.com>
23077 * config/i386/i386.c (release_scratch_register_on_entry): Add new
23078 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
23079 the scratch if RELEASE_VIA_POP is false.
23080 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
23081 If we have to save a temporary register, decrement SIZE appropriately.
23082 Pass new arguments to release_scratch_register_on_entry.
23083 (ix86_adjust_stack_and_probe): Likewise.
23084 (ix86_emit_probe_stack_range): Pass new arguments to
23085 release_scratch_register_on_entry.
23087 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
23089 PR rtl-optimization/84157
23090 * combine.c (change_zero_ext): Use REG_P predicate in
23091 front of HARD_REGISTER_P predicate.
23093 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
23095 * config/avr/avr.c (avr_option_override): Move disabling of
23096 -fdelete-null-pointer-checks to...
23097 * common/config/avr/avr-common.c (avr_option_optimization_table):
23100 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23102 PR tree-optimization/81635
23103 * tree-data-ref.c (split_constant_offset_1): For types that
23104 wrap on overflow, try to use range info to prove that wrapping
23107 2018-02-01 Renlin Li <renlin.li@arm.com>
23110 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
23111 TAILCALL_ADDR_REGS.
23112 (aarch64_register_move_cost): Likewise.
23113 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
23114 TAILCALL_ADDR_REGS.
23115 (REG_CLASS_NAMES): Likewise.
23116 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
23117 TAILCALL_ADDR_REGS. Remove IP registers.
23118 * config/aarch64/aarch64.md (Ucs): Update register constraint.
23120 2018-02-01 Richard Biener <rguenther@suse.de>
23122 * domwalk.h (dom_walker::dom_walker): Add additional constructor
23123 for specifying RPO order and allow NULL for that.
23124 * domwalk.c (dom_walker::dom_walker): Likewise.
23125 (dom_walker::walk): Handle NULL RPO order.
23126 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
23128 (rewrite_update_dom_walker): Likewise.
23129 (mark_def_dom_walker): Likewise.
23131 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23133 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
23134 (aarch64_maybe_expand_sve_subreg_move): Declare.
23135 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
23136 * config/aarch64/predicates.md (aarch64_any_register_operand): New
23138 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
23139 that are semantically a reverse operation.
23140 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
23141 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
23142 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
23144 (aarch64_can_change_mode_class): For big-endian, forbid changes
23145 between two SVE modes if they have different element sizes.
23147 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23149 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
23150 the TImode handling for big-endian targets.
23152 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23154 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
23155 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
23157 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
23158 Remove BSWAP handing for big-endian targets and use the form of
23159 LD1RQ appropariate for the mode.
23161 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23163 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
23164 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
23165 duplicated element.
23167 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
23170 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
23171 check for operands that need to go through aarch64_sve_reload_be.
23173 2018-02-01 Jakub Jelinek <jakub@redhat.com>
23175 PR tree-optimization/81661
23176 PR tree-optimization/84117
23177 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
23178 * tree-eh.c: Include gimplify.h.
23179 (find_trapping_overflow, replace_trapping_overflow,
23180 rewrite_to_non_trapping_overflow): New functions.
23181 * tree-vect-loop.c: Include tree-eh.h.
23182 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
23183 * tree-data-ref.c: Include tree-eh.h.
23184 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
23186 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
23188 PR rtl-optimization/84123
23189 * combine.c (change_zero_ext): Check if hard register satisfies
23190 can_change_dest_mode before calling gen_lowpart_SUBREG.
23192 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
23195 * ira.c (ira_init_register_move_cost): Remove assert.
23197 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
23199 PR rtl-optimization/84071
23200 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
23201 * doc/tm.texi: Regenerate.
23203 2018-01-31 Richard Biener <rguenther@suse.de>
23205 PR tree-optimization/84132
23206 * tree-data-ref.c (analyze_miv_subscript): Properly
23207 check whether evolution_function_is_affine_multivariate_p
23208 before calling gcd_of_steps_may_divide_p.
23210 2018-01-31 Julia Koval <julia.koval@intel.com>
23213 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
23214 * config/i386/i386.md (rdpid_rex64) New.
23215 (rdpid): Make 32bit only.
23217 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
23220 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
23221 an IDENTIFIER_NODE for FUNCTION_TYPE's.
23223 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
23226 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
23228 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
23230 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
23232 PR rtl-optimization/84071
23233 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
23234 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
23236 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
23238 * config/arc/arc.c (arc_handle_aux_attribute): New function.
23239 (arc_attribute_table): Add 'aux' attribute.
23240 (arc_in_small_data_p): Consider aux like variables.
23241 (arc_is_aux_reg_p): New function.
23242 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
23243 (arc_get_aux_arg): New function.
23244 (prepare_move_operands): Handle aux-register access.
23245 (arc_handle_aux_attribute): New function.
23246 * doc/extend.texi (ARC Variable attributes): Add subsection.
23248 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
23250 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
23251 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
23252 (arc_attribute_table): Add 'uncached' attribute.
23253 (arc_print_operand): Print '.di' flag for uncached memory
23255 (arc_in_small_data_p): Do not consider for small data the uncached
23257 (arc_is_uncached_mem_p): New function.
23258 * config/arc/predicates.md (compact_store_memory_operand): Check
23259 for uncached memory accesses.
23260 (nonvol_nonimm_operand): Likewise.
23261 * doc/extend.texi (ARC Type Attribute): New subsection.
23263 2018-01-31 Jakub Jelinek <jakub@redhat.com>
23266 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
23267 falign-loops=): Add Optimization flag.
23269 2018-01-30 Jeff Law <law@redhat.com>
23272 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
23273 INT_REGISTERS_SAVED. Check it prior to calling
23274 get_scratch_register_on_entry.
23275 (ix86_adjust_stack_and_probe): Similarly.
23276 (ix86_emit_probe_stack_range): Similarly.
23277 (ix86_expand_prologue): Corresponding changes.
23279 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
23282 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
23283 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
23285 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
23288 * lra-constraints.c (curr_insn_transform): Process AND in the
23291 2018-01-30 Jakub Jelinek <jakub@redhat.com>
23293 PR rtl-optimization/83986
23294 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
23295 dependence against last_pending_memory_flush in addition to
23296 pending_jump_insns.
23298 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
23300 PR tree-optimization/81611
23301 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
23304 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
23307 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
23310 2018-01-30 Richard Biener <rguenther@suse.de>
23311 Jakub Jelinek <jakub@redhat.com>
23313 PR tree-optimization/84111
23314 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
23315 inner loops added during recursion, as they don't have up-to-date
23318 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
23321 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
23322 (can_inline_edge_by_limits_p): ... here.
23323 (can_early_inline_edge_p, check_callers,
23324 update_caller_keys, update_callee_keys, recursive_inlining,
23325 add_new_edges_to_heap, speculation_useful_p,
23326 inline_small_functions,
23327 inline_small_functions, flatten_function,
23328 inline_to_all_callers_1): Update.
23330 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
23332 * profile-count.c (profile_count::combine_with_ipa_count): Handle
23335 2018-01-30 Richard Biener <rguenther@suse.de>
23337 PR tree-optimization/83008
23338 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
23339 invariant and constant vector uses in stmts when they need
23340 more than one stmt.
23342 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
23345 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
23346 * configure: Regenerate.
23348 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
23350 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
23352 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
23353 Use gen_rtx_REG rather than gen_lowpart.
23355 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
23357 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
23358 rather than 0 when creating partial subregs.
23360 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
23362 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
23365 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
23368 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
23369 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
23370 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
23371 flags. This restores the settings used before the 2017-07-24.
23372 Turning off pre increment/decrement/modify allows IVOPTS to
23373 optimize DF/SF loops where the index is an int.
23375 2018-01-29 Richard Biener <rguenther@suse.de>
23376 Kelvin Nilsen <kelvin@gcc.gnu.org>
23379 * tree-vect-stmts.c (vectorizable_call): Don't call
23380 targetm.vectorize_builtin_md_vectorized_function if callee is
23383 2018-01-22 Carl Love <cel@us.ibm.com>
23385 * doc/extend.tex: Fix typo in second arg in
23386 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
23388 2018-01-29 Richard Biener <rguenther@suse.de>
23390 PR tree-optimization/84086
23391 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
23392 (flush_ssaname_freelist): When SSA names were released reset
23393 the SCEV hash table.
23395 2018-01-29 Richard Biener <rguenther@suse.de>
23397 PR tree-optimization/84057
23398 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
23399 removed paths when removing edges.
23401 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
23403 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
23404 -mfunction-return=@var{choice}.
23406 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
23408 PR diagnostic/84034
23409 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
23410 Handle CR like TAB.
23411 (layout::print_source_line): Likewise.
23412 (test_get_line_width_without_trailing_whitespace): Add test cases.
23414 2018-01-27 Jakub Jelinek <jakub@redhat.com>
23416 PR middle-end/84040
23417 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
23420 2018-01-26 Jim Wilson <jimw@sifive.com>
23422 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
23424 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
23427 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23429 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
23430 and CMP + SUB-immediate -> SUBS.
23432 2018-01-26 Martin Sebor <msebor@redhat.com>
23434 PR tree-optimization/83896
23435 * tree-ssa-strlen.c (get_string_len): Rename...
23436 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
23437 Avoid assuming length is constant.
23438 (handle_char_store): Use HOST_WIDE_INT for string length.
23440 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
23443 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
23444 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
23446 2018-01-26 Richard Biener <rguenther@suse.de>
23448 PR rtl-optimization/84003
23449 * dse.c (record_store): Only record redundant stores when
23450 the earlier store aliases at least all accesses the later one does.
23452 2018-01-26 Jakub Jelinek <jakub@redhat.com>
23454 PR rtl-optimization/83985
23455 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
23456 REG_CFA_RESTORE insns.
23457 (delete_unmarked_insns): Don't ignore separate shrink wrapping
23458 REG_CFA_RESTORE insns here.
23461 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
23462 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
23464 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
23466 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
23467 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
23468 (arc_init): Likewise.
23469 (arc_override_options): Likewise.
23470 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
23472 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
23474 * config/arc/arc.h (TARGET_DBNZ): Define.
23475 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
23476 properly set the tune attribute.
23477 (dbnz): Use TARGET_DBNZ guard.
23478 * config/arc/arc.opt (mtune): Add core3 option.
23480 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
23482 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
23483 recognize new pic like addresses.
23484 (arc_delegitimize_address): Clean up.
23486 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
23488 * config/arc/arc-arches.def: Option mrf16 valid for all
23490 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
23491 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
23492 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
23493 * config/arc/arc-tables.opt: Regenerate.
23494 * config/arc/arc.c (arc_conditional_register_usage): Handle
23495 reduced register file case.
23496 (arc_file_start): Set must have build attributes.
23497 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
23498 mrf16 option value.
23499 * config/arc/arc.opt (mrf16): Add new option.
23500 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
23501 * config/arc/genmultilib.awk: Handle new mrf16 option.
23502 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
23503 * config/arc/t-multilib: Regenerate.
23504 * doc/invoke.texi (ARC Options): Document mrf16 option.
23506 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
23508 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
23509 * config/arc/arc.c (arc_handle_secure_attribute): New function.
23510 (arc_attribute_table): Add 'secure_call' attribute.
23511 (arc_print_operand): Print secure call operand.
23512 (arc_function_ok_for_sibcall): Don't optimize tail calls when
23514 (arc_is_secure_call_p): New function. * config/arc/arc.md
23515 (call_i): Add support for sjli instruction.
23516 (call_value_i): Likewise.
23517 * config/arc/constraints.md (Csc): New constraint.
23519 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
23520 John Eric Martin <John.Martin@emmicro-us.com>
23522 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
23523 * config/arc/arc.c (_arc_jli_section): New struct.
23524 (arc_jli_section): New type.
23525 (rc_jli_sections): New static variable.
23526 (arc_handle_jli_attribute): New function.
23527 (arc_attribute_table): Add jli_always and jli_fixed attribute.
23528 (arc_file_end): New function.
23529 (TARGET_ASM_FILE_END): Define.
23530 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
23531 (arc_add_jli_section): New function.
23532 (jli_call_scan): Likewise.
23533 (arc_reorg): Call jli_call_scan.
23534 (arc_output_addsi): Remove 'S' from printing asm operand.
23535 (arc_is_jli_call_p): New function.
23536 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
23538 (movhi_insn): Likewise.
23539 (movsi_insn): Likewise.
23540 (movsi_set_cc_insn): Likewise.
23541 (loadqi_update): Likewise.
23542 (load_zeroextendqisi_update): Likewise.
23543 (load_signextendqisi_update): Likewise.
23544 (loadhi_update): Likewise.
23545 (load_zeroextendhisi_update): Likewise.
23546 (load_signextendhisi_update): Likewise.
23547 (loadsi_update): Likewise.
23548 (loadsf_update): Likewise.
23549 (movsicc_insn): Likewise.
23550 (bset_insn): Likewise.
23551 (bxor_insn): Likewise.
23552 (bclr_insn): Likewise.
23553 (bmsk_insn): Likewise.
23554 (bicsi3_insn): Likewise.
23555 (cmpsi_cc_c_insn): Likewise.
23556 (movsi_ne): Likewise.
23557 (movsi_cond_exec): Likewise.
23558 (clrsbsi2): Likewise.
23559 (norm_f): Likewise.
23569 (call_i): Remove 'S' asm letter, add jli instruction.
23570 (call_value_i): Likewise.
23571 * config/arc/arc.op (mjli-always): New option.
23572 * config/arc/constraints.md (Cji): New constraint.
23573 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
23575 (subsf3_fpx): Likewise.
23576 (mulsf3_fpx): Likewise.
23577 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
23579 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
23580 function attrbutes.
23581 * doc/invoke.texi (ARC): Document mjli-always option.
23583 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
23585 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
23586 avoid addition with 0 and use incw and decw where possible.
23588 2018-01-26 Richard Biener <rguenther@suse.de>
23590 PR tree-optimization/81082
23591 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
23592 association if it requires casting to unsigned.
23593 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
23594 from fold_plusminus_mult_expr to catch important cases late when
23595 range info is available.
23597 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
23599 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
23600 * configure.ac (hidden_linkonce): New test.
23601 * configure: Regenerate.
23602 * config.in: Regenerate.
23604 2018-01-26 Julia Koval <julia.koval@intel.com>
23606 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
23607 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
23608 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
23609 _mm_mask_bitshuffle_epi64_mask): Fix type.
23610 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
23611 USI_FTYPE_V4DI_V4DI_USI): Remove.
23612 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
23613 __builtin_ia32_vpshufbitqmb256_mask,
23614 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
23615 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
23616 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
23618 2018-01-26 Alan Modra <amodra@gmail.com>
23621 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
23622 UNSPEC_VBPERMQ. Sort other unspecs.
23624 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
23626 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
23628 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
23630 PR middle-end/83055
23631 * predict.c (drop_profile): Do not push/pop cfun; update also
23633 (handle_missing_profiles): Fix logic looking for zero profiles.
23635 2018-01-25 Jakub Jelinek <jakub@redhat.com>
23637 PR middle-end/83977
23638 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
23639 on functions with #pragma omp declare simd or functions with simd
23641 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
23642 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
23643 Remove trailing \n from warning_at calls.
23645 2018-01-25 Tom de Vries <tom@codesourcery.com>
23648 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
23649 for neutered workers.
23651 2018-01-24 Joseph Myers <joseph@codesourcery.com>
23654 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
23655 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
23657 2018-01-24 Jeff Law <law@redhat.com>
23660 * i386.c (get_probe_interval): Move to earlier point.
23661 (ix86_compute_frame_layout): If -fstack-clash-protection and
23662 the frame is larger than the probe interval, then use pushes
23663 to save registers rather than reg->mem moves.
23664 (ix86_expand_prologue): Remove conditional for int_registers_saved
23667 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
23670 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
23671 min/max for never referenced object.
23673 2018-01-24 Jakub Jelinek <jakub@redhat.com>
23675 PR middle-end/83977
23676 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
23678 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
23679 attributes from DECL_ATTRIBUTES (decl) without affecting
23680 DECL_ATTRIBUTES (current_function_decl).
23681 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
23682 functions with non-NULL DECL_ABSTRACT_ORIGIN.
23684 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
23686 PR tree-optimization/83979
23687 * fold-const.c (fold_comparison): Use constant_boolean_node
23688 instead of boolean_{true,false}_node.
23690 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
23692 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
23695 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
23697 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
23698 Simplify the clause that sets the length attribute.
23699 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
23700 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
23701 clause that sets the length attribute.
23702 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
23704 2018-01-24 Tom de Vries <tom@codesourcery.com>
23707 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
23708 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
23709 Add strict parameter.
23710 (prevent_branch_around_nothing): Insert dummy insn between branch to
23711 label and label with no ptx insn inbetween.
23712 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
23714 2018-01-24 Tom de Vries <tom@codesourcery.com>
23717 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
23718 for neutered threads in warp.
23719 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
23721 2018-01-24 Richard Biener <rguenther@suse.de>
23723 PR tree-optimization/83176
23724 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
23727 2018-01-24 Richard Biener <rguenther@suse.de>
23729 PR tree-optimization/82819
23730 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
23731 code generating pluses that are no-ops in the target precision.
23733 2018-01-24 Richard Biener <rguenther@suse.de>
23735 PR middle-end/84000
23736 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
23738 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
23740 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
23741 to merge probabilities.
23742 * predict.c (probably_never_executed): Also mark as cold functions
23743 with global 0 profile and guessed local profile.
23744 * profile-count.c (profile_probability::combine_with_count): New
23746 * profile-count.h (profile_probability::operator*,
23747 profile_probability::operator*=, profile_probability::operator/,
23748 profile_probability::operator/=): Reduce precision to adjusted
23749 and set value to guessed on contradictory divisions.
23750 (profile_probability::combine_with_freq): Remove.
23751 (profile_probability::combine_wiht_count): Declare.
23752 (profile_count::force_nonzero):: Set to adjusted.
23753 (profile_count::probability_in):: Set quality to adjusted.
23754 * tree-ssa-tail-merge.c (replace_block_by): Use
23755 combine_with_count.
23757 2018-01-23 Andrew Waterman <andrew@sifive.com>
23758 Jim Wilson <jimw@sifive.com>
23760 * config/riscv/riscv.c (riscv_stack_boundary): New.
23761 (riscv_option_override): Set riscv_stack_boundary. Handle
23762 riscv_preferred_stack_boundary_arg.
23763 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
23764 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
23765 (STACK_BOUNDARY): Set to riscv_stack_boundary.
23766 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
23767 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
23768 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
23770 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
23773 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
23774 of struct ix86_frame.
23775 (ix86_expand_epilogue): Likewise. Add a local variable for
23776 the reg_save_offset field in struct ix86_frame.
23778 2018-01-23 Bin Cheng <bin.cheng@arm.com>
23780 PR tree-optimization/82604
23781 * tree-loop-distribution.c (enum partition_kind): New enum item
23782 PKIND_PARTIAL_MEMSET.
23783 (partition_builtin_p): Support above new enum item.
23784 (generate_code_for_partition): Ditto.
23785 (compute_access_range): Differentiate cases that equality can be
23786 proven at all loops, the innermost loops or no loops.
23787 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
23788 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
23789 (finalize_partitions, distribute_loop): Don't fuse partition of
23790 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
23791 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
23792 parloop is enabled.
23794 2018-01-23 Martin Liska <mliska@suse.cz>
23796 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
23797 order to ignore the predictor.
23798 (PRED_POLYMORPHIC_CALL): Likewise.
23799 (PRED_RECURSIVE_CALL): Likewise.
23801 2018-01-23 Martin Liska <mliska@suse.cz>
23803 * tree-profile.c (tree_profiling): Print function header to
23804 aware reader which function we are working on.
23805 * value-prof.c (gimple_find_values_to_profile): Do not print
23806 not interesting value histograms.
23808 2018-01-23 Martin Liska <mliska@suse.cz>
23810 * profile-count.h (enum profile_quality): Add
23811 profile_uninitialized as the first value. Do not number values
23812 as they are zero based.
23813 (profile_count::verify): Update sanity check.
23814 (profile_probability::verify): Likewise.
23816 2018-01-23 Nathan Sidwell <nathan@acm.org>
23818 * doc/invoke.texi (ffor-scope): Deprecate.
23820 2018-01-23 David Malcolm <dmalcolm@redhat.com>
23822 PR tree-optimization/83510
23823 * domwalk.c (set_all_edges_as_executable): New function.
23824 (dom_walker::dom_walker): Convert bool param
23825 "skip_unreachable_blocks" to enum reachability. Move setup of
23826 edge flags to set_all_edges_as_executable and only do it when
23827 reachability is REACHABLE_BLOCKS.
23828 * domwalk.h (enum dom_walker::reachability): New enum.
23829 (dom_walker::dom_walker): Convert bool param
23830 "skip_unreachable_blocks" to enum reachability.
23831 (set_all_edges_as_executable): New decl.
23832 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
23833 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
23835 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
23836 but converting true to REACHABLE_BLOCKS.
23837 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
23839 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
23840 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
23841 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
23843 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
23844 if check_all_array_refs will be called.
23846 2018-01-23 David Malcolm <dmalcolm@redhat.com>
23848 * tree.c (selftest::test_location_wrappers): Add more test
23851 2018-01-23 David Malcolm <dmalcolm@redhat.com>
23853 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
23854 (selftest::test_bit_in_range): Likewise.
23856 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
23859 * doc/sourcebuild.texi (vect_float): Say that the selector
23860 only describes the situation when -funsafe-math-optimizations is on.
23861 (vect_float_strict): Document.
23863 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
23865 PR tree-optimization/83965
23866 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
23867 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
23868 instead of checking only for a reduction.
23869 (vect_recog_widen_sum_pattern): Likewise.
23871 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
23873 * predict.c (probably_never_executed): Only use precise profile info.
23874 (compute_function_frequency): Skip after inlining hack since we now
23875 have quality checking.
23877 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
23879 * profile-count.h (profile_probability::very_unlikely,
23880 profile_probability::unlikely, profile_probability::even): Set
23881 precision to guessed.
23883 2018-01-23 Richard Biener <rguenther@suse.de>
23885 PR tree-optimization/83963
23886 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
23887 Properly terminate dominator walk when crossing the exit edge not
23888 when visiting its source block.
23890 2018-01-23 Jakub Jelinek <jakub@redhat.com>
23893 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
23894 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
23896 2018-01-22 Jakub Jelinek <jakub@redhat.com>
23898 PR tree-optimization/83957
23899 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
23900 semicolon after for body surrounded by braces.
23902 PR tree-optimization/83081
23903 * profile-count.h (profile_probability::split): New method.
23904 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
23905 Use profile_probability::split.
23906 (do_compare_rtx_and_jump): Fix adjustment of probabilities
23907 when splitting a single conditional jump into 2.
23909 2018-01-22 David Malcolm <dmalcolm@redhat.com>
23911 PR tree-optimization/69452
23912 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
23915 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23917 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
23918 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
23919 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
23921 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23923 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
23925 * config/rl78/rl78.md (movdi): New define_expand.
23926 * config/rl78/rl78.c (rl78_split_movdi): New function.
23928 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
23931 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
23933 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
23934 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
23935 128-bit to produce an UNSPEC move to get the double word with the
23936 signbit and then a shift directly to do signbit.
23937 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
23938 implementation with a new version that just does either a direct
23939 move or a regular move. Move memory interface to separate insns.
23940 Move insns so they are next to the expander.
23941 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
23942 with signbit move. Split big and little endian case.
23943 (signbit<mode>2_dm_mem_le): Likewise.
23944 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
23945 (signbit<mode>2_dm2): Likewise.
23947 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23949 * config/rl78/rl78.md (anddi3): New define_expand.
23951 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23953 * config/rl78/rl78.md (umindi3): New define_expand.
23955 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23957 * config/rl78/rl78.md (smindi3): New define_expand.
23959 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23961 * config/rl78/rl78.md (smaxdi3): New define_expand.
23963 2018-01-22 Carl Love <cel@us.ibm.com>
23965 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
23966 LVX_V1TI): Add macro expansion.
23967 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
23968 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
23969 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
23970 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
23971 Change check to determine if the instruction is a byte reversing
23972 entry. Fix typo in comment.
23973 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
23974 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
23975 Add def_builtin calls for new builtins.
23976 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
23977 Add define_insn expansion.
23979 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23981 * config/rl78/rl78.md (umaxdi3): New define_expand.
23983 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
23985 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
23986 for non-QImode registers.
23988 2018-01-22 Richard Biener <rguenther@suse.de>
23990 PR tree-optimization/83963
23991 * graphite-scop-detection.c (scop_detection::get_sese): Delay
23992 including the loop exit block.
23993 (scop_detection::merge_sese): Likewise.
23994 (scop_detection::add_scop): Do it here instead.
23996 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23998 * doc/sourcebuild.texi (arm_softfloat): Document.
24000 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
24003 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
24004 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
24005 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
24007 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24008 David Edelsohn <dje.gcc@gmail.com>
24011 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
24012 Change "crset eq" to "crset 2".
24013 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
24014 (*call_indirect_aix<mode>_nospec): Likewise.
24015 (*call_value_indirect_aix<mode>_nospec): Likewise.
24016 (*call_indirect_elfv2<mode>_nospec): Likewise.
24017 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
24018 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
24019 change assembly output from . to $.
24020 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
24021 (indirect_jump<mode>_nospec): Change assembly output from . to $.
24022 (*tablejump<mode>_internal1_nospec): Likewise.
24024 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
24027 * config/sh/sh_optimize_sett_clrt.cc:
24028 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
24030 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
24032 PR tree-optimization/83940
24033 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
24034 offset_dt to vect_constant_def rather than vect_unknown_def_type.
24035 (vect_check_load_store_mask): Add a mask_dt_out parameter and
24036 use it to pass back the definition type.
24037 (vect_check_store_rhs): Likewise rhs_dt_out.
24038 (vect_build_gather_load_calls): Add a mask_dt argument and use
24039 it instead of a call to vect_is_simple_use.
24040 (vectorizable_store): Update calls to vect_check_load_store_mask
24041 and vect_check_store_rhs. Use the dt returned by the latter instead
24042 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
24043 instead of calls to vect_is_simple_use. Pass the scalar rather
24044 than the vector operand to vect_is_simple_use when handling
24045 second and subsequent copies of an rhs value.
24046 (vectorizable_load): Update calls to vect_check_load_store_mask
24047 and vect_build_gather_load_calls. Use the cached mask_dt and
24048 gs_info.offset_dt instead of calls to vect_is_simple_use.
24050 2018-01-20 Jakub Jelinek <jakub@redhat.com>
24052 PR middle-end/83945
24053 * tree-emutls.c: Include gimplify.h.
24054 (lower_emutls_2): New function.
24055 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
24056 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
24057 it before further processing.
24060 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
24061 UINTVAL (trueop1) instead of INTVAL (op1).
24063 2018-01-19 Jakub Jelinek <jakub@redhat.com>
24067 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
24068 INCOMING_FRAME_SP_OFFSET if not defined.
24069 (scan_trace): Add ENTRY argument. If true and
24070 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
24071 emit a note to adjust the CFA offset.
24072 (create_cfi_notes): Adjust scan_trace callers.
24073 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
24074 INCOMING_FRAME_SP_OFFSET in the CIE.
24075 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
24076 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
24078 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
24079 * doc/tm.texi: Regenerated.
24081 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
24083 PR rtl-optimization/83147
24084 * lra-constraints.c (remove_inheritance_pseudos): Use
24085 lra_substitute_pseudo_within_insn.
24087 2018-01-19 Tom de Vries <tom@codesourcery.com>
24088 Cesar Philippidis <cesar@codesourcery.com>
24091 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
24093 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
24096 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
24097 spaces for function labels.
24099 2018-01-19 Martin Liska <mliska@suse.cz>
24101 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
24102 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
24103 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
24104 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
24105 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
24106 (PRED_CONST_RETURN): Change from 69 to 65.
24107 (PRED_NULL_RETURN): Change from 91 to 71.
24108 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
24109 (PRED_LOOP_GUARD): Change from 66 to 73.
24111 2018-01-19 Martin Liska <mliska@suse.cz>
24113 * predict.c (predict_insn_def): Add new assert.
24114 (struct branch_predictor): Change type to signed integer.
24115 (test_prediction_value_range): Amend test to cover
24116 PROB_UNINITIALIZED.
24117 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
24118 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
24119 (PRED_LOOP_ITERATIONS_MAX): Likewise.
24120 (PRED_LOOP_IV_COMPARE): Likewise.
24121 * predict.h (PROB_UNINITIALIZED): Define new constant.
24123 2018-01-19 Martin Liska <mliska@suse.cz>
24125 * predict.c (dump_prediction): Add new format for
24126 analyze_brprob.py script which is enabled with -details
24128 * profile-count.h (precise_p): New function.
24130 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
24132 PR tree-optimization/83922
24133 * tree-vect-loop.c (vect_verify_full_masking): Return false if
24134 there are no statements that need masking.
24135 (vect_active_double_reduction_p): New function.
24136 (vect_analyze_loop_operations): Use it when handling phis that
24137 are not in the loop header.
24139 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
24141 PR tree-optimization/83914
24142 * tree-vect-loop.c (vectorizable_induction): Don't convert
24143 init_expr or apply the peeling adjustment for inductions
24144 that are nested within the vectorized loop.
24146 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24148 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
24151 2018-01-18 Jakub Jelinek <jakub@redhat.com>
24155 * function.h (gimplify_parameters): Add gimple_seq * argument.
24156 * function.c: Include gimple.h and options.h.
24157 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
24158 for the added local temporaries if needed.
24159 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
24160 if there are any parameter cleanups, wrap whole body into a
24161 try/finally with the cleanups.
24163 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
24166 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
24167 Use GET_MODE_CLASS for scalar floating point.
24169 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
24173 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
24174 Fix call of call_cgraph_insertion_hooks.
24176 2018-01-18 Martin Sebor <msebor@redhat.com>
24178 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
24180 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
24183 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
24186 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
24189 * common.opt: (-ffile-prefix-map): New option.
24190 * opts.c (common_handle_option): Defer it.
24191 * opts-global.c (handle_common_deferred_options): Handle it.
24192 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
24193 * file-prefix-map.h: New file.
24194 (remap_debug_filename, add_debug_prefix_map): ...here.
24195 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
24196 * final.c (debug_prefix_map, add_debug_prefix_map
24197 remap_debug_filename): Move to...
24198 * file-prefix-map.c: New file.
24199 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
24200 generalize, get rid of alloca(), use strrchr() instead of strchr().
24201 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
24202 Implement in terms of add_prefix_map().
24203 (remap_macro_filename, remap_debug_filename): Implement in term of
24205 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
24206 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
24207 * dbxout.c: Include file-prefix-map.h.
24208 * varasm.c: Likewise.
24209 * vmsdbgout.c: Likewise.
24210 * xcoffout.c: Likewise.
24211 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
24212 * doc/cppopts.texi (-fmacro-prefix-map): Document.
24213 * doc/invoke.texi (-ffile-prefix-map): Document.
24214 (-fdebug-prefix-map): Update description.
24216 2018-01-18 Martin Liska <mliska@suse.cz>
24218 * config/i386/i386.c (indirect_thunk_name): Document that also
24220 (output_indirect_thunk): Document why both instructions
24221 (pause and lfence) are generated.
24223 2018-01-18 Richard Biener <rguenther@suse.de>
24225 PR tree-optimization/83887
24226 * graphite-scop-detection.c
24227 (scop_detection::get_nearest_dom_with_single_entry): Remove.
24228 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
24229 (scop_detection::merge_sese): Re-implement with a flood-fill
24230 algorithm that properly finds a SESE region if it exists.
24232 2018-01-18 Jakub Jelinek <jakub@redhat.com>
24235 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
24236 pointer_diff optimizations use view_convert instead of convert.
24238 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24240 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
24241 Generate different code for -mno-speculate-indirect-jumps.
24242 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
24243 (*call_indirect_aix<mode>): Disable for
24244 -mno-speculate-indirect-jumps.
24245 (*call_indirect_aix<mode>_nospec): New define_insn.
24246 (*call_value_indirect_aix<mode>): Disable for
24247 -mno-speculate-indirect-jumps.
24248 (*call_value_indirect_aix<mode>_nospec): New define_insn.
24249 (*sibcall_nonlocal_sysv<mode>): Generate different code for
24250 -mno-speculate-indirect-jumps.
24251 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
24253 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
24255 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
24256 long double type, set the flags for noting the default long double
24257 type, even if we don't pass or return a long double type.
24259 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
24262 * ipa-inline.c (flatten_function): Do not overwrite final inlining
24265 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
24267 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
24268 support for merge[hl].
24269 (fold_mergehl_helper): New helper function.
24270 (tree-vector-builder.h): New #include for tree_vector_builder usage.
24271 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
24272 (altivec_vmrglw_direct): Add xxmrglw insn.
24274 2018-01-17 Andrew Waterman <andrew@sifive.com>
24276 * config/riscv/riscv.c (riscv_conditional_register_usage): If
24277 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
24279 2018-01-17 David Malcolm <dmalcolm@redhat.com>
24282 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
24283 call the lto_location_cache before reading the
24284 DECL_SOURCE_LOCATION of the types.
24286 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
24287 Richard Sandiford <richard.sandiford@linaro.org>
24289 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
24290 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
24291 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
24292 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
24293 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
24295 * config/aarch64/constraints.md (aarch64_movti_operand):
24297 * config/aarch64/predicates.md (Uti): Add new constraint.
24299 2018-01-17 Carl Love <cel@us.ibm.com>
24301 * config/rs6000/vsx.md (define_expand xl_len_r,
24302 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
24303 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
24305 (define_expand, define_insn): Move the shift left from the
24306 define_insn to the define_expand for lxvl and stxvl instructions.
24307 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
24308 and XL_LEN_R definitions to PURE.
24310 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
24312 * config/i386/i386.c (indirect_thunk_name): Declare regno
24313 as unsigned int. Compare regno with INVALID_REGNUM.
24314 (output_indirect_thunk): Ditto.
24315 (output_indirect_thunk_function): Ditto.
24316 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
24317 in the call to output_indirect_thunk_function.
24319 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
24321 PR middle-end/83884
24322 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
24323 rather than the size of inner_type to determine the stack slot size
24324 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
24326 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
24329 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
24332 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
24334 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
24335 endian Linux systems to optionally enable multilibs for selecting
24336 the long double type if the user configured an explicit type.
24337 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
24338 have no long double multilibs if not defined.
24339 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
24340 warn if the user used -mabi={ieee,ibm}longdouble and we built
24341 multilibs for long double.
24342 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
24343 appropriate multilib option.
24344 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
24346 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
24347 for building long double multilibs.
24348 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
24350 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
24352 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
24355 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
24357 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
24360 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
24363 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
24366 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
24368 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
24369 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
24371 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
24373 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
24374 different rtl trees depending on TARGET_64BIT.
24375 (rs6000_gen_lvx): Likewise.
24377 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
24379 * config/visium/visium.md (nop): Tweak comment.
24380 (hazard_nop): Likewise.
24382 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24384 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
24385 -mspeculate-indirect-jumps.
24386 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
24387 for -mno-speculate-indirect-jumps.
24388 (*call_indirect_elfv2<mode>_nospec): New define_insn.
24389 (*call_value_indirect_elfv2<mode>): Disable for
24390 -mno-speculate-indirect-jumps.
24391 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
24392 (indirect_jump): Emit different RTL for
24393 -mno-speculate-indirect-jumps.
24394 (*indirect_jump<mode>): Disable for
24395 -mno-speculate-indirect-jumps.
24396 (*indirect_jump<mode>_nospec): New define_insn.
24397 (tablejump): Emit different RTL for
24398 -mno-speculate-indirect-jumps.
24399 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
24400 (tablejumpsi_nospec): New define_expand.
24401 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
24402 (tablejumpdi_nospec): New define_expand.
24403 (*tablejump<mode>_internal1): Disable for
24404 -mno-speculate-indirect-jumps.
24405 (*tablejump<mode>_internal1_nospec): New define_insn.
24406 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
24409 2018-01-16 Artyom Skrobov tyomitch@gmail.com
24411 * caller-save.c (insert_save): Drop unnecessary parameter. All
24414 2018-01-16 Jakub Jelinek <jakub@redhat.com>
24415 Richard Biener <rguenth@suse.de>
24418 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
24419 return early, inline manually is_gimple_sizepos. Make sure if we
24420 call gimplify_expr we don't end up with a gimple constant.
24421 * tree.c (variably_modified_type_p): Don't return true for
24422 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
24423 * gimplify.h (is_gimple_sizepos): Remove.
24425 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
24427 PR tree-optimization/83857
24428 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
24429 vectorizable_live_operation for pure SLP statements.
24430 (vectorizable_live_operation): Handle PHIs.
24432 2018-01-16 Richard Biener <rguenther@suse.de>
24434 PR tree-optimization/83867
24435 * tree-vect-stmts.c (vect_transform_stmt): Precompute
24436 nested_in_vect_loop_p since the scalar stmt may get invalidated.
24438 2018-01-16 Jakub Jelinek <jakub@redhat.com>
24441 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
24442 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
24443 If off is not INTEGER_CST, issue a may not be aligned warning
24444 rather than isn't aligned. Use isn%'t rather than isn't.
24445 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
24447 <case MULT_EXPR>: Improve the case when bottom and one of the
24448 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
24449 operand, in that case check if the other operand is multiple of
24450 bottom divided by the INTEGER_CST operand.
24452 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
24455 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
24456 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
24457 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
24458 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
24459 * config/pa/pa.c (pa_function_arg_advance): Likewise.
24460 (pa_function_arg, pa_arg_partial_bytes): Likewise.
24461 (pa_function_arg_size): New function.
24463 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
24465 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
24466 in a separate statement.
24468 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
24470 PR tree-optimization/83847
24471 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
24472 group gathers and scatters.
24474 2018-01-16 Jakub Jelinek <jakub@redhat.com>
24476 PR rtl-optimization/86620
24477 * params.def (max-sched-ready-insns): Bump minimum value to 1.
24479 PR rtl-optimization/83213
24480 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
24481 to last if both are JUMP_INSNs.
24483 PR tree-optimization/83843
24484 * gimple-ssa-store-merging.c
24485 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
24486 store_immediate_info for bswap/nop orig_stores.
24488 2018-01-15 Andrew Waterman <andrew@sifive.com>
24490 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
24492 <UDIV>: Increase cost if !TARGET_DIV.
24494 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
24496 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
24497 (define_attr "cr_logical_3op"): New.
24498 (cceq_ior_compare): Adjust.
24499 (cceq_ior_compare_complement): Adjust.
24500 (*cceq_rev_compare): Adjust.
24501 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
24502 (is_cracked_insn): Adjust.
24503 (insn_must_be_first_in_group): Adjust.
24504 * config/rs6000/40x.md: Adjust.
24505 * config/rs6000/440.md: Adjust.
24506 * config/rs6000/476.md: Adjust.
24507 * config/rs6000/601.md: Adjust.
24508 * config/rs6000/603.md: Adjust.
24509 * config/rs6000/6xx.md: Adjust.
24510 * config/rs6000/7450.md: Adjust.
24511 * config/rs6000/7xx.md: Adjust.
24512 * config/rs6000/8540.md: Adjust.
24513 * config/rs6000/cell.md: Adjust.
24514 * config/rs6000/e300c2c3.md: Adjust.
24515 * config/rs6000/e500mc.md: Adjust.
24516 * config/rs6000/e500mc64.md: Adjust.
24517 * config/rs6000/e5500.md: Adjust.
24518 * config/rs6000/e6500.md: Adjust.
24519 * config/rs6000/mpc.md: Adjust.
24520 * config/rs6000/power4.md: Adjust.
24521 * config/rs6000/power5.md: Adjust.
24522 * config/rs6000/power6.md: Adjust.
24523 * config/rs6000/power7.md: Adjust.
24524 * config/rs6000/power8.md: Adjust.
24525 * config/rs6000/power9.md: Adjust.
24526 * config/rs6000/rs64.md: Adjust.
24527 * config/rs6000/titan.md: Adjust.
24529 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
24531 * config/i386/predicates.md (indirect_branch_operand): Rewrite
24532 ix86_indirect_branch_register logic.
24534 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
24536 * config/i386/constraints.md (Bs): Update
24537 ix86_indirect_branch_register check. Don't check
24538 ix86_indirect_branch_register with GOT_memory_operand.
24540 * config/i386/predicates.md (GOT_memory_operand): Don't check
24541 ix86_indirect_branch_register here.
24542 (GOT32_symbol_operand): Likewise.
24544 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
24546 * config/i386/predicates.md (constant_call_address_operand):
24547 Rewrite ix86_indirect_branch_register logic.
24548 (sibcall_insn_operand): Likewise.
24550 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
24552 * config/i386/constraints.md (Bs): Replace
24553 ix86_indirect_branch_thunk_register with
24554 ix86_indirect_branch_register.
24556 * config/i386/i386.md (indirect_jump): Likewise.
24557 (tablejump): Likewise.
24558 (*sibcall_memory): Likewise.
24559 (*sibcall_value_memory): Likewise.
24560 Peepholes of indirect call and jump via memory: Likewise.
24561 * config/i386/i386.opt: Likewise.
24562 * config/i386/predicates.md (indirect_branch_operand): Likewise.
24563 (GOT_memory_operand): Likewise.
24564 (call_insn_operand): Likewise.
24565 (sibcall_insn_operand): Likewise.
24566 (GOT32_symbol_operand): Likewise.
24568 2018-01-15 Jakub Jelinek <jakub@redhat.com>
24570 PR middle-end/83837
24571 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
24572 type rather than type addr's type points to.
24573 (expand_omp_atomic_mutex): Likewise.
24574 (expand_omp_atomic): Likewise.
24576 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
24579 * config/i386/i386.c (output_indirect_thunk_function): Use
24580 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
24581 for __x86_return_thunk.
24583 2018-01-15 Richard Biener <rguenther@suse.de>
24585 PR middle-end/83850
24586 * expmed.c (extract_bit_field_1): Fix typo.
24588 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24591 * config/arm/iterators.md (VF): New mode iterator.
24592 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
24593 Remove integer-related logic from pattern.
24594 (neon_vabd<mode>_3): Likewise.
24596 2018-01-15 Jakub Jelinek <jakub@redhat.com>
24598 PR middle-end/82694
24599 * common.opt (fstrict-overflow): No longer an alias.
24600 (fwrapv-pointer): New option.
24601 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
24602 also for pointer types based on flag_wrapv_pointer.
24603 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
24604 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
24605 opts->x_flag_wrapv got set.
24606 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
24607 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
24608 POINTER_TYPE_OVERFLOW_UNDEFINED.
24609 * match.pd: Likewise in address comparison pattern.
24610 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
24612 2018-01-15 Richard Biener <rguenther@suse.de>
24615 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
24616 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
24617 Reset type names to their identifier if their TYPE_DECL doesn't
24618 have linkage (and thus is used for ODR and devirt).
24619 (save_debug_info_for_decl): Remove.
24620 (save_debug_info_for_type): Likewise.
24621 (add_tree_to_fld_list): Adjust.
24622 * tree-pretty-print.c (dump_generic_node): Make dumping of
24623 type names more robust.
24625 2018-01-15 Richard Biener <rguenther@suse.de>
24627 * BASE-VER: Bump to 8.0.1.
24629 2018-01-14 Martin Sebor <msebor@redhat.com>
24632 * builtins.c (check_access): Avoid warning when the no-warning bit
24635 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
24637 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
24638 * ira-color (allocno_hard_regs_compare): Likewise.
24640 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
24643 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
24644 Use .pushsection/.popsection.
24646 2018-01-14 Martin Sebor <msebor@redhat.com>
24649 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
24651 2018-01-14 Jakub Jelinek <jakub@redhat.com>
24653 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
24654 entry from extra_headers.
24655 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
24656 extra_headers, make the list bitwise identical to the i?86-*-* one.
24658 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
24660 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
24661 -mcmodel=large with -mindirect-branch=thunk,
24662 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
24663 -mfunction-return=thunk-extern.
24664 * doc/invoke.texi: Document -mcmodel=large is incompatible with
24665 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
24666 -mfunction-return=thunk and -mfunction-return=thunk-extern.
24668 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
24670 * config/i386/i386.c (print_reg): Print the name of the full
24671 integer register without '%'.
24672 (ix86_print_operand): Handle 'V'.
24673 * doc/extend.texi: Document 'V' modifier.
24675 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
24677 * config/i386/constraints.md (Bs): Disallow memory operand for
24678 -mindirect-branch-register.
24680 * config/i386/predicates.md (indirect_branch_operand): Likewise.
24681 (GOT_memory_operand): Likewise.
24682 (call_insn_operand): Likewise.
24683 (sibcall_insn_operand): Likewise.
24684 (GOT32_symbol_operand): Likewise.
24685 * config/i386/i386.md (indirect_jump): Call convert_memory_address
24686 for -mindirect-branch-register.
24687 (tablejump): Likewise.
24688 (*sibcall_memory): Likewise.
24689 (*sibcall_value_memory): Likewise.
24690 Disallow peepholes of indirect call and jump via memory for
24691 -mindirect-branch-register.
24692 (*call_pop): Replace m with Bw.
24693 (*call_value_pop): Likewise.
24694 (*sibcall_pop_memory): Replace m with Bs.
24695 * config/i386/i386.opt (mindirect-branch-register): New option.
24696 * doc/invoke.texi: Document -mindirect-branch-register option.
24698 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
24700 * config/i386/i386-protos.h (ix86_output_function_return): New.
24701 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
24702 set function_return_type.
24703 (indirect_thunk_name): Add ret_p to indicate thunk for function
24705 (output_indirect_thunk_function): Pass false to
24706 indirect_thunk_name.
24707 (ix86_output_indirect_branch_via_reg): Likewise.
24708 (ix86_output_indirect_branch_via_push): Likewise.
24709 (output_indirect_thunk_function): Create alias for function
24710 return thunk if regno < 0.
24711 (ix86_output_function_return): New function.
24712 (ix86_handle_fndecl_attribute): Handle function_return.
24713 (ix86_attribute_table): Add function_return.
24714 * config/i386/i386.h (machine_function): Add
24715 function_return_type.
24716 * config/i386/i386.md (simple_return_internal): Use
24717 ix86_output_function_return.
24718 (simple_return_internal_long): Likewise.
24719 * config/i386/i386.opt (mfunction-return=): New option.
24720 (indirect_branch): Mention -mfunction-return=.
24721 * doc/extend.texi: Document function_return function attribute.
24722 * doc/invoke.texi: Document -mfunction-return= option.
24724 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
24726 * config/i386/i386-opts.h (indirect_branch): New.
24727 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
24728 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
24729 with local indirect jump when converting indirect call and jump.
24730 (ix86_set_indirect_branch_type): New.
24731 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
24732 (indirectlabelno): New.
24733 (indirect_thunk_needed): Likewise.
24734 (indirect_thunk_bnd_needed): Likewise.
24735 (indirect_thunks_used): Likewise.
24736 (indirect_thunks_bnd_used): Likewise.
24737 (INDIRECT_LABEL): Likewise.
24738 (indirect_thunk_name): Likewise.
24739 (output_indirect_thunk): Likewise.
24740 (output_indirect_thunk_function): Likewise.
24741 (ix86_output_indirect_branch_via_reg): Likewise.
24742 (ix86_output_indirect_branch_via_push): Likewise.
24743 (ix86_output_indirect_branch): Likewise.
24744 (ix86_output_indirect_jmp): Likewise.
24745 (ix86_code_end): Call output_indirect_thunk_function if needed.
24746 (ix86_output_call_insn): Call ix86_output_indirect_branch if
24748 (ix86_handle_fndecl_attribute): Handle indirect_branch.
24749 (ix86_attribute_table): Add indirect_branch.
24750 * config/i386/i386.h (machine_function): Add indirect_branch_type
24751 and has_local_indirect_jump.
24752 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
24754 (tablejump): Likewise.
24755 (*indirect_jump): Use ix86_output_indirect_jmp.
24756 (*tablejump_1): Likewise.
24757 (simple_return_indirect_internal): Likewise.
24758 * config/i386/i386.opt (mindirect-branch=): New option.
24759 (indirect_branch): New.
24762 (thunk-inline): Likewise.
24763 (thunk-extern): Likewise.
24764 * doc/extend.texi: Document indirect_branch function attribute.
24765 * doc/invoke.texi: Document -mindirect-branch= option.
24767 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
24770 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
24772 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
24774 * ipa-inline.c (want_inline_small_function_p): Return false if
24775 inlining has already failed with CIF_FINAL_ERROR.
24776 (update_caller_keys): Call want_inline_small_function_p before
24778 (update_callee_keys): Likewise.
24780 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
24782 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
24784 (rs6000_quadword_masked_address_p): Likewise.
24785 (quad_aligned_load_p): Likewise.
24786 (quad_aligned_store_p): Likewise.
24787 (const_load_sequence_p): Add comment to describe the outer-most loop.
24788 (mimic_memory_attributes_and_flags): New function.
24789 (rs6000_gen_stvx): Likewise.
24790 (replace_swapped_aligned_store): Likewise.
24791 (rs6000_gen_lvx): Likewise.
24792 (replace_swapped_aligned_load): Likewise.
24793 (replace_swapped_load_constant): Capitalize argument name in
24794 comment describing this function.
24795 (rs6000_analyze_swaps): Add a third pass to search for vector loads
24796 and stores that access quad-word aligned addresses and replace
24797 with stvx or lvx instructions when appropriate.
24798 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
24799 New function prototype.
24800 (rs6000_quadword_masked_address_p): Likewise.
24801 (rs6000_gen_lvx): Likewise.
24802 (rs6000_gen_stvx): Likewise.
24803 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
24804 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
24805 when memory address is aligned.
24806 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
24807 this split to select lvx instruction when memory address is aligned.
24808 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
24809 instruction when memory address is aligned.
24810 (*vsx_le_perm_load_v16qi): Likewise.
24811 (four unnamed splitters): Modify to select the stvx instruction
24812 when memory is aligned.
24814 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
24816 * predict.c (determine_unlikely_bbs): Handle correctly BBs
24817 which appears in the queue multiple times.
24819 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
24820 Alan Hayward <alan.hayward@arm.com>
24821 David Sherwood <david.sherwood@arm.com>
24823 * tree-vectorizer.h (vec_lower_bound): New structure.
24824 (_loop_vec_info): Add check_nonzero and lower_bounds.
24825 (LOOP_VINFO_CHECK_NONZERO): New macro.
24826 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
24827 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
24828 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
24829 fields. Make seg_len the distance travelled, not including the
24831 (dr_direction_indicator): Declare.
24832 (dr_zero_step_indicator): Likewise.
24833 (dr_known_forward_stride_p): Likewise.
24834 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
24836 (runtime_alias_check_p): Allow runtime alias checks with
24838 (operator ==): Compare access_size and align.
24839 (prune_runtime_alias_test_list): Rework for new distinction between
24840 the access_size and seg_len.
24841 (create_intersect_range_checks_index): Likewise. Cope with polynomial
24843 (get_segment_min_max): New function.
24844 (create_intersect_range_checks): Use it.
24845 (dr_step_indicator): New function.
24846 (dr_direction_indicator): Likewise.
24847 (dr_zero_step_indicator): Likewise.
24848 (dr_known_forward_stride_p): Likewise.
24849 * tree-loop-distribution.c (data_ref_segment_size): Return
24850 DR_STEP * (niters - 1).
24851 (compute_alias_check_pairs): Update call to the dr_with_seg_len
24853 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
24854 (vect_preserves_scalar_order_p): New function, split out from...
24855 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
24856 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
24857 (vect_vfa_access_size): New function.
24858 (vect_vfa_align): Likewise.
24859 (vect_compile_time_alias): Take access_size_a and access_b arguments.
24860 (dump_lower_bound): New function.
24861 (vect_check_lower_bound): Likewise.
24862 (vect_small_gap_p): Likewise.
24863 (vectorizable_with_step_bound_p): Likewise.
24864 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
24865 depencies if the vectorization factor is 1. Convert the checks
24866 for nonzero steps into checks on the bounds of DR_STEP. Try using
24867 a bunds check for variable steps if the minimum required step is
24868 relatively small. Update calls to the dr_with_seg_len
24869 constructor and to vect_compile_time_alias.
24870 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
24872 (vect_loop_versioning): Call it.
24873 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
24875 (vect_estimate_min_profitable_iters): Account for any bounds checks.
24877 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
24878 Alan Hayward <alan.hayward@arm.com>
24879 David Sherwood <david.sherwood@arm.com>
24881 * doc/sourcebuild.texi (vect_scatter_store): Document.
24882 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
24884 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
24886 * genopinit.c (main): Add supports_vec_scatter_store and
24887 supports_vec_scatter_store_cached to target_optabs.
24888 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
24889 IFN_MASK_SCATTER_STORE.
24890 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
24892 * internal-fn.h (internal_store_fn_p): Declare.
24893 (internal_fn_stored_value_index): Likewise.
24894 * internal-fn.c (scatter_store_direct): New macro.
24895 (expand_scatter_store_optab_fn): New function.
24896 (direct_scatter_store_optab_supported_p): New macro.
24897 (internal_store_fn_p): New function.
24898 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
24899 IFN_MASK_SCATTER_STORE.
24900 (internal_fn_mask_index): Likewise.
24901 (internal_fn_stored_value_index): New function.
24902 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
24903 for scatter stores.
24904 * optabs-query.h (supports_vec_scatter_store_p): Declare.
24905 * optabs-query.c (supports_vec_scatter_store_p): New function.
24906 * tree-vectorizer.h (vect_get_store_rhs): Declare.
24907 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
24908 true for scatter stores.
24909 (vect_gather_scatter_fn_p): Handle scatter stores too.
24910 (vect_check_gather_scatter): Consider using scatter stores if
24911 supports_vec_scatter_store_p.
24912 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
24913 scatter stores too.
24914 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
24915 internal_fn_stored_value_index.
24916 (check_load_store_masking): Handle scatter stores too.
24917 (vect_get_store_rhs): Make public.
24918 (vectorizable_call): Use internal_store_fn_p.
24919 (vectorizable_store): Handle scatter store internal functions.
24920 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
24921 when deciding whether the end of the group has been reached.
24922 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
24923 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
24924 (mask_scatter_store<mode>): New insns.
24926 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
24927 Alan Hayward <alan.hayward@arm.com>
24928 David Sherwood <david.sherwood@arm.com>
24930 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
24931 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
24932 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
24934 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
24935 Use vect_truncate_gather_scatter_offset if we can't treat the
24936 operation as a normal gather load or scatter store.
24937 (get_group_load_store_type): Take the gather_scatter_info
24938 as argument. Try using a gather load or scatter store for
24939 single-element groups.
24940 (get_load_store_type): Update calls to get_group_load_store_type
24941 and vect_use_strided_gather_scatters_p.
24943 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
24944 Alan Hayward <alan.hayward@arm.com>
24945 David Sherwood <david.sherwood@arm.com>
24947 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
24948 optional tree argument.
24949 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
24951 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
24952 but continue to use the current value as a fallback.
24953 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
24954 to compare the updates.
24955 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
24956 (get_load_store_type): Use it when handling a strided access.
24957 (vect_get_strided_load_store_ops): New function.
24958 (vect_get_data_ptr_increment): Likewise.
24959 (vectorizable_load): Handle strided gather loads. Always pass
24960 a step to vect_create_data_ref_ptr and bump_vector_ptr.
24962 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
24963 Alan Hayward <alan.hayward@arm.com>
24964 David Sherwood <david.sherwood@arm.com>
24966 * doc/md.texi (gather_load@var{m}): Document.
24967 (mask_gather_load@var{m}): Likewise.
24968 * genopinit.c (main): Add supports_vec_gather_load and
24969 supports_vec_gather_load_cached to target_optabs.
24970 * optabs-tree.c (init_tree_optimization_optabs): Use
24971 ggc_cleared_alloc to allocate target_optabs.
24972 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
24973 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
24975 * internal-fn.h (internal_load_fn_p): Declare.
24976 (internal_gather_scatter_fn_p): Likewise.
24977 (internal_fn_mask_index): Likewise.
24978 (internal_gather_scatter_fn_supported_p): Likewise.
24979 * internal-fn.c (gather_load_direct): New macro.
24980 (expand_gather_load_optab_fn): New function.
24981 (direct_gather_load_optab_supported_p): New macro.
24982 (direct_internal_fn_optab): New function.
24983 (internal_load_fn_p): Likewise.
24984 (internal_gather_scatter_fn_p): Likewise.
24985 (internal_fn_mask_index): Likewise.
24986 (internal_gather_scatter_fn_supported_p): Likewise.
24987 * optabs-query.c (supports_at_least_one_mode_p): New function.
24988 (supports_vec_gather_load_p): Likewise.
24989 * optabs-query.h (supports_vec_gather_load_p): Declare.
24990 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
24991 and memory_type field.
24992 (NUM_PATTERNS): Bump to 15.
24993 * tree-vect-data-refs.c: Include internal-fn.h.
24994 (vect_gather_scatter_fn_p): New function.
24995 (vect_describe_gather_scatter_call): Likewise.
24996 (vect_check_gather_scatter): Try using internal functions for
24997 gather loads. Recognize existing calls to a gather load function.
24998 (vect_analyze_data_refs): Consider using gather loads if
24999 supports_vec_gather_load_p.
25000 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
25001 (vect_get_gather_scatter_offset_type): Likewise.
25002 (vect_convert_mask_for_vectype): Likewise.
25003 (vect_add_conversion_to_patterm): Likewise.
25004 (vect_try_gather_scatter_pattern): Likewise.
25005 (vect_recog_gather_scatter_pattern): New pattern recognizer.
25006 (vect_vect_recog_func_ptrs): Add it.
25007 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
25008 internal_fn_mask_index and internal_gather_scatter_fn_p.
25009 (check_load_store_masking): Take the gather_scatter_info as an
25010 argument and handle gather loads.
25011 (vect_get_gather_scatter_ops): New function.
25012 (vectorizable_call): Check internal_load_fn_p.
25013 (vectorizable_load): Likewise. Handle gather load internal
25015 (vectorizable_store): Update call to check_load_store_masking.
25016 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
25017 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
25018 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
25019 (aarch64_gather_scale_operand_d): New predicates.
25020 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
25021 (mask_gather_load<mode>): New insns.
25023 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25024 Alan Hayward <alan.hayward@arm.com>
25025 David Sherwood <david.sherwood@arm.com>
25027 * optabs.def (fold_left_plus_optab): New optab.
25028 * doc/md.texi (fold_left_plus_@var{m}): Document.
25029 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
25030 * internal-fn.c (fold_left_direct): Define.
25031 (expand_fold_left_optab_fn): Likewise.
25032 (direct_fold_left_optab_supported_p): Likewise.
25033 * fold-const-call.c (fold_const_fold_left): New function.
25034 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
25035 * tree-parloops.c (valid_reduction_p): New function.
25036 (gather_scalar_reductions): Use it.
25037 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
25038 (vect_finish_replace_stmt): Declare.
25039 * tree-vect-loop.c (fold_left_reduction_fn): New function.
25040 (needs_fold_left_reduction_p): New function, split out from...
25041 (vect_is_simple_reduction): ...here. Accept reductions that
25042 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
25043 (vect_force_simple_reduction): Also store the reduction type in
25044 the assignment's STMT_VINFO_REDUC_TYPE.
25045 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
25046 (merge_with_identity): New function.
25047 (vect_expand_fold_left): Likewise.
25048 (vectorize_fold_left_reduction): Likewise.
25049 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
25050 scalar phi in place for it. Check for target support and reject
25051 cases that would reassociate the operation. Defer the transform
25052 phase to vectorize_fold_left_reduction.
25053 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
25054 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
25055 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
25057 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25059 * tree-if-conv.c (predicate_mem_writes): Remove redundant
25060 call to ifc_temp_var.
25062 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25063 Alan Hayward <alan.hayward@arm.com>
25064 David Sherwood <david.sherwood@arm.com>
25066 * target.def (legitimize_address_displacement): Take the original
25067 offset as a poly_int.
25068 * targhooks.h (default_legitimize_address_displacement): Update
25070 * targhooks.c (default_legitimize_address_displacement): Likewise.
25071 * doc/tm.texi: Regenerate.
25072 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
25073 as an argument, moving assert of ad->disp == ad->disp_term to...
25074 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
25075 Try calling targetm.legitimize_address_displacement before expanding
25076 the address rather than afterwards, and adjust for the new interface.
25077 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
25078 Match the new hook interface. Handle SVE addresses.
25079 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
25080 new hook interface.
25082 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25084 * Makefile.in (OBJS): Add early-remat.o.
25085 * target.def (select_early_remat_modes): New hook.
25086 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
25087 * doc/tm.texi: Regenerate.
25088 * targhooks.h (default_select_early_remat_modes): Declare.
25089 * targhooks.c (default_select_early_remat_modes): New function.
25090 * timevar.def (TV_EARLY_REMAT): New timevar.
25091 * passes.def (pass_early_remat): New pass.
25092 * tree-pass.h (make_pass_early_remat): Declare.
25093 * early-remat.c: New file.
25094 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
25096 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
25098 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25099 Alan Hayward <alan.hayward@arm.com>
25100 David Sherwood <david.sherwood@arm.com>
25102 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
25103 vfm1 with a bound_epilog parameter.
25104 (vect_do_peeling): Update calls accordingly, and move the prologue
25105 call earlier in the function. Treat the base bound_epilog as 0 for
25106 fully-masked loops and retain vf - 1 for other loops. Add 1 to
25107 this base when peeling for gaps.
25108 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
25109 with fully-masked loops.
25110 (vect_estimate_min_profitable_iters): Handle the single peeled
25111 iteration in that case.
25113 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25114 Alan Hayward <alan.hayward@arm.com>
25115 David Sherwood <david.sherwood@arm.com>
25117 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
25118 single-element interleaving even if the size is not a power of 2.
25119 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
25120 accesses for single-element interleaving if the group size is
25123 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25124 Alan Hayward <alan.hayward@arm.com>
25125 David Sherwood <david.sherwood@arm.com>
25127 * doc/md.texi (fold_extract_last_@var{m}): Document.
25128 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
25129 * optabs.def (fold_extract_last_optab): New optab.
25130 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
25131 * internal-fn.c (fold_extract_direct): New macro.
25132 (expand_fold_extract_optab_fn): Likewise.
25133 (direct_fold_extract_optab_supported_p): Likewise.
25134 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
25135 * tree-vect-loop.c (vect_model_reduction_cost): Handle
25136 EXTRACT_LAST_REDUCTION.
25137 (get_initial_def_for_reduction): Do not create an initial vector
25138 for EXTRACT_LAST_REDUCTION reductions.
25139 (vectorizable_reduction): Leave the scalar phi in place for
25140 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
25141 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
25142 epilogue code for EXTRACT_LAST_REDUCTION and defer the
25143 transform phase to vectorizable_condition.
25144 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
25146 (vect_finish_stmt_generation): ...here.
25147 (vect_finish_replace_stmt): New function.
25148 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
25149 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
25151 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
25153 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25154 Alan Hayward <alan.hayward@arm.com>
25155 David Sherwood <david.sherwood@arm.com>
25157 * doc/md.texi (extract_last_@var{m}): Document.
25158 * optabs.def (extract_last_optab): New optab.
25159 * internal-fn.def (EXTRACT_LAST): New internal function.
25160 * internal-fn.c (cond_unary_direct): New macro.
25161 (expand_cond_unary_optab_fn): Likewise.
25162 (direct_cond_unary_optab_supported_p): Likewise.
25163 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
25164 loops using EXTRACT_LAST.
25165 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
25166 (extract_last_<mode>): ...this optab.
25167 (vec_extract<mode><Vel>): Update accordingly.
25169 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25170 Alan Hayward <alan.hayward@arm.com>
25171 David Sherwood <david.sherwood@arm.com>
25173 * target.def (empty_mask_is_expensive): New hook.
25174 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
25175 * doc/tm.texi: Regenerate.
25176 * targhooks.h (default_empty_mask_is_expensive): Declare.
25177 * targhooks.c (default_empty_mask_is_expensive): New function.
25178 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
25179 if the target says that empty masks are expensive.
25180 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
25182 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
25184 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25185 Alan Hayward <alan.hayward@arm.com>
25186 David Sherwood <david.sherwood@arm.com>
25188 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
25189 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
25190 (vect_use_loop_mask_for_alignment_p): New function.
25191 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
25192 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
25193 niters_skip argument. Make sure that the first niters_skip elements
25194 of the first iteration are inactive.
25195 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
25196 Update call to vect_set_loop_masks_directly.
25197 (get_misalign_in_elems): New function, split out from...
25198 (vect_gen_prolog_loop_niters): ...here.
25199 (vect_update_init_of_dr): Take a code argument that specifies whether
25200 the adjustment should be added or subtracted.
25201 (vect_update_init_of_drs): Likewise.
25202 (vect_prepare_for_masked_peels): New function.
25203 (vect_do_peeling): Skip prologue peeling if we're using a mask
25204 instead. Update call to vect_update_inits_of_drs.
25205 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
25207 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
25208 alignment. Do not include the number of peeled iterations in
25209 the minimum threshold in that case.
25210 (vectorizable_induction): Adjust the start value down by
25211 LOOP_VINFO_MASK_SKIP_NITERS iterations.
25212 (vect_transform_loop): Call vect_prepare_for_masked_peels.
25213 Take the number of skipped iterations into account when calculating
25215 * tree-vect-stmts.c (vect_gen_while_not): New function.
25217 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25218 Alan Hayward <alan.hayward@arm.com>
25219 David Sherwood <david.sherwood@arm.com>
25221 * doc/sourcebuild.texi (vect_fully_masked): Document.
25222 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
25223 default value to 0.
25224 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
25226 (vect_analyze_loop_2): ...here. Don't check the vectorization
25227 factor against the number of loop iterations if the loop is
25230 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25231 Alan Hayward <alan.hayward@arm.com>
25232 David Sherwood <david.sherwood@arm.com>
25234 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
25235 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
25236 (dump_groups): Update accordingly.
25237 (iv_use::mem_type): New member variable.
25238 (address_p): New function.
25239 (record_use): Add a mem_type argument and initialize the new
25241 (record_group_use): Add a mem_type argument. Use address_p.
25242 Remove obsolete null checks of base_object. Update call to record_use.
25243 (find_interesting_uses_op): Update call to record_group_use.
25244 (find_interesting_uses_cond): Likewise.
25245 (find_interesting_uses_address): Likewise.
25246 (get_mem_type_for_internal_fn): New function.
25247 (find_address_like_use): Likewise.
25248 (find_interesting_uses_stmt): Try find_address_like_use before
25249 calling find_interesting_uses_op.
25250 (addr_offset_valid_p): Use the iv mem_type field as the type
25251 of the addressed memory.
25252 (add_autoinc_candidates): Likewise.
25253 (get_address_cost): Likewise.
25254 (split_small_address_groups_p): Use address_p.
25255 (split_address_groups): Likewise.
25256 (add_iv_candidate_for_use): Likewise.
25257 (autoinc_possible_for_pair): Likewise.
25258 (rewrite_groups): Likewise.
25259 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
25260 (determine_group_iv_cost): Update after split of USE_ADDRESS.
25261 (get_alias_ptr_type_for_ptr_address): New function.
25262 (rewrite_use_address): Rewrite address uses in calls that were
25263 identified by find_address_like_use.
25265 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25266 Alan Hayward <alan.hayward@arm.com>
25267 David Sherwood <david.sherwood@arm.com>
25269 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
25271 * gimple-expr.h (is_gimple_addressable: Likewise.
25272 * gimple-expr.c (is_gimple_address): Likewise.
25273 * internal-fn.c (expand_call_mem_ref): New function.
25274 (expand_mask_load_optab_fn): Use it.
25275 (expand_mask_store_optab_fn): Likewise.
25277 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25278 Alan Hayward <alan.hayward@arm.com>
25279 David Sherwood <david.sherwood@arm.com>
25281 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
25282 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
25283 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
25284 (cond_umax@var{mode}): Document.
25285 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
25286 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
25287 (cond_umin_optab, cond_umax_optab): New optabs.
25288 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
25289 (COND_IOR, COND_XOR): New internal functions.
25290 * internal-fn.h (get_conditional_internal_fn): Declare.
25291 * internal-fn.c (cond_binary_direct): New macro.
25292 (expand_cond_binary_optab_fn): Likewise.
25293 (direct_cond_binary_optab_supported_p): Likewise.
25294 (get_conditional_internal_fn): New function.
25295 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
25296 Cope with reduction statements that are vectorized as calls rather
25298 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
25299 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
25300 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
25301 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
25302 (UNSPEC_COND_EOR): New unspecs.
25303 (optab): Add mappings for them.
25304 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
25305 (sve_int_op, sve_fp_op): New int attributes.
25307 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25308 Alan Hayward <alan.hayward@arm.com>
25309 David Sherwood <david.sherwood@arm.com>
25311 * optabs.def (while_ult_optab): New optab.
25312 * doc/md.texi (while_ult@var{m}@var{n}): Document.
25313 * internal-fn.def (WHILE_ULT): New internal function.
25314 * internal-fn.h (direct_internal_fn_supported_p): New override
25315 that takes two types as argument.
25316 * internal-fn.c (while_direct): New macro.
25317 (expand_while_optab_fn): New function.
25318 (convert_optab_supported_p): Likewise.
25319 (direct_while_optab_supported_p): New macro.
25320 * wide-int.h (wi::udiv_ceil): New function.
25321 * tree-vectorizer.h (rgroup_masks): New structure.
25322 (vec_loop_masks): New typedef.
25323 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
25324 and fully_masked_p.
25325 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
25326 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
25327 (vect_max_vf): New function.
25328 (slpeel_make_loop_iterate_ntimes): Delete.
25329 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
25330 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
25331 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
25332 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
25333 internal-fn.h, stor-layout.h and optabs-query.h.
25334 (vect_set_loop_mask): New function.
25335 (add_preheader_seq): Likewise.
25336 (add_header_seq): Likewise.
25337 (interleave_supported_p): Likewise.
25338 (vect_maybe_permute_loop_masks): Likewise.
25339 (vect_set_loop_masks_directly): Likewise.
25340 (vect_set_loop_condition_masked): Likewise.
25341 (vect_set_loop_condition_unmasked): New function, split out from
25342 slpeel_make_loop_iterate_ntimes.
25343 (slpeel_make_loop_iterate_ntimes): Rename to..
25344 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
25345 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
25346 (vect_do_peeling): Update call accordingly.
25347 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
25349 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
25350 mask_compare_type, can_fully_mask_p and fully_masked_p.
25351 (release_vec_loop_masks): New function.
25352 (_loop_vec_info): Use it to free the loop masks.
25353 (can_produce_all_loop_masks_p): New function.
25354 (vect_get_max_nscalars_per_iter): Likewise.
25355 (vect_verify_full_masking): Likewise.
25356 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
25357 retries, and free the mask rgroups before retrying. Check loop-wide
25358 reasons for disallowing fully-masked loops. Make the final decision
25359 about whether use a fully-masked loop or not.
25360 (vect_estimate_min_profitable_iters): Do not assume that peeling
25361 for the number of iterations will be needed for fully-masked loops.
25362 (vectorizable_reduction): Disable fully-masked loops.
25363 (vectorizable_live_operation): Likewise.
25364 (vect_halve_mask_nunits): New function.
25365 (vect_double_mask_nunits): Likewise.
25366 (vect_record_loop_mask): Likewise.
25367 (vect_get_loop_mask): Likewise.
25368 (vect_transform_loop): Handle the case in which the final loop
25369 iteration might handle a partial vector. Call vect_set_loop_condition
25370 instead of slpeel_make_loop_iterate_ntimes.
25371 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
25372 (check_load_store_masking): New function.
25373 (prepare_load_store_mask): Likewise.
25374 (vectorizable_store): Handle fully-masked loops.
25375 (vectorizable_load): Likewise.
25376 (supportable_widening_operation): Use vect_halve_mask_nunits for
25378 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
25379 (vect_gen_while): New function.
25380 * config/aarch64/aarch64.md (umax<mode>3): New expander.
25381 (aarch64_uqdec<mode>): New insn.
25383 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25384 Alan Hayward <alan.hayward@arm.com>
25385 David Sherwood <david.sherwood@arm.com>
25387 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
25388 (reduc_xor_scal_optab): New optabs.
25389 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
25390 (reduc_xor_scal_@var{m}): Document.
25391 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
25392 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
25393 internal functions.
25394 * fold-const-call.c (fold_const_call): Handle them.
25395 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
25396 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
25397 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
25398 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
25399 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
25400 (UNSPEC_XORV): New unspecs.
25401 (optab): Add entries for them.
25402 (BITWISEV): New int iterator.
25403 (bit_reduc_op): New int attributes.
25405 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25406 Alan Hayward <alan.hayward@arm.com>
25407 David Sherwood <david.sherwood@arm.com>
25409 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
25410 * internal-fn.def (VEC_SHL_INSERT): New internal function.
25411 * optabs.def (vec_shl_insert_optab): New optab.
25412 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
25413 (duplicate_and_interleave): Likewise.
25414 * tree-vect-loop.c: Include internal-fn.h.
25415 (neutral_op_for_slp_reduction): New function, split out from
25416 get_initial_defs_for_reduction.
25417 (get_initial_def_for_reduction): Handle option 2 for variable-length
25418 vectors by loading the neutral value into a vector and then shifting
25419 the initial value into element 0.
25420 (get_initial_defs_for_reduction): Replace the code argument with
25421 the neutral value calculated by neutral_op_for_slp_reduction.
25422 Use gimple_build_vector for constant-length vectors.
25423 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
25424 but the first group_size elements have a neutral value.
25425 Use duplicate_and_interleave otherwise.
25426 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
25427 Update call to get_initial_defs_for_reduction. Handle SLP
25428 reductions for variable-length vectors by creating one vector
25429 result for each scalar result, with the elements associated
25430 with other scalar results stubbed out with the neutral value.
25431 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
25432 Require IFN_VEC_SHL_INSERT for double reductions on
25433 variable-length vectors, or SLP reductions that have
25434 a neutral value. Require can_duplicate_and_interleave_p
25435 support for variable-length unchained SLP reductions if there
25436 is no neutral value, such as for MIN/MAX reductions. Also require
25437 the number of vector elements to be a multiple of the number of
25438 SLP statements when doing variable-length unchained SLP reductions.
25439 Update call to vect_create_epilog_for_reduction.
25440 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
25441 and remove initial values.
25442 (duplicate_and_interleave): Make public.
25443 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
25444 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
25446 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25447 Alan Hayward <alan.hayward@arm.com>
25448 David Sherwood <david.sherwood@arm.com>
25450 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
25451 (can_duplicate_and_interleave_p): New function.
25452 (vect_get_and_check_slp_defs): Take the vector of statements
25453 rather than just the current one. Remove excess parentheses.
25454 Restriction rejectinon of vect_constant_def and vect_external_def
25455 for variable-length vectors to boolean types, or types for which
25456 can_duplicate_and_interleave_p is false.
25457 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
25458 (duplicate_and_interleave): New function.
25459 (vect_get_constant_vectors): Use gimple_build_vector for
25460 constant-length vectors and suitable variable-length constant
25461 vectors. Use duplicate_and_interleave for other variable-length
25462 vectors. Don't defer the update when inserting new statements.
25464 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25465 Alan Hayward <alan.hayward@arm.com>
25466 David Sherwood <david.sherwood@arm.com>
25468 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
25469 min_profitable_iters doesn't go negative.
25471 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25472 Alan Hayward <alan.hayward@arm.com>
25473 David Sherwood <david.sherwood@arm.com>
25475 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
25476 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
25477 * optabs.def (vec_mask_load_lanes_optab): New optab.
25478 (vec_mask_store_lanes_optab): Likewise.
25479 * internal-fn.def (MASK_LOAD_LANES): New internal function.
25480 (MASK_STORE_LANES): Likewise.
25481 * internal-fn.c (mask_load_lanes_direct): New macro.
25482 (mask_store_lanes_direct): Likewise.
25483 (expand_mask_load_optab_fn): Handle masked operations.
25484 (expand_mask_load_lanes_optab_fn): New macro.
25485 (expand_mask_store_optab_fn): Handle masked operations.
25486 (expand_mask_store_lanes_optab_fn): New macro.
25487 (direct_mask_load_lanes_optab_supported_p): Likewise.
25488 (direct_mask_store_lanes_optab_supported_p): Likewise.
25489 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
25491 (vect_load_lanes_supported): Likewise.
25492 * tree-vect-data-refs.c (strip_conversion): New function.
25493 (can_group_stmts_p): Likewise.
25494 (vect_analyze_data_ref_accesses): Use it instead of checking
25495 for a pair of assignments.
25496 (vect_store_lanes_supported): Take a masked_p parameter.
25497 (vect_load_lanes_supported): Likewise.
25498 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
25499 vect_store_lanes_supported and vect_load_lanes_supported.
25500 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
25501 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
25502 parameter. Don't allow gaps for masked accesses.
25503 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
25504 and vect_load_lanes_supported.
25505 (get_load_store_type): Take a masked_p parameter and update
25506 call to get_group_load_store_type.
25507 (vectorizable_store): Update call to get_load_store_type.
25508 Handle IFN_MASK_STORE_LANES.
25509 (vectorizable_load): Update call to get_load_store_type.
25510 Handle IFN_MASK_LOAD_LANES.
25512 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25513 Alan Hayward <alan.hayward@arm.com>
25514 David Sherwood <david.sherwood@arm.com>
25516 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
25518 * config/aarch64/aarch64-protos.h
25519 (aarch64_sve_struct_memory_operand_p): Declare.
25520 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
25521 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
25522 (VPRED, vpred): Handle SVE structure modes.
25523 * config/aarch64/constraints.md (Utx): New constraint.
25524 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
25525 (aarch64_sve_struct_nonimmediate_operand): New predicates.
25526 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
25527 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
25528 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
25529 structure modes. Split into pieces after RA.
25530 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
25531 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
25533 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
25534 SVE structure modes.
25535 (aarch64_classify_address): Likewise.
25536 (sizetochar): Move earlier in file.
25537 (aarch64_print_operand): Handle SVE register lists.
25538 (aarch64_array_mode): New function.
25539 (aarch64_sve_struct_memory_operand_p): Likewise.
25540 (TARGET_ARRAY_MODE): Redefine.
25542 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25543 Alan Hayward <alan.hayward@arm.com>
25544 David Sherwood <david.sherwood@arm.com>
25546 * target.def (array_mode): New target hook.
25547 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
25548 * doc/tm.texi: Regenerate.
25549 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
25550 * hooks.c (hook_optmode_mode_uhwi_none): New function.
25551 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
25552 targetm.array_mode.
25553 * stor-layout.c (mode_for_array): Likewise. Support polynomial
25556 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25557 Alan Hayward <alan.hayward@arm.com>
25558 David Sherwood <david.sherwood@arm.com>
25560 * fold-const.c (fold_binary_loc): Check the argument types
25561 rather than the result type when testing for a vector operation.
25563 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25565 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
25566 * doc/tm.texi: Regenerate.
25568 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25569 Alan Hayward <alan.hayward@arm.com>
25570 David Sherwood <david.sherwood@arm.com>
25572 * doc/invoke.texi (-msve-vector-bits=): Document new option.
25573 (sve): Document new AArch64 extension.
25574 * doc/md.texi (w): Extend the description of the AArch64
25575 constraint to include SVE vectors.
25576 (Upl, Upa): Document new AArch64 predicate constraints.
25577 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
25579 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
25580 (msve-vector-bits=): New option.
25581 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
25582 SVE when these are disabled.
25583 (sve): New extension.
25584 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
25585 modes. Adjust their number of units based on aarch64_sve_vg.
25586 (MAX_BITSIZE_MODE_ANY_MODE): Define.
25587 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
25588 aarch64_addr_query_type.
25589 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
25590 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
25591 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
25592 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
25593 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
25594 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
25595 (aarch64_simd_imm_zero_p): Delete.
25596 (aarch64_check_zero_based_sve_index_immediate): Declare.
25597 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
25598 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
25599 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
25600 (aarch64_sve_float_mul_immediate_p): Likewise.
25601 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
25602 rather than an rtx.
25603 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
25604 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
25605 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
25606 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
25607 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
25608 (aarch64_regmode_natural_size): Likewise.
25609 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
25610 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
25612 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
25613 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
25614 for VG and the SVE predicate registers.
25615 (V_ALIASES): Add a "z"-prefixed alias.
25616 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
25617 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
25618 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
25619 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
25620 (REG_CLASS_NAMES): Add entries for them.
25621 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
25622 and the predicate registers.
25623 (aarch64_sve_vg): Declare.
25624 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
25625 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
25626 (REGMODE_NATURAL_SIZE): Define.
25627 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
25629 * config/aarch64/aarch64.c: Include cfgrtl.h.
25630 (simd_immediate_info): Add a constructor for series vectors,
25631 and an associated step field.
25632 (aarch64_sve_vg): New variable.
25633 (aarch64_dbx_register_number): Handle VG and the predicate registers.
25634 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
25635 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
25636 (VEC_ANY_DATA, VEC_STRUCT): New constants.
25637 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
25638 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
25639 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
25640 (aarch64_get_mask_mode): New functions.
25641 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
25642 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
25643 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
25644 predicate modes and predicate registers. Explicitly restrict
25645 GPRs to modes of 16 bytes or smaller. Only allow FP registers
25646 to store a vector mode if it is recognized by
25647 aarch64_classify_vector_mode.
25648 (aarch64_regmode_natural_size): New function.
25649 (aarch64_hard_regno_caller_save_mode): Return the original mode
25651 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
25652 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
25653 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
25654 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
25656 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
25657 does not overlap dest if the function is frame-related. Handle
25659 (aarch64_split_add_offset): New function.
25660 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
25661 them aarch64_add_offset.
25662 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
25663 and update call to aarch64_sub_sp.
25664 (aarch64_add_cfa_expression): New function.
25665 (aarch64_expand_prologue): Pass extra temporary registers to the
25666 functions above. Handle the case in which we need to emit new
25667 DW_CFA_expressions for registers that were originally saved
25668 relative to the stack pointer, but now have to be expressed
25669 relative to the frame pointer.
25670 (aarch64_output_mi_thunk): Pass extra temporary registers to the
25672 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
25673 IP0 and IP1 values for SVE frames.
25674 (aarch64_expand_vec_series): New function.
25675 (aarch64_expand_sve_widened_duplicate): Likewise.
25676 (aarch64_expand_sve_const_vector): Likewise.
25677 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
25678 Handle SVE constants. Use emit_move_insn to move a force_const_mem
25679 into the register, rather than emitting a SET directly.
25680 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
25681 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
25682 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
25683 (offset_9bit_signed_scaled_p): New functions.
25684 (aarch64_replicate_bitmask_imm): New function.
25685 (aarch64_bitmask_imm): Use it.
25686 (aarch64_cannot_force_const_mem): Reject expressions involving
25687 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
25688 (aarch64_classify_index): Handle SVE indices, by requiring
25689 a plain register index with a scale that matches the element size.
25690 (aarch64_classify_address): Handle SVE addresses. Assert that
25691 the mode of the address is VOIDmode or an integer mode.
25692 Update call to aarch64_classify_symbol.
25693 (aarch64_classify_symbolic_expression): Update call to
25694 aarch64_classify_symbol.
25695 (aarch64_const_vec_all_in_range_p): New function.
25696 (aarch64_print_vector_float_operand): Likewise.
25697 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
25698 "vN" for FP registers with SVE modes. Handle (const ...) vectors
25699 and the FP immediates 1.0 and 0.5.
25700 (aarch64_print_address_internal): Handle SVE addresses.
25701 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
25702 (aarch64_regno_regclass): Handle predicate registers.
25703 (aarch64_secondary_reload): Handle big-endian reloads of SVE
25705 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
25706 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
25707 (aarch64_convert_sve_vector_bits): New function.
25708 (aarch64_override_options): Use it to handle -msve-vector-bits=.
25709 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
25710 rather than an rtx.
25711 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
25712 Handle SVE vector and predicate modes. Accept VL-based constants
25713 that need only one temporary register, and VL offsets that require
25714 no temporary registers.
25715 (aarch64_conditional_register_usage): Mark the predicate registers
25716 as fixed if SVE isn't available.
25717 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
25718 Return true for SVE vector and predicate modes.
25719 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
25720 rather than an unsigned int. Handle SVE modes.
25721 (aarch64_preferred_simd_mode): Update call accordingly. Handle
25723 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
25725 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
25726 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
25727 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
25728 (aarch64_sve_float_mul_immediate_p): New functions.
25729 (aarch64_sve_valid_immediate): New function.
25730 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
25731 Explicitly reject structure modes. Check for INDEX constants.
25732 Handle PTRUE and PFALSE constants.
25733 (aarch64_check_zero_based_sve_index_immediate): New function.
25734 (aarch64_simd_imm_zero_p): Delete.
25735 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
25736 vector modes. Accept constants in the range of CNT[BHWD].
25737 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
25738 ask for an Advanced SIMD mode.
25739 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
25740 (aarch64_simd_vector_alignment): Handle SVE predicates.
25741 (aarch64_vectorize_preferred_vector_alignment): New function.
25742 (aarch64_simd_vector_alignment_reachable): Use it instead of
25744 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
25745 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
25747 (MAX_VECT_LEN): Delete.
25748 (expand_vec_perm_d): Add a vec_flags field.
25749 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
25750 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
25751 (aarch64_evpc_ext): Don't apply a big-endian lane correction
25753 (aarch64_evpc_rev): Rename to...
25754 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
25755 (aarch64_evpc_rev_global): New function.
25756 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
25757 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
25759 (aarch64_evpc_sve_tbl): New function.
25760 (aarch64_expand_vec_perm_const_1): Update after rename of
25761 aarch64_evpc_rev. Handle SVE permutes too, trying
25762 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
25763 than aarch64_evpc_tbl.
25764 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
25765 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
25766 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
25767 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
25768 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
25769 (aarch64_expand_sve_vcond): New functions.
25770 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
25771 of aarch64_vector_mode_p.
25772 (aarch64_dwarf_poly_indeterminate_value): New function.
25773 (aarch64_compute_pressure_classes): Likewise.
25774 (aarch64_can_change_mode_class): Likewise.
25775 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
25776 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
25777 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
25778 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
25779 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
25780 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
25781 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
25782 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
25784 (Dn, Dl, Dr): Accept const as well as const_vector.
25785 (Dz): Likewise. Compare against CONST0_RTX.
25786 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
25787 of "vector" where appropriate.
25788 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
25789 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
25790 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
25791 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
25792 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
25793 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
25794 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
25795 (v_int_equiv): Extend to SVE modes.
25796 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
25798 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
25799 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
25800 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
25801 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
25802 (SVE_COND_FP_CMP): New int iterators.
25803 (perm_hilo): Handle the new unpack unspecs.
25804 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
25806 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
25807 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
25808 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
25809 (aarch64_equality_operator, aarch64_constant_vector_operand)
25810 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
25811 (aarch64_sve_nonimmediate_operand): Likewise.
25812 (aarch64_sve_general_operand): Likewise.
25813 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
25814 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
25815 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
25816 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
25817 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
25818 (aarch64_sve_float_arith_immediate): Likewise.
25819 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
25820 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
25821 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
25822 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
25823 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
25824 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
25825 (aarch64_sve_float_arith_operand): Likewise.
25826 (aarch64_sve_float_arith_with_sub_operand): Likewise.
25827 (aarch64_sve_float_mul_operand): Likewise.
25828 (aarch64_sve_vec_perm_operand): Likewise.
25829 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
25830 (aarch64_mov_operand): Accept const_poly_int and const_vector.
25831 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
25832 as well as const_vector.
25833 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
25834 in file. Use CONST0_RTX and CONSTM1_RTX.
25835 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
25836 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
25837 Use aarch64_simd_imm_zero.
25838 * config/aarch64/aarch64-sve.md: New file.
25839 * config/aarch64/aarch64.md: Include it.
25840 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
25841 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
25842 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
25843 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
25844 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
25845 (sve): New attribute.
25846 (enabled): Disable instructions with the sve attribute unless
25848 (movqi, movhi): Pass CONST_POLY_INT operaneds through
25849 aarch64_expand_mov_immediate.
25850 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
25851 CNT[BHSD] immediates.
25852 (movti): Split CONST_POLY_INT moves into two halves.
25853 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
25854 Split additions that need a temporary here if the destination
25855 is the stack pointer.
25856 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
25857 (*add<mode>3_poly_1): New instruction.
25858 (set_clobber_cc): New expander.
25860 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25862 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
25863 parameter and use it instead of GET_MODE_SIZE (innermode). Use
25864 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
25865 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
25866 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
25867 Change innermode from fixed_mode_size to machine_mode.
25868 (simplify_subreg): Update call accordingly. Handle a constant-sized
25869 subreg of a variable-length CONST_VECTOR.
25871 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25872 Alan Hayward <alan.hayward@arm.com>
25873 David Sherwood <david.sherwood@arm.com>
25875 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
25876 (add_offset_to_base): New function, split out from...
25877 (create_mem_ref): ...here. When handling a scale other than 1,
25878 check first whether the address is valid without the offset.
25879 Add it into the base if so, leaving the index and scale as-is.
25881 2018-01-12 Jakub Jelinek <jakub@redhat.com>
25884 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
25885 fold_for_warn before checking if arg2 is INTEGER_CST.
25887 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
25889 * config/rs6000/predicates.md (load_multiple_operation): Delete.
25890 (store_multiple_operation): Delete.
25891 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
25892 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
25893 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
25894 guarded by TARGET_STRING.
25895 (rs6000_output_load_multiple): Delete.
25896 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
25897 OPTION_MASK_STRING / TARGET_STRING handling.
25898 (print_operand) <'N', 'O'>: Add comment that these are unused now.
25899 (const rs6000_opt_masks) <"string">: Change mask to 0.
25900 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
25901 (MASK_STRING): Delete.
25902 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
25904 (load_multiple): Delete.
25911 (store_multiple): Delete.
25918 (movmemsi_8reg): Delete.
25919 (corresponding unnamed define_insn): Delete.
25920 (movmemsi_6reg): Delete.
25921 (corresponding unnamed define_insn): Delete.
25922 (movmemsi_4reg): Delete.
25923 (corresponding unnamed define_insn): Delete.
25924 (movmemsi_2reg): Delete.
25925 (corresponding unnamed define_insn): Delete.
25926 (movmemsi_1reg): Delete.
25927 (corresponding unnamed define_insn): Delete.
25928 * config/rs6000/rs6000.opt (mno-string): New.
25929 (mstring): Replace by deprecation warning stub.
25930 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
25932 2018-01-12 Jakub Jelinek <jakub@redhat.com>
25934 * regrename.c (regrename_do_replace): If replacing the same
25935 reg multiple times, try to reuse last created gen_raw_REG.
25938 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
25939 main to workaround a bug in GDB.
25941 2018-01-12 Tom de Vries <tom@codesourcery.com>
25944 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
25946 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
25948 PR rtl-optimization/80481
25949 * ira-color.c (get_cap_member): New function.
25950 (allocnos_conflict_by_live_ranges_p): Use it.
25951 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
25952 (setup_slot_coalesced_allocno_live_ranges): Ditto.
25954 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
25957 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
25958 (*saddl_se_1): Ditto.
25959 (*ssubsi_1): Ditto.
25960 (*ssubl_se_1): Ditto.
25962 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
25964 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
25965 rather than wi::to_widest for DR_INITs.
25966 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
25967 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
25968 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
25970 (vect_analyze_group_access_1): Note that here.
25972 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
25974 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
25975 polynomial type sizes.
25977 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
25979 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
25980 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
25981 (gimple_add_tmp_var): Likewise.
25983 2018-01-12 Martin Liska <mliska@suse.cz>
25985 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
25986 (gimple_alloc_sizes): Likewise.
25987 (dump_gimple_statistics): Use PRIu64 in printf format.
25988 * gimple.h: Change uint64_t to int.
25990 2018-01-12 Martin Liska <mliska@suse.cz>
25992 * tree-core.h: Use uint64_t instead of int.
25993 * tree.c (tree_node_counts): Likewise.
25994 (tree_node_sizes): Likewise.
25995 (dump_tree_statistics): Use PRIu64 in printf format.
25997 2018-01-12 Martin Liska <mliska@suse.cz>
25999 * Makefile.in: As qsort_chk is implemented in vec.c, add
26000 vec.o to linkage of gencfn-macros.
26001 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
26002 passing the info to record_node_allocation_statistics.
26003 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
26005 * ggc-common.c (struct ggc_usage): Add operator== and use
26006 it in operator< and compare function.
26007 * mem-stats.h (struct mem_usage): Likewise.
26008 * vec.c (struct vec_usage): Remove operator< and compare
26009 function. Can be simply inherited.
26011 2018-01-12 Martin Jambor <mjambor@suse.cz>
26014 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
26015 * tree-ssa-math-opts.c: Include domwalk.h.
26016 (convert_mult_to_fma_1): New function.
26017 (fma_transformation_info): New type.
26018 (fma_deferring_state): Likewise.
26019 (cancel_fma_deferring): New function.
26020 (result_of_phi): Likewise.
26021 (last_fma_candidate_feeds_initial_phi): Likewise.
26022 (convert_mult_to_fma): Added deferring logic, split actual
26023 transformation to convert_mult_to_fma_1.
26024 (math_opts_dom_walker): New type.
26025 (math_opts_dom_walker::after_dom_children): New method, body moved
26026 here from pass_optimize_widening_mul::execute, added deferring logic
26028 (pass_optimize_widening_mul::execute): Moved most of code to
26029 math_opts_dom_walker::after_dom_children.
26030 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
26031 * config/i386/i386.c (ix86_option_override_internal): Added
26032 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
26034 2018-01-12 Richard Biener <rguenther@suse.de>
26037 * dwarf2out.c (gen_variable_die): Do not reset old_die for
26038 inline instance vars.
26040 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
26043 * config/rx/rx.c (rx_is_restricted_memory_address):
26044 Handle SUBREG case.
26046 2018-01-12 Richard Biener <rguenther@suse.de>
26048 PR tree-optimization/80846
26049 * target.def (split_reduction): New target hook.
26050 * targhooks.c (default_split_reduction): New function.
26051 * targhooks.h (default_split_reduction): Declare.
26052 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
26053 target requests first reduce vectors by combining low and high
26055 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
26056 (get_vectype_for_scalar_type_and_size): Export.
26057 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
26058 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
26059 * doc/tm.texi: Regenerate.
26060 * config/i386/i386.c (ix86_split_reduction): Implement
26061 TARGET_VECTORIZE_SPLIT_REDUCTION.
26063 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
26066 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
26067 in PIC mode except for TARGET_VXWORKS_RTP.
26068 * config/sparc/sparc.c: Include cfgrtl.h.
26069 (TARGET_INIT_PIC_REG): Define.
26070 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
26071 (sparc_pic_register_p): New predicate.
26072 (sparc_legitimate_address_p): Use it.
26073 (sparc_legitimize_pic_address): Likewise.
26074 (sparc_delegitimize_address): Likewise.
26075 (sparc_mode_dependent_address_p): Likewise.
26076 (gen_load_pcrel_sym): Remove 4th parameter.
26077 (load_got_register): Adjust call to above. Remove obsolete stuff.
26078 (sparc_expand_prologue): Do not call load_got_register here.
26079 (sparc_flat_expand_prologue): Likewise.
26080 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
26081 (sparc_use_pseudo_pic_reg): New function.
26082 (sparc_init_pic_reg): Likewise.
26083 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
26084 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
26086 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
26088 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
26089 Add item for branch_cost.
26091 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
26093 PR rtl-optimization/83565
26094 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
26095 not extend the result to a larger mode for rotate operations.
26096 (num_sign_bit_copies1): Likewise.
26098 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
26101 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
26103 Use values-Xc.o for -pedantic.
26104 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
26106 2018-01-12 Martin Liska <mliska@suse.cz>
26109 * ipa-devirt.c (final_warning_record::grow_type_warnings):
26111 (possible_polymorphic_call_targets): Use it.
26112 (ipa_devirt): Likewise.
26114 2018-01-12 Martin Liska <mliska@suse.cz>
26116 * profile-count.h (enum profile_quality): Use 0 as invalid
26117 enum value of profile_quality.
26119 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
26121 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
26122 -mext-string options.
26124 2018-01-12 Richard Biener <rguenther@suse.de>
26126 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
26127 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
26128 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
26130 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
26132 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
26134 * configure.ac (--with-long-double-format): Add support for the
26135 configuration option to change the default long double format on
26137 * config.gcc (powerpc*-linux*-*): Likewise.
26138 * configure: Regenerate.
26139 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
26140 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
26141 used without modification.
26143 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
26145 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
26146 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
26147 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
26148 MISC_BUILTIN_SPEC_BARRIER.
26149 (rs6000_init_builtins): Likewise.
26150 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
26152 (speculation_barrier): New define_insn.
26153 * doc/extend.texi: Document __builtin_speculation_barrier.
26155 2018-01-11 Jakub Jelinek <jakub@redhat.com>
26158 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
26159 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
26160 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
26162 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
26163 integral modes instead of "ss" and "sd".
26164 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
26165 vectors with 32-bit and 64-bit elements.
26166 (vecdupssescalarmodesuffix): New mode attribute.
26167 (vec_dup<mode>): Use it.
26169 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
26172 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
26173 frame if argument is passed on stack.
26175 2018-01-11 Jakub Jelinek <jakub@redhat.com>
26178 * ree.c (combine_reaching_defs): Optimize also
26179 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
26180 reg2=any_extend(exp); reg1=reg2;, formatting fix.
26182 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
26184 PR middle-end/83189
26185 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
26187 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
26189 PR middle-end/83718
26190 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
26191 after they are computed.
26193 2018-01-11 Bin Cheng <bin.cheng@arm.com>
26195 PR tree-optimization/83695
26196 * gimple-loop-linterchange.cc
26197 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
26198 reset cached scev information after interchange.
26199 (pass_linterchange::execute): Remove call to scev_reset_htab.
26201 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26203 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
26204 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
26205 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
26206 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
26207 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
26208 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
26209 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
26210 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
26211 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
26212 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
26213 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
26214 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
26215 (V_lane_reg): Likewise.
26216 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
26218 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
26219 (vfmal_lane_low<mode>_intrinsic,
26220 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
26221 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
26222 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
26223 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
26224 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
26225 vfmsl_lane_high<mode>_intrinsic): New define_insns.
26227 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26229 * config/arm/arm-cpus.in (fp16fml): New feature.
26230 (ALL_SIMD): Add fp16fml.
26231 (armv8.2-a): Add fp16fml as an option.
26232 (armv8.3-a): Likewise.
26233 (armv8.4-a): Add fp16fml as part of fp16.
26234 * config/arm/arm.h (TARGET_FP16FML): Define.
26235 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
26237 * config/arm/arm-modes.def (V2HF): Define.
26238 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
26239 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
26240 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
26241 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
26242 vfmsl_low, vfmsl_high): New set of builtins.
26243 * config/arm/iterators.md (PLUSMINUS): New code iterator.
26244 (vfml_op): New code attribute.
26245 (VFMLHALVES): New int iterator.
26246 (VFML, VFMLSEL): New mode attributes.
26247 (V_reg): Define mapping for V2HF.
26248 (V_hi, V_lo): New mode attributes.
26249 (VF_constraint): Likewise.
26250 (vfml_half, vfml_half_selector): New int attributes.
26251 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
26253 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
26254 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
26256 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
26257 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
26258 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
26259 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
26261 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
26262 Document new effective target and option set.
26264 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26266 * config/arm/arm-cpus.in (armv8_4): New feature.
26267 (ARMv8_4a): New fgroup.
26268 (armv8.4-a): New arch.
26269 * config/arm/arm-tables.opt: Regenerate.
26270 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
26271 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
26272 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
26273 Add matching rules for -march=armv8.4-a and extensions.
26274 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
26276 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
26279 * config/rx/rx.md (BW): New mode attribute.
26280 (sync_lock_test_and_setsi): Add mode suffix to insn output.
26282 2018-01-11 Richard Biener <rguenther@suse.de>
26284 PR tree-optimization/83435
26285 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
26286 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
26287 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
26289 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26290 Alan Hayward <alan.hayward@arm.com>
26291 David Sherwood <david.sherwood@arm.com>
26293 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
26295 (aarch64_classify_address): Initialize it. Track polynomial offsets.
26296 (aarch64_print_address_internal): Use it to check for a zero offset.
26298 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26299 Alan Hayward <alan.hayward@arm.com>
26300 David Sherwood <david.sherwood@arm.com>
26302 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
26303 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
26304 Return a poly_int64 rather than a HOST_WIDE_INT.
26305 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
26306 rather than a HOST_WIDE_INT.
26307 * config/aarch64/aarch64.h (aarch64_frame): Protect with
26308 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
26309 hard_fp_offset, frame_size, initial_adjust, callee_offset and
26310 final_offset from HOST_WIDE_INT to poly_int64.
26311 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
26312 to_constant when getting the number of units in an Advanced SIMD
26314 (aarch64_builtin_vectorized_function): Check for a constant number
26316 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
26318 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
26319 attribute instead of GET_MODE_NUNITS.
26320 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
26321 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
26322 GET_MODE_SIZE for fixed-size registers.
26323 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
26324 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
26325 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
26326 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
26327 (aarch64_print_operand, aarch64_print_address_internal)
26328 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
26329 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
26330 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
26331 Handle polynomial GET_MODE_SIZE.
26332 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
26333 wider than SImode without modification.
26334 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
26335 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
26336 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
26337 passing and returning SVE modes.
26338 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
26339 rather than GEN_INT.
26340 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
26341 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
26342 (aarch64_allocate_and_probe_stack_space): Likewise.
26343 (aarch64_layout_frame): Cope with polynomial offsets.
26344 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
26345 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
26346 polynomial offsets.
26347 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
26348 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
26349 poly_int64 rather than a HOST_WIDE_INT.
26350 (aarch64_get_separate_components, aarch64_process_components)
26351 (aarch64_expand_prologue, aarch64_expand_epilogue)
26352 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
26353 (aarch64_anchor_offset): New function, split out from...
26354 (aarch64_legitimize_address): ...here.
26355 (aarch64_builtin_vectorization_cost): Handle polynomial
26356 TYPE_VECTOR_SUBPARTS.
26357 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
26359 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
26360 number of elements from the PARALLEL rather than the mode.
26361 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
26362 rather than GET_MODE_BITSIZE.
26363 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
26364 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
26365 (aarch64_expand_vec_perm_const_1): Handle polynomial
26366 d->perm.length () and d->perm elements.
26367 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
26368 Apply to_constant to d->perm elements.
26369 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
26370 polynomial CONST_VECTOR_NUNITS.
26371 (aarch64_move_pointer): Take amount as a poly_int64 rather
26373 (aarch64_progress_pointer): Avoid temporary variable.
26374 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
26375 the mode attribute instead of GET_MODE.
26377 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26378 Alan Hayward <alan.hayward@arm.com>
26379 David Sherwood <david.sherwood@arm.com>
26381 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
26382 x exists before using it.
26383 (aarch64_add_constant_internal): Rename to...
26384 (aarch64_add_offset_1): ...this. Replace regnum with separate
26385 src and dest rtxes. Handle the case in which they're different,
26386 including when the offset is zero. Replace scratchreg with an rtx.
26387 Use 2 additions if there is no spare register into which we can
26388 move a 16-bit constant.
26389 (aarch64_add_constant): Delete.
26390 (aarch64_add_offset): Replace reg with separate src and dest
26391 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
26392 Use aarch64_add_offset_1.
26393 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
26394 an rtx rather than an int. Take the delta as a poly_int64
26395 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
26396 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
26397 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
26398 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
26399 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
26400 and aarch64_add_sp.
26401 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
26402 aarch64_add_constant.
26404 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26406 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
26407 Use scalar_float_mode.
26409 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26411 * config/aarch64/aarch64-simd.md
26412 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
26413 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
26414 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
26415 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
26416 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
26417 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
26418 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
26419 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
26420 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
26421 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
26423 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
26426 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
26427 targ_options->x_arm_arch_string is non NULL.
26429 2018-01-11 Tamar Christina <tamar.christina@arm.com>
26431 * config/aarch64/aarch64.h
26432 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
26434 2018-01-11 Sudakshina Das <sudi.das@arm.com>
26437 * expmed.c (emit_store_flag_force): Swap if const op0
26438 and change VOIDmode to mode of op0.
26440 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
26442 PR rtl-optimization/83761
26443 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
26444 than bytes to mode_for_size.
26446 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
26448 PR middle-end/83189
26449 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
26450 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
26453 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
26455 PR middle-end/83575
26456 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
26457 when in layout mode.
26458 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
26459 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
26462 2018-01-10 Michael Collison <michael.collison@arm.com>
26464 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
26465 * config/aarch64/aarch64-option-extension.def: Add
26466 AARCH64_OPT_EXTENSION of 'fp16fml'.
26467 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
26468 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
26469 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
26470 * config/aarch64/constraints.md (Ui7): New constraint.
26471 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
26472 (VFMLA_SEL_W): Ditto.
26475 (VFMLA16_LOW): New int iterator.
26476 (VFMLA16_HIGH): Ditto.
26477 (UNSPEC_FMLAL): New unspec.
26478 (UNSPEC_FMLSL): Ditto.
26479 (UNSPEC_FMLAL2): Ditto.
26480 (UNSPEC_FMLSL2): Ditto.
26481 (f16mac): New code attribute.
26482 * config/aarch64/aarch64-simd-builtins.def
26483 (aarch64_fmlal_lowv2sf): Ditto.
26484 (aarch64_fmlsl_lowv2sf): Ditto.
26485 (aarch64_fmlalq_lowv4sf): Ditto.
26486 (aarch64_fmlslq_lowv4sf): Ditto.
26487 (aarch64_fmlal_highv2sf): Ditto.
26488 (aarch64_fmlsl_highv2sf): Ditto.
26489 (aarch64_fmlalq_highv4sf): Ditto.
26490 (aarch64_fmlslq_highv4sf): Ditto.
26491 (aarch64_fmlal_lane_lowv2sf): Ditto.
26492 (aarch64_fmlsl_lane_lowv2sf): Ditto.
26493 (aarch64_fmlal_laneq_lowv2sf): Ditto.
26494 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
26495 (aarch64_fmlalq_lane_lowv4sf): Ditto.
26496 (aarch64_fmlsl_lane_lowv4sf): Ditto.
26497 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
26498 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
26499 (aarch64_fmlal_lane_highv2sf): Ditto.
26500 (aarch64_fmlsl_lane_highv2sf): Ditto.
26501 (aarch64_fmlal_laneq_highv2sf): Ditto.
26502 (aarch64_fmlsl_laneq_highv2sf): Ditto.
26503 (aarch64_fmlalq_lane_highv4sf): Ditto.
26504 (aarch64_fmlsl_lane_highv4sf): Ditto.
26505 (aarch64_fmlalq_laneq_highv4sf): Ditto.
26506 (aarch64_fmlsl_laneq_highv4sf): Ditto.
26507 * config/aarch64/aarch64-simd.md:
26508 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
26509 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
26510 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
26511 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
26512 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
26513 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
26514 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
26515 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
26516 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
26517 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
26518 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
26519 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
26520 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
26521 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
26522 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
26523 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
26524 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
26525 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
26526 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
26527 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
26528 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
26529 (vfmlsl_low_u32): Ditto.
26530 (vfmlalq_low_u32): Ditto.
26531 (vfmlslq_low_u32): Ditto.
26532 (vfmlal_high_u32): Ditto.
26533 (vfmlsl_high_u32): Ditto.
26534 (vfmlalq_high_u32): Ditto.
26535 (vfmlslq_high_u32): Ditto.
26536 (vfmlal_lane_low_u32): Ditto.
26537 (vfmlsl_lane_low_u32): Ditto.
26538 (vfmlal_laneq_low_u32): Ditto.
26539 (vfmlsl_laneq_low_u32): Ditto.
26540 (vfmlalq_lane_low_u32): Ditto.
26541 (vfmlslq_lane_low_u32): Ditto.
26542 (vfmlalq_laneq_low_u32): Ditto.
26543 (vfmlslq_laneq_low_u32): Ditto.
26544 (vfmlal_lane_high_u32): Ditto.
26545 (vfmlsl_lane_high_u32): Ditto.
26546 (vfmlal_laneq_high_u32): Ditto.
26547 (vfmlsl_laneq_high_u32): Ditto.
26548 (vfmlalq_lane_high_u32): Ditto.
26549 (vfmlslq_lane_high_u32): Ditto.
26550 (vfmlalq_laneq_high_u32): Ditto.
26551 (vfmlslq_laneq_high_u32): Ditto.
26552 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
26553 (AARCH64_FL_FOR_ARCH8_4): New.
26554 (AARCH64_ISA_F16FML): New ISA flag.
26555 (TARGET_F16FML): New feature flag for fp16fml.
26556 (doc/invoke.texi): Document new fp16fml option.
26558 2018-01-10 Michael Collison <michael.collison@arm.com>
26560 * config/aarch64/aarch64-builtins.c:
26561 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
26562 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
26563 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
26564 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
26565 (AARCH64_ISA_SHA3): New ISA flag.
26566 (TARGET_SHA3): New feature flag for sha3.
26567 * config/aarch64/iterators.md (sha512_op): New int attribute.
26568 (CRYPTO_SHA512): New int iterator.
26569 (UNSPEC_SHA512H): New unspec.
26570 (UNSPEC_SHA512H2): Ditto.
26571 (UNSPEC_SHA512SU0): Ditto.
26572 (UNSPEC_SHA512SU1): Ditto.
26573 * config/aarch64/aarch64-simd-builtins.def
26574 (aarch64_crypto_sha512hqv2di): New builtin.
26575 (aarch64_crypto_sha512h2qv2di): Ditto.
26576 (aarch64_crypto_sha512su0qv2di): Ditto.
26577 (aarch64_crypto_sha512su1qv2di): Ditto.
26578 (aarch64_eor3qv8hi): Ditto.
26579 (aarch64_rax1qv2di): Ditto.
26580 (aarch64_xarqv2di): Ditto.
26581 (aarch64_bcaxqv8hi): Ditto.
26582 * config/aarch64/aarch64-simd.md:
26583 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
26584 (aarch64_crypto_sha512su0qv2di): Ditto.
26585 (aarch64_crypto_sha512su1qv2di): Ditto.
26586 (aarch64_eor3qv8hi): Ditto.
26587 (aarch64_rax1qv2di): Ditto.
26588 (aarch64_xarqv2di): Ditto.
26589 (aarch64_bcaxqv8hi): Ditto.
26590 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
26591 (vsha512h2q_u64): Ditto.
26592 (vsha512su0q_u64): Ditto.
26593 (vsha512su1q_u64): Ditto.
26594 (veor3q_u16): Ditto.
26595 (vrax1q_u64): Ditto.
26596 (vxarq_u64): Ditto.
26597 (vbcaxq_u16): Ditto.
26598 * config/arm/types.md (crypto_sha512): New type attribute.
26599 (crypto_sha3): Ditto.
26600 (doc/invoke.texi): Document new sha3 option.
26602 2018-01-10 Michael Collison <michael.collison@arm.com>
26604 * config/aarch64/aarch64-builtins.c:
26605 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
26606 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
26607 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
26608 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
26609 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
26610 (AARCH64_ISA_SM4): New ISA flag.
26611 (TARGET_SM4): New feature flag for sm4.
26612 * config/aarch64/aarch64-simd-builtins.def
26613 (aarch64_sm3ss1qv4si): Ditto.
26614 (aarch64_sm3tt1aq4si): Ditto.
26615 (aarch64_sm3tt1bq4si): Ditto.
26616 (aarch64_sm3tt2aq4si): Ditto.
26617 (aarch64_sm3tt2bq4si): Ditto.
26618 (aarch64_sm3partw1qv4si): Ditto.
26619 (aarch64_sm3partw2qv4si): Ditto.
26620 (aarch64_sm4eqv4si): Ditto.
26621 (aarch64_sm4ekeyqv4si): Ditto.
26622 * config/aarch64/aarch64-simd.md:
26623 (aarch64_sm3ss1qv4si): Ditto.
26624 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
26625 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
26626 (aarch64_sm4eqv4si): Ditto.
26627 (aarch64_sm4ekeyqv4si): Ditto.
26628 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
26629 (sm3part_op): Ditto.
26630 (CRYPTO_SM3TT): Ditto.
26631 (CRYPTO_SM3PART): Ditto.
26632 (UNSPEC_SM3SS1): New unspec.
26633 (UNSPEC_SM3TT1A): Ditto.
26634 (UNSPEC_SM3TT1B): Ditto.
26635 (UNSPEC_SM3TT2A): Ditto.
26636 (UNSPEC_SM3TT2B): Ditto.
26637 (UNSPEC_SM3PARTW1): Ditto.
26638 (UNSPEC_SM3PARTW2): Ditto.
26639 (UNSPEC_SM4E): Ditto.
26640 (UNSPEC_SM4EKEY): Ditto.
26641 * config/aarch64/constraints.md (Ui2): New constraint.
26642 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
26643 * config/arm/types.md (crypto_sm3): New type attribute.
26644 (crypto_sm4): Ditto.
26645 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
26646 (vsm3tt1aq_u32): Ditto.
26647 (vsm3tt1bq_u32): Ditto.
26648 (vsm3tt2aq_u32): Ditto.
26649 (vsm3tt2bq_u32): Ditto.
26650 (vsm3partw1q_u32): Ditto.
26651 (vsm3partw2q_u32): Ditto.
26652 (vsm4eq_u32): Ditto.
26653 (vsm4ekeyq_u32): Ditto.
26654 (doc/invoke.texi): Document new sm4 option.
26656 2018-01-10 Michael Collison <michael.collison@arm.com>
26658 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
26659 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
26660 (AARCH64_FL_FOR_ARCH8_4): New.
26661 (AARCH64_FL_V8_4): New flag.
26662 (doc/invoke.texi): Document new armv8.4-a option.
26664 2018-01-10 Michael Collison <michael.collison@arm.com>
26666 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
26667 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
26668 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
26669 * config/aarch64/aarch64-option-extension.def: Add
26670 AARCH64_OPT_EXTENSION of 'sha2'.
26671 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
26672 (crypto): Disable sha2 and aes if crypto disabled.
26673 (crypto): Enable aes and sha2 if enabled.
26674 (simd): Disable sha2 and aes if simd disabled.
26675 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
26677 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
26678 (TARGET_SHA2): New feature flag for sha2.
26679 (TARGET_AES): New feature flag for aes.
26680 * config/aarch64/aarch64-simd.md:
26681 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
26682 conditional on TARGET_AES.
26683 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
26684 (aarch64_crypto_sha1hsi): Make pattern conditional
26686 (aarch64_crypto_sha1hv4si): Ditto.
26687 (aarch64_be_crypto_sha1hv4si): Ditto.
26688 (aarch64_crypto_sha1su1v4si): Ditto.
26689 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
26690 (aarch64_crypto_sha1su0v4si): Ditto.
26691 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
26692 (aarch64_crypto_sha256su0v4si): Ditto.
26693 (aarch64_crypto_sha256su1v4si): Ditto.
26694 (doc/invoke.texi): Document new aes and sha2 options.
26696 2018-01-10 Martin Sebor <msebor@redhat.com>
26698 PR tree-optimization/83781
26699 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
26702 2018-01-11 Martin Sebor <msebor@gmail.com>
26703 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
26705 PR tree-optimization/83501
26706 PR tree-optimization/81703
26708 * tree-ssa-strlen.c (get_string_cst): Rename...
26709 (get_string_len): ...to this. Handle global constants.
26710 (handle_char_store): Adjust.
26712 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
26713 Jim Wilson <jimw@sifive.com>
26715 * config/riscv/riscv-protos.h (riscv_output_return): New.
26716 * config/riscv/riscv.c (struct machine_function): New naked_p field.
26717 (riscv_attribute_table, riscv_output_return),
26718 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
26719 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
26720 (riscv_compute_frame_info): Only compute frame->mask if not a naked
26722 (riscv_expand_prologue): Add early return for naked function.
26723 (riscv_expand_epilogue): Likewise.
26724 (riscv_function_ok_for_sibcall): Return false for naked function.
26725 (riscv_set_current_function): New.
26726 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
26727 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
26728 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
26729 * doc/extend.texi (RISC-V Function Attributes): New.
26731 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
26733 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
26734 check for 128-bit long double before checking TCmode.
26735 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
26736 128-bit long doubles before checking TFmode or TCmode.
26737 (FLOAT128_IBM_P): Likewise.
26739 2018-01-10 Martin Sebor <msebor@redhat.com>
26741 PR tree-optimization/83671
26742 * builtins.c (c_strlen): Unconditionally return zero for the empty
26744 Use -Warray-bounds for warnings.
26745 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
26746 for non-constant array indices with COMPONENT_REF, arrays of
26747 arrays, and pointers to arrays.
26748 (gimple_fold_builtin_strlen): Determine and set length range for
26749 non-constant character arrays.
26751 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
26753 PR middle-end/81897
26754 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
26757 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
26759 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
26761 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
26764 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
26765 VECTOR_MEM_ALTIVEC_OR_VSX_P.
26766 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
26767 indexed_or_indirect_operand predicate.
26768 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
26769 (*vsx_le_perm_load_v8hi): Likewise.
26770 (*vsx_le_perm_load_v16qi): Likewise.
26771 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
26772 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
26773 (*vsx_le_perm_store_v8hi): Likewise.
26774 (*vsx_le_perm_store_v16qi): Likewise.
26775 (eight unnamed splitters): Likewise.
26777 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
26779 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
26780 * config/rs6000/emmintrin.h: Likewise.
26781 * config/rs6000/mmintrin.h: Likewise.
26782 * config/rs6000/xmmintrin.h: Likewise.
26784 2018-01-10 David Malcolm <dmalcolm@redhat.com>
26787 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
26789 * tree.c (tree_nop_conversion): Return true for location wrapper
26791 (maybe_wrap_with_location): New function.
26792 (selftest::check_strip_nops): New function.
26793 (selftest::test_location_wrappers): New function.
26794 (selftest::tree_c_tests): Call it.
26795 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
26796 (maybe_wrap_with_location): New decl.
26797 (EXPR_LOCATION_WRAPPER_P): New macro.
26798 (location_wrapper_p): New inline function.
26799 (tree_strip_any_location_wrapper): New inline function.
26801 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
26804 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
26805 stack_realign_offset for the largest alignment of stack slot
26807 (ix86_find_max_used_stack_alignment): New function.
26808 (ix86_finalize_stack_frame_flags): Use it. Set
26809 max_used_stack_alignment if we don't realign stack.
26810 * config/i386/i386.h (machine_function): Add
26811 max_used_stack_alignment.
26813 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
26815 * config/arm/arm.opt (-mbranch-cost): New option.
26816 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
26819 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
26822 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
26823 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
26825 2018-01-10 Richard Biener <rguenther@suse.de>
26828 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
26829 early out so it also covers the case where we have a non-NULL
26832 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
26834 PR tree-optimization/83753
26835 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
26836 for non-strided grouped accesses if the number of elements is 1.
26838 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
26841 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
26842 * i386.h (TARGET_USE_GATHER): Define.
26843 * x86-tune.def (X86_TUNE_USE_GATHER): New.
26845 2018-01-10 Martin Liska <mliska@suse.cz>
26848 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
26849 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
26851 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
26852 CLEANUP_NO_PARTITIONING is not set.
26854 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
26856 * doc/rtl.texi: Remove documentation of (const ...) wrappers
26857 for vectors, as a partial revert of r254296.
26858 * rtl.h (const_vec_p): Delete.
26859 (const_vec_duplicate_p): Don't test for vector CONSTs.
26860 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
26861 * expmed.c (make_tree): Likewise.
26864 * common.md (E, F): Use CONSTANT_P instead of checking for
26866 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
26867 checking for CONST_VECTOR.
26869 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
26871 PR middle-end/83575
26872 * predict.c (force_edge_cold): Handle in more sane way edges
26873 with no prediction.
26875 2018-01-09 Carl Love <cel@us.ibm.com>
26877 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
26879 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
26880 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
26881 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
26882 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
26883 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
26884 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
26885 * config/rs6000/rs6000-protos.h: Add extern defition for
26886 rs6000_generate_float2_double_code.
26887 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
26889 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
26890 (float2_v2df): Add define_expand.
26892 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
26895 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
26896 op_mode in the force_to_mode call.
26898 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
26900 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
26901 instead of checking each element individually.
26902 (aarch64_evpc_uzp): Likewise.
26903 (aarch64_evpc_zip): Likewise.
26904 (aarch64_evpc_ext): Likewise.
26905 (aarch64_evpc_rev): Likewise.
26906 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
26907 instead of checking each element individually. Return true without
26909 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
26910 whether all selected elements come from the same input, instead of
26911 checking each element individually. Remove calls to gen_rtx_REG,
26912 start_sequence and end_sequence and instead assert that no rtl is
26915 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
26917 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
26918 order of HIGH and CONST checks.
26920 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
26922 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
26923 if the destination isn't an SSA_NAME.
26925 2018-01-09 Richard Biener <rguenther@suse.de>
26927 PR tree-optimization/83668
26928 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
26930 (canonicalize_loop_form): ... here, renamed from ...
26931 (canonicalize_loop_closed_ssa_form): ... this and amended to
26932 swap successor edges for loop exit blocks to make us use
26933 the RPO order we need for initial schedule generation.
26935 2018-01-09 Joseph Myers <joseph@codesourcery.com>
26937 PR tree-optimization/64811
26938 * match.pd: When optimizing comparisons with Inf, avoid
26939 introducing or losing exceptions from comparisons with NaN.
26941 2018-01-09 Martin Liska <mliska@suse.cz>
26944 * asan.c (shadow_mem_size): Add gcc_assert.
26946 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
26948 Don't save registers in main().
26951 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
26952 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
26953 * config/avr/avr.c (avr_set_current_function): Don't error if
26954 naked, OS_task or OS_main are specified at the same time.
26955 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
26957 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
26959 * common/config/avr/avr-common.c (avr_option_optimization_table):
26960 Switch on -mmain-is-OS_task for optimizing compilations.
26962 2018-01-09 Richard Biener <rguenther@suse.de>
26964 PR tree-optimization/83572
26965 * graphite.c: Include cfganal.h.
26966 (graphite_transform_loops): Connect infinite loops to exit
26967 and remove fake edges at the end.
26969 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
26971 * ipa-inline.c (edge_badness): Revert accidental checkin.
26973 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
26976 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
26977 symbols; not inline clones.
26979 2018-01-09 Jakub Jelinek <jakub@redhat.com>
26982 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
26983 hard registers. Formatting fixes.
26985 PR preprocessor/83722
26986 * gcc.c (try_generate_repro): Pass
26987 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
26988 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
26991 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
26992 Kito Cheng <kito.cheng@gmail.com>
26994 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
26995 (riscv_leaf_function_p): Delete.
26996 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
26998 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
27000 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
27002 (do_ifelse): New function.
27003 (do_isel): New function.
27004 (do_sub3): New function.
27005 (do_add3): New function.
27006 (do_load_mask_compare): New function.
27007 (do_overlap_load_compare): New function.
27008 (expand_compare_loop): New function.
27009 (expand_block_compare): Call expand_compare_loop() when appropriate.
27010 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
27011 option description.
27012 (-mblock-compare-inline-loop-limit): New option.
27014 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27017 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
27018 Reverse order of second and third operands in first alternative.
27019 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
27020 of first and second elements in UNSPEC_VPERMR vector.
27021 (altivec_expand_vec_perm_le): Likewise.
27023 2018-01-08 Jeff Law <law@redhat.com>
27025 PR rtl-optimizatin/81308
27026 * tree-switch-conversion.c (cfg_altered): New file scoped static.
27027 (process_switch): If group_case_labels makes a change, then set
27029 (pass_convert_switch::execute): If a switch is converted, then
27030 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
27032 PR rtl-optimization/81308
27033 * recog.c (split_all_insns): Conditionally cleanup the CFG after
27036 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
27038 PR target/83663 - Revert r255946
27039 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
27040 generation for cases where splatting a value is not useful.
27041 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
27042 across a vec_duplicate and a paradoxical subreg forming a vector
27043 mode to a vec_concat.
27045 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27047 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
27048 -march=armv8.3-a variants.
27049 * config/arm/t-multilib: Likewise.
27050 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
27052 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
27054 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
27056 (cceq_ior_compare_complement): Give it a name so I can use it, and
27057 change boolean_or_operator predicate to boolean_operator so it can
27058 be used to generate a crand.
27059 (eqne): New code iterator.
27060 (bd/bd_neg): New code_attrs.
27061 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
27062 a single define_insn.
27063 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
27064 decrement (bdnzt/bdnzf/bdzt/bdzf).
27065 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
27066 with the new names of the branch decrement patterns, and added the
27067 names of the branch decrement conditional patterns.
27069 2018-01-08 Richard Biener <rguenther@suse.de>
27071 PR tree-optimization/83563
27072 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
27075 2018-01-08 Richard Biener <rguenther@suse.de>
27077 PR middle-end/83713
27078 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
27080 2018-01-08 Richard Biener <rguenther@suse.de>
27082 PR tree-optimization/83685
27083 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
27084 references to abnormals.
27086 2018-01-08 Richard Biener <rguenther@suse.de>
27089 * dwarf2out.c (output_indirect_strings): Handle empty
27090 skeleton_debug_str_hash.
27091 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
27093 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
27095 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
27096 (emit_store_direct): Likewise.
27097 (arc_trampoline_adjust_address): Likewise.
27098 (arc_asm_trampoline_template): New function.
27099 (arc_initialize_trampoline): Use asm_trampoline_template.
27100 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
27101 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
27102 * config/arc/arc.md (flush_icache): Delete pattern.
27104 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
27106 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
27107 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
27110 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
27113 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
27114 by not USED_FOR_TARGET.
27115 (make_pass_resolve_sw_modes): Likewise.
27117 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
27119 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
27122 2018-01-08 Richard Biener <rguenther@suse.de>
27124 PR middle-end/83580
27125 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
27127 2018-01-08 Richard Biener <rguenther@suse.de>
27129 PR middle-end/83517
27130 * match.pd ((t * 2) / 2) -> t): Add missing :c.
27132 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
27134 PR middle-end/81897
27135 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
27136 basic blocks with a small number of successors.
27137 (convert_control_dep_chain_into_preds): Improve handling of
27139 (dump_predicates): Split apart into...
27140 (dump_pred_chain): ...here...
27141 (dump_pred_info): ...and here.
27142 (can_one_predicate_be_invalidated_p): Add debugging printfs.
27143 (can_chain_union_be_invalidated_p): Improve check for invalidation
27145 (uninit_uses_cannot_happen): Avoid unnecessary if
27146 convert_control_dep_chain_into_preds yielded nothing.
27148 2018-01-06 Martin Sebor <msebor@redhat.com>
27150 PR tree-optimization/83640
27151 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
27152 subtracting negative offset from size.
27153 (builtin_access::overlap): Adjust offset bounds of the access to fall
27154 within the size of the object if possible.
27156 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
27158 PR rtl-optimization/83699
27159 * expmed.c (extract_bit_field_1): Restrict the vector usage of
27160 extract_bit_field_as_subreg to cases in which the extracted
27161 value is also a vector.
27163 * lra-constraints.c (process_alt_operands): Test for the equivalence
27164 substitutions when detecting a possible reload cycle.
27166 2018-01-06 Jakub Jelinek <jakub@redhat.com>
27169 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
27170 by default if flag_selective_schedling{,2}. Formatting fixes.
27172 PR rtl-optimization/83682
27173 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
27174 if it has non-VECTOR_MODE element mode.
27175 (vec_duplicate_p): Likewise.
27177 PR middle-end/83694
27178 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
27179 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
27181 2018-01-05 Jakub Jelinek <jakub@redhat.com>
27184 * config/i386/i386-builtin.def
27185 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
27186 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
27187 Require also OPTION_MASK_ISA_AVX512F in addition to
27188 OPTION_MASK_ISA_GFNI.
27189 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
27190 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
27191 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
27192 to OPTION_MASK_ISA_GFNI.
27193 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
27194 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
27195 OPTION_MASK_ISA_AVX512BW.
27196 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
27197 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
27198 addition to OPTION_MASK_ISA_GFNI.
27199 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
27200 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
27201 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
27202 to OPTION_MASK_ISA_GFNI.
27203 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
27204 a requirement for all ISAs rather than any of them with a few
27206 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
27208 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
27209 bitmasks to be enabled with 3 exceptions, instead of requiring any
27210 enabled ISA with lots of exceptions.
27211 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
27212 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
27213 Change avx512bw in isa attribute to avx512f.
27214 * config/i386/sgxintrin.h: Add license boilerplate.
27215 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
27216 to __AVX512F__ and __AVX512VL to __AVX512VL__.
27217 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
27218 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
27220 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
27221 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
27222 temporarily sse2 rather than sse if not enabled already.
27225 * config/i386/sse.md (VI248_VLBW): Rename to ...
27226 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
27227 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
27228 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
27229 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
27230 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
27231 mode iterator instead of VI248_VLBW.
27233 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
27235 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
27236 (record_modified): Skip clobbers; add debug output.
27237 (param_change_prob): Use sreal frequencies.
27239 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
27241 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
27242 punt for user-aligned variables.
27244 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
27246 * tree-chrec.c (chrec_contains_symbols): Return true for
27249 2018-01-05 Sudakshina Das <sudi.das@arm.com>
27252 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
27253 of (x|y) == x for BICS pattern.
27255 2018-01-05 Jakub Jelinek <jakub@redhat.com>
27257 PR tree-optimization/83605
27258 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
27259 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
27262 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
27264 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
27265 * config/epiphany/rtems.h: New file.
27267 2018-01-04 Jakub Jelinek <jakub@redhat.com>
27268 Uros Bizjak <ubizjak@gmail.com>
27271 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
27272 QIreg_operand instead of register_operand predicate.
27273 * config/i386/i386.c (ix86_rop_should_change_byte_p,
27274 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
27275 comments instead of -fmitigate[-_]rop.
27277 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
27280 * cgraphunit.c (symbol_table::compile): Switch to text_section
27281 before calling assembly_start debug hook.
27282 * run-rtl-passes.c (run_rtl_passes): Likewise.
27285 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27287 * tree-vrp.c (extract_range_from_binary_expr_1): Check
27288 range_int_cst_p rather than !symbolic_range_p before calling
27289 extract_range_from_multiplicative_op_1.
27291 2018-01-04 Jeff Law <law@redhat.com>
27293 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
27294 redundant test in assertion.
27296 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27298 * doc/rtl.texi: Document machine_mode wrapper classes.
27300 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27302 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
27303 using tree_to_uhwi.
27305 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27307 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
27308 the VEC_PERM_EXPR fold to fail.
27310 2018-01-04 Jakub Jelinek <jakub@redhat.com>
27313 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
27314 to switched_sections.
27316 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27319 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
27320 test for d.testing.
27322 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
27325 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
27326 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
27328 2018-01-04 Jakub Jelinek <jakub@redhat.com>
27331 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
27332 is BLKmode and bitpos not zero or mode change is needed.
27334 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
27337 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
27340 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
27343 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
27344 instead of MULT rtx. Update all corresponding splitters.
27345 (*saddl_se): Ditto.
27346 (*ssub<modesuffix>): Ditto.
27347 (*ssubl_se): Ditto.
27348 (*cmp_sadd_di): Update split patterns.
27349 (*cmp_sadd_si): Ditto.
27350 (*cmp_sadd_sidi): Ditto.
27351 (*cmp_ssub_di): Ditto.
27352 (*cmp_ssub_si): Ditto.
27353 (*cmp_ssub_sidi): Ditto.
27354 * config/alpha/predicates.md (const23_operand): New predicate.
27355 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
27356 Look for ASHIFT, not MULT inner operand.
27357 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
27359 2018-01-04 Martin Liska <mliska@suse.cz>
27361 PR gcov-profile/83669
27362 * gcov.c (output_intermediate_file): Add version to intermediate
27364 * doc/gcov.texi: Document new field 'version' in intermediate
27365 file format. Fix location of '-k' option of gcov command.
27367 2018-01-04 Martin Liska <mliska@suse.cz>
27370 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
27372 2018-01-04 Jakub Jelinek <jakub@redhat.com>
27374 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
27376 2018-01-03 Martin Sebor <msebor@redhat.com>
27378 PR tree-optimization/83655
27379 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
27380 checking calls with invalid arguments.
27382 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27384 * tree-vect-stmts.c (vect_get_store_rhs): New function.
27385 (vectorizable_mask_load_store): Delete.
27386 (vectorizable_call): Return false for masked loads and stores.
27387 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
27388 instead of gimple_assign_rhs1.
27389 (vectorizable_load): Handle IFN_MASK_LOAD.
27390 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
27392 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27394 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
27396 (vectorizable_mask_load_store): ...here.
27397 (vectorizable_load): ...and here.
27399 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27401 * tree-vect-stmts.c (vect_build_all_ones_mask)
27402 (vect_build_zero_merge_argument): New functions, split out from...
27403 (vectorizable_load): ...here.
27405 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27407 * tree-vect-stmts.c (vect_check_store_rhs): New function,
27409 (vectorizable_mask_load_store): ...here.
27410 (vectorizable_store): ...and here.
27412 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27414 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
27416 (vectorizable_mask_load_store): ...here.
27418 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27420 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
27421 (vect_model_store_cost): Take a vec_load_store_type instead of a
27423 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
27424 (vect_model_store_cost): Take a vec_load_store_type instead of a
27426 (vectorizable_mask_load_store): Update accordingly.
27427 (vectorizable_store): Likewise.
27428 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
27430 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27432 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
27433 IFN_MASK_LOAD calls here rather than...
27434 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
27436 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27437 Alan Hayward <alan.hayward@arm.com>
27438 David Sherwood <david.sherwood@arm.com>
27440 * expmed.c (extract_bit_field_1): For vector extracts,
27441 fall back to extract_bit_field_as_subreg if vec_extract
27444 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27445 Alan Hayward <alan.hayward@arm.com>
27446 David Sherwood <david.sherwood@arm.com>
27448 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
27449 they are variable or constant sized.
27450 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
27451 slots for constant-sized data.
27453 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27454 Alan Hayward <alan.hayward@arm.com>
27455 David Sherwood <david.sherwood@arm.com>
27457 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
27458 handling COND_EXPRs with boolean comparisons, try to find a better
27459 basis for the mask type than the boolean itself.
27461 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27463 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
27464 is calculated and how it can be overridden.
27465 * genmodes.c (max_bitsize_mode_any_mode): New variable.
27466 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
27468 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
27471 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27472 Alan Hayward <alan.hayward@arm.com>
27473 David Sherwood <david.sherwood@arm.com>
27475 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
27476 Remove the mode argument.
27477 (aarch64_simd_valid_immediate): Remove the mode and inverse
27479 * config/aarch64/iterators.md (bitsize): New iterator.
27480 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
27481 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
27482 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
27483 aarch64_simd_valid_immediate.
27484 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
27485 (aarch64_reg_or_bic_imm): Likewise.
27486 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
27487 with an insn_type enum and msl with a modifier_type enum.
27488 Replace element_width with a scalar_mode. Change the shift
27489 to unsigned int. Add constructors for scalar_float_mode and
27490 scalar_int_mode elements.
27491 (aarch64_vect_float_const_representable_p): Delete.
27492 (aarch64_can_const_movi_rtx_p)
27493 (aarch64_simd_scalar_immediate_valid_for_move)
27494 (aarch64_simd_make_constant): Update call to
27495 aarch64_simd_valid_immediate.
27496 (aarch64_advsimd_valid_immediate_hs): New function.
27497 (aarch64_advsimd_valid_immediate): Likewise.
27498 (aarch64_simd_valid_immediate): Remove mode and inverse
27499 arguments. Rewrite to use the above. Use const_vec_duplicate_p
27500 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
27501 and aarch64_float_const_representable_p on the result.
27502 (aarch64_output_simd_mov_immediate): Remove mode argument.
27503 Update call to aarch64_simd_valid_immediate and use of
27504 simd_immediate_info.
27505 (aarch64_output_scalar_simd_mov_immediate): Update call
27508 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27509 Alan Hayward <alan.hayward@arm.com>
27510 David Sherwood <david.sherwood@arm.com>
27512 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
27513 (mode_nunits): Likewise CONST_MODE_NUNITS.
27514 * machmode.def (ADJUST_NUNITS): Document.
27515 * genmodes.c (mode_data::need_nunits_adj): New field.
27516 (blank_mode): Update accordingly.
27517 (adj_nunits): New variable.
27518 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
27520 (emit_mode_size_inline): Set need_bytesize_adj for all modes
27521 listed in adj_nunits.
27522 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
27523 listed in adj_nunits. Don't emit case statements for such modes.
27524 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
27525 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
27526 nothing if adj_nunits is nonnull.
27527 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
27528 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
27529 (emit_mode_fbit): Update use of print_maybe_const_decl.
27530 (emit_move_size): Likewise. Treat the array as non-const
27532 (emit_mode_adjustments): Handle adj_nunits.
27534 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27536 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
27537 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
27538 (VECTOR_MODES): Use it.
27539 (make_vector_modes): Take the prefix as an argument.
27541 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27542 Alan Hayward <alan.hayward@arm.com>
27543 David Sherwood <david.sherwood@arm.com>
27545 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
27546 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
27547 for MODE_VECTOR_BOOL.
27548 * machmode.def (VECTOR_BOOL_MODE): Document.
27549 * genmodes.c (VECTOR_BOOL_MODE): New macro.
27550 (make_vector_bool_mode): New function.
27551 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
27553 * lto-streamer-in.c (lto_input_mode_table): Likewise.
27554 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
27556 * stor-layout.c (int_mode_for_mode): Likewise.
27557 * tree.c (build_vector_type_for_mode): Likewise.
27558 * varasm.c (output_constant_pool_2): Likewise.
27559 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
27560 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
27561 for MODE_VECTOR_BOOL.
27562 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
27563 of mode class checks.
27564 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
27565 instead of a list of mode class checks.
27566 (expand_vector_scalar_condition): Likewise.
27567 (type_for_widest_vector_mode): Handle BImode as an inner mode.
27569 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27570 Alan Hayward <alan.hayward@arm.com>
27571 David Sherwood <david.sherwood@arm.com>
27573 * machmode.h (mode_size): Change from unsigned short to
27575 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
27576 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
27577 or if measurement_type is not polynomial.
27578 (fixed_size_mode::includes_p): Check for constant-sized modes.
27579 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
27580 return a poly_uint16 rather than an unsigned short.
27581 (emit_mode_size): Change the type of mode_size from unsigned short
27582 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
27583 (emit_mode_adjustments): Cope with polynomial vector sizes.
27584 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
27586 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
27588 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
27589 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
27590 * caller-save.c (setup_save_areas): Likewise.
27591 (replace_reg_with_saved_mem): Likewise.
27592 * calls.c (emit_library_call_value_1): Likewise.
27593 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
27594 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
27595 (gen_lowpart_for_combine): Likewise.
27596 * convert.c (convert_to_integer_1): Likewise.
27597 * cse.c (equiv_constant, cse_insn): Likewise.
27598 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
27599 (cselib_subst_to_values): Likewise.
27600 * dce.c (word_dce_process_block): Likewise.
27601 * df-problems.c (df_word_lr_mark_ref): Likewise.
27602 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
27603 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
27604 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
27605 (rtl_for_decl_location): Likewise.
27606 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
27607 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
27608 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
27609 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
27610 (expand_expr_real_1): Likewise.
27611 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
27612 (pad_below): Likewise.
27613 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
27614 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
27615 * ira.c (get_subreg_tracking_sizes): Likewise.
27616 * ira-build.c (ira_create_allocno_objects): Likewise.
27617 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
27618 (ira_sort_regnos_for_alter_reg): Likewise.
27619 * ira-costs.c (record_operand_costs): Likewise.
27620 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
27621 (resolve_simple_move): Likewise.
27622 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
27623 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
27624 (lra_constraints): Likewise.
27625 (CONST_POOL_OK_P): Reject variable-sized modes.
27626 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
27627 (add_pseudo_to_slot, lra_spill): Likewise.
27628 * omp-low.c (omp_clause_aligned_alignment): Likewise.
27629 * optabs-query.c (get_best_extraction_insn): Likewise.
27630 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
27631 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
27632 (expand_mult_highpart, valid_multiword_target_p): Likewise.
27633 * recog.c (offsettable_address_addr_space_p): Likewise.
27634 * regcprop.c (maybe_mode_change): Likewise.
27635 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
27636 * regrename.c (build_def_use): Likewise.
27637 * regstat.c (dump_reg_info): Likewise.
27638 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
27639 (find_reloads, find_reloads_subreg_address): Likewise.
27640 * reload1.c (eliminate_regs_1): Likewise.
27641 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
27642 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
27643 (simplify_binary_operation_1, simplify_subreg): Likewise.
27644 * targhooks.c (default_function_arg_padding): Likewise.
27645 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
27646 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
27647 (verify_gimple_assign_ternary): Likewise.
27648 * tree-inline.c (estimate_move_cost): Likewise.
27649 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
27650 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
27651 (get_address_cost_ainc): Likewise.
27652 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
27653 (vect_supportable_dr_alignment): Likewise.
27654 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
27655 (vectorizable_reduction): Likewise.
27656 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
27657 (vectorizable_operation, vectorizable_load): Likewise.
27658 * tree.c (build_same_sized_truth_vector_type): Likewise.
27659 * valtrack.c (cleanup_auto_inc_dec): Likewise.
27660 * var-tracking.c (emit_note_insn_var_location): Likewise.
27661 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
27662 (ADDR_VEC_ALIGN): Likewise.
27664 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27665 Alan Hayward <alan.hayward@arm.com>
27666 David Sherwood <david.sherwood@arm.com>
27668 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
27670 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
27671 or if measurement_type is polynomial.
27672 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
27673 * combine.c (make_extraction): Likewise.
27674 * dse.c (find_shift_sequence): Likewise.
27675 * dwarf2out.c (mem_loc_descriptor): Likewise.
27676 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
27677 (extract_bit_field, extract_low_bits): Likewise.
27678 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
27679 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
27680 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
27681 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
27682 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
27683 * reload.c (find_reloads): Likewise.
27684 * reload1.c (alter_reg): Likewise.
27685 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
27686 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
27687 * tree-if-conv.c (predicate_mem_writes): Likewise.
27688 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
27689 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
27690 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
27691 * valtrack.c (dead_debug_insert_temp): Likewise.
27692 * varasm.c (mergeable_constant_section): Likewise.
27693 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
27695 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27696 Alan Hayward <alan.hayward@arm.com>
27697 David Sherwood <david.sherwood@arm.com>
27699 * expr.c (expand_assignment): Cope with polynomial mode sizes
27700 when assigning to a CONCAT.
27702 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27703 Alan Hayward <alan.hayward@arm.com>
27704 David Sherwood <david.sherwood@arm.com>
27706 * machmode.h (mode_precision): Change from unsigned short to
27708 (mode_to_precision): Return a poly_uint16 rather than an unsigned
27710 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
27711 or if measurement_type is not polynomial.
27712 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
27713 in which the mode is already known to be a scalar_int_mode.
27714 * genmodes.c (emit_mode_precision): Change the type of mode_precision
27715 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
27717 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
27718 for GET_MODE_PRECISION.
27719 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
27720 for GET_MODE_PRECISION.
27721 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
27723 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
27724 (expand_field_assignment, make_extraction): Likewise.
27725 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
27726 (get_last_value): Likewise.
27727 * convert.c (convert_to_integer_1): Likewise.
27728 * cse.c (cse_insn): Likewise.
27729 * expr.c (expand_expr_real_1): Likewise.
27730 * lra-constraints.c (simplify_operand_subreg): Likewise.
27731 * optabs-query.c (can_atomic_load_p): Likewise.
27732 * optabs.c (expand_atomic_load): Likewise.
27733 (expand_atomic_store): Likewise.
27734 * ree.c (combine_reaching_defs): Likewise.
27735 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
27736 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
27737 * tree.h (type_has_mode_precision_p): Likewise.
27738 * ubsan.c (instrument_si_overflow): Likewise.
27740 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27741 Alan Hayward <alan.hayward@arm.com>
27742 David Sherwood <david.sherwood@arm.com>
27744 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
27745 polynomial numbers of units.
27746 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
27747 (valid_vector_subparts_p): New function.
27748 (build_vector_type): Remove temporary shim and take the number
27749 of units as a poly_uint64 rather than an int.
27750 (build_opaque_vector_type): Take the number of units as a
27751 poly_uint64 rather than an int.
27752 * tree.c (build_vector_from_ctor): Handle polynomial
27753 TYPE_VECTOR_SUBPARTS.
27754 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
27755 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
27756 (build_vector_from_val): If the number of units is variable,
27757 use build_vec_duplicate_cst for constant operands and
27758 VEC_DUPLICATE_EXPR otherwise.
27759 (make_vector_type): Remove temporary is_constant ().
27760 (build_vector_type, build_opaque_vector_type): Take the number of
27761 units as a poly_uint64 rather than an int.
27762 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
27764 * cfgexpand.c (expand_debug_expr): Likewise.
27765 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
27766 (store_constructor, expand_expr_real_1): Likewise.
27767 (const_scalar_mask_from_tree): Likewise.
27768 * fold-const-call.c (fold_const_reduction): Likewise.
27769 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
27770 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
27771 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
27772 (fold_relational_const): Likewise.
27773 (native_interpret_vector): Likewise. Change the size from an
27774 int to an unsigned int.
27775 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
27776 TYPE_VECTOR_SUBPARTS.
27777 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
27778 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
27779 duplicating a non-constant operand into a variable-length vector.
27780 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
27781 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
27782 * ipa-icf.c (sem_variable::equals): Likewise.
27783 * match.pd: Likewise.
27784 * omp-simd-clone.c (simd_clone_subparts): Likewise.
27785 * print-tree.c (print_node): Likewise.
27786 * stor-layout.c (layout_type): Likewise.
27787 * targhooks.c (default_builtin_vectorization_cost): Likewise.
27788 * tree-cfg.c (verify_gimple_comparison): Likewise.
27789 (verify_gimple_assign_binary): Likewise.
27790 (verify_gimple_assign_ternary): Likewise.
27791 (verify_gimple_assign_single): Likewise.
27792 * tree-pretty-print.c (dump_generic_node): Likewise.
27793 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
27794 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
27795 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
27796 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
27797 (vect_shift_permute_load_chain): Likewise.
27798 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
27799 (expand_vector_condition, optimize_vector_constructor): Likewise.
27800 (lower_vec_perm, get_compute_type): Likewise.
27801 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
27802 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
27803 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
27804 (vect_recog_mask_conversion_pattern): Likewise.
27805 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
27806 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
27807 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
27808 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
27809 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
27810 (vectorizable_shift, vectorizable_operation, vectorizable_store)
27811 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
27812 (supportable_widening_operation): Likewise.
27813 (supportable_narrowing_operation): Likewise.
27814 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
27816 * varasm.c (output_constant): Likewise.
27818 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27819 Alan Hayward <alan.hayward@arm.com>
27820 David Sherwood <david.sherwood@arm.com>
27822 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
27823 so that both the length == 3 and length != 3 cases set up their
27824 own permute vectors. Add comments explaining why we know the
27825 number of elements is constant.
27826 (vect_permute_load_chain): Likewise.
27828 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27829 Alan Hayward <alan.hayward@arm.com>
27830 David Sherwood <david.sherwood@arm.com>
27832 * machmode.h (mode_nunits): Change from unsigned char to
27834 (ONLY_FIXED_SIZE_MODES): New macro.
27835 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
27836 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
27837 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
27839 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
27840 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
27841 or if measurement_type is not polynomial.
27842 * genmodes.c (ZERO_COEFFS): New macro.
27843 (emit_mode_nunits_inline): Make mode_nunits_inline return a
27845 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
27846 Use ZERO_COEFFS when emitting initializers.
27847 * data-streamer.h (bp_pack_poly_value): New function.
27848 (bp_unpack_poly_value): Likewise.
27849 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
27850 for GET_MODE_NUNITS.
27851 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
27852 for GET_MODE_NUNITS.
27853 * tree.c (make_vector_type): Remove temporary shim and make
27854 the real function take the number of units as a poly_uint64
27855 rather than an int.
27856 (build_vector_type_for_mode): Handle polynomial nunits.
27857 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
27858 * emit-rtl.c (const_vec_series_p_1): Likewise.
27859 (gen_rtx_CONST_VECTOR): Likewise.
27860 * fold-const.c (test_vec_duplicate_folding): Likewise.
27861 * genrecog.c (validate_pattern): Likewise.
27862 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
27863 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
27864 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
27865 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
27866 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
27867 * rtlanal.c (subreg_get_info): Likewise.
27868 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
27869 (vect_grouped_load_supported): Likewise.
27870 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
27871 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
27872 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
27873 (simplify_const_unary_operation, simplify_binary_operation_1)
27874 (simplify_const_binary_operation, simplify_ternary_operation)
27875 (test_vector_ops_duplicate, test_vector_ops): Likewise.
27876 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
27877 instead of CONST_VECTOR_NUNITS.
27878 * varasm.c (output_constant_pool_2): Likewise.
27879 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
27880 explicit-encoded elements in the XVEC for variable-length vectors.
27882 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27884 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
27886 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27887 Alan Hayward <alan.hayward@arm.com>
27888 David Sherwood <david.sherwood@arm.com>
27890 * coretypes.h (fixed_size_mode): Declare.
27891 (fixed_size_mode_pod): New typedef.
27892 * builtins.h (target_builtins::x_apply_args_mode)
27893 (target_builtins::x_apply_result_mode): Change type to
27894 fixed_size_mode_pod.
27895 * builtins.c (apply_args_size, apply_result_size, result_vector)
27896 (expand_builtin_apply_args_1, expand_builtin_apply)
27897 (expand_builtin_return): Update accordingly.
27899 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
27901 * cse.c (hash_rtx_cb): Hash only the encoded elements.
27902 * cselib.c (cselib_hash_rtx): Likewise.
27903 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
27904 CONST_VECTOR encoding.
27906 2018-01-03 Jakub Jelinek <jakub@redhat.com>
27907 Jeff Law <law@redhat.com>
27910 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
27911 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
27912 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
27913 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
27916 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
27917 explicitly probe *sp in a noreturn function if there were any callee
27918 register saves or frame pointer is needed.
27920 2018-01-03 Jakub Jelinek <jakub@redhat.com>
27923 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
27924 BLKmode for ternary, binary or unary expressions.
27927 * var-tracking.c (delete_vta_debug_insn): New inline function.
27928 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
27929 insns from get_insns () to NULL instead of each bb separately.
27930 Use delete_vta_debug_insn. No longer static.
27931 (vt_debug_insns_local, variable_tracking_main_1): Adjust
27932 delete_vta_debug_insns callers.
27933 * rtl.h (delete_vta_debug_insns): Declare.
27934 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
27935 instead of variable_tracking_main.
27937 2018-01-03 Martin Sebor <msebor@redhat.com>
27939 PR tree-optimization/83603
27940 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
27941 arguments past the endof the argument list in functions declared
27942 without a prototype.
27943 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
27944 Avoid checking when arguments are null.
27946 2018-01-03 Martin Sebor <msebor@redhat.com>
27949 * doc/extend.texi (attribute const): Fix a typo.
27950 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
27951 issuing -Wsuggest-attribute for void functions.
27953 2018-01-03 Martin Sebor <msebor@redhat.com>
27955 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
27956 offset_int::from instead of wide_int::to_shwi.
27957 (maybe_diag_overlap): Remove assertion.
27958 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
27959 * gimple-ssa-sprintf.c (format_directive): Same.
27960 (parse_directive): Same.
27961 (sprintf_dom_walker::compute_format_length): Same.
27962 (try_substitute_return_value): Same.
27964 2018-01-03 Jeff Law <law@redhat.com>
27966 PR middle-end/83654
27967 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
27968 non-constant residual for zero at runtime and avoid probing in
27969 that case. Reorganize code for trailing problem to mirror handling
27972 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27974 PR tree-optimization/83501
27975 * tree-ssa-strlen.c (get_string_cst): New.
27976 (handle_char_store): Call get_string_cst.
27978 2018-01-03 Martin Liska <mliska@suse.cz>
27980 PR tree-optimization/83593
27981 * tree-ssa-strlen.c: Include tree-cfg.h.
27982 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
27983 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
27984 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
27986 (strlen_dom_walker::before_dom_children): Call
27987 gimple_purge_dead_eh_edges. Dump tranformation with details
27989 (strlen_dom_walker::before_dom_children): Update call by adding
27990 new argument cleanup_eh.
27991 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
27993 2018-01-03 Martin Liska <mliska@suse.cz>
27996 * cif-code.def (VARIADIC_THUNK): New enum value.
27997 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
28000 2018-01-03 Jan Beulich <jbeulich@suse.com>
28002 * sse.md (mov<mode>_internal): Tighten condition for when to use
28003 vmovdqu<ssescalarsize> for TI and OI modes.
28005 2018-01-03 Jakub Jelinek <jakub@redhat.com>
28007 Update copyright years.
28009 2018-01-03 Martin Liska <mliska@suse.cz>
28012 * ipa-visibility.c (function_and_variable_visibility): Skip
28013 functions with noipa attribure.
28015 2018-01-03 Jakub Jelinek <jakub@redhat.com>
28017 * gcc.c (process_command): Update copyright notice dates.
28018 * gcov-dump.c (print_version): Ditto.
28019 * gcov.c (print_version): Ditto.
28020 * gcov-tool.c (print_version): Ditto.
28021 * gengtype.c (create_file): Ditto.
28022 * doc/cpp.texi: Bump @copying's copyright year.
28023 * doc/cppinternals.texi: Ditto.
28024 * doc/gcc.texi: Ditto.
28025 * doc/gccint.texi: Ditto.
28026 * doc/gcov.texi: Ditto.
28027 * doc/install.texi: Ditto.
28028 * doc/invoke.texi: Ditto.
28030 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28032 * vector-builder.h (vector_builder::m_full_nelts): Change from
28033 unsigned int to poly_uint64.
28034 (vector_builder::full_nelts): Update prototype accordingly.
28035 (vector_builder::new_vector): Likewise.
28036 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
28037 (vector_builder::operator ==): Likewise.
28038 (vector_builder::finalize): Likewise.
28039 * int-vector-builder.h (int_vector_builder::int_vector_builder):
28040 Take the number of elements as a poly_uint64 rather than an
28042 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
28043 from unsigned int to poly_uint64.
28044 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
28045 (vec_perm_indices::new_vector): Likewise.
28046 (vec_perm_indices::length): Likewise.
28047 (vec_perm_indices::nelts_per_input): Likewise.
28048 (vec_perm_indices::input_nelts): Likewise.
28049 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
28050 number of elements per input as a poly_uint64 rather than an
28051 unsigned int. Use the original encoding for variable-length
28052 vectors, rather than clamping each individual element.
28053 For the second and subsequent elements in each pattern,
28054 clamp the step and base before clamping their sum.
28055 (vec_perm_indices::series_p): Handle polynomial element counts.
28056 (vec_perm_indices::all_in_range_p): Likewise.
28057 (vec_perm_indices_to_tree): Likewise.
28058 (vec_perm_indices_to_rtx): Likewise.
28059 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
28060 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
28061 (tree_vector_builder::new_binary_operation): Handle polynomial
28062 element counts. Return false if we need to know the number
28063 of elements at compile time.
28064 * fold-const.c (fold_vec_perm): Punt if the number of elements
28065 isn't known at compile time.
28067 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28069 * vec-perm-indices.h (vec_perm_builder): Change element type
28070 from HOST_WIDE_INT to poly_int64.
28071 (vec_perm_indices::element_type): Update accordingly.
28072 (vec_perm_indices::clamp): Handle polynomial element_types.
28073 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
28074 (vec_perm_indices::all_in_range_p): Likewise.
28075 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
28077 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
28078 polynomial vec_perm_indices element types.
28079 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
28080 * fold-const.c (fold_vec_perm): Likewise.
28081 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
28082 * tree-vect-generic.c (lower_vec_perm): Likewise.
28083 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
28084 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
28085 element type to HOST_WIDE_INT.
28087 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28088 Alan Hayward <alan.hayward@arm.com>
28089 David Sherwood <david.sherwood@arm.com>
28091 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
28092 rather than an int. Use plus_constant.
28093 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
28094 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
28096 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28097 Alan Hayward <alan.hayward@arm.com>
28098 David Sherwood <david.sherwood@arm.com>
28100 * calls.c (emit_call_1, expand_call): Change struct_value_size from
28101 a HOST_WIDE_INT to a poly_int64.
28103 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28104 Alan Hayward <alan.hayward@arm.com>
28105 David Sherwood <david.sherwood@arm.com>
28107 * calls.c (load_register_parameters): Cope with polynomial
28108 mode sizes. Require a constant size for BLKmode parameters
28109 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
28110 forces a parameter to be padded at the lsb end in order to
28111 fill a complete number of words, require the parameter size
28112 to be ordered wrt UNITS_PER_WORD.
28114 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28115 Alan Hayward <alan.hayward@arm.com>
28116 David Sherwood <david.sherwood@arm.com>
28118 * reload1.c (spill_stack_slot_width): Change element type
28119 from unsigned int to poly_uint64_pod.
28120 (alter_reg): Treat mode sizes as polynomial.
28122 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28123 Alan Hayward <alan.hayward@arm.com>
28124 David Sherwood <david.sherwood@arm.com>
28126 * reload.c (complex_word_subreg_p): New function.
28127 (reload_inner_reg_of_subreg, push_reload): Use it.
28129 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28130 Alan Hayward <alan.hayward@arm.com>
28131 David Sherwood <david.sherwood@arm.com>
28133 * lra-constraints.c (process_alt_operands): Reject matched
28134 operands whose sizes aren't ordered.
28135 (match_reload): Refer to this check here.
28137 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28138 Alan Hayward <alan.hayward@arm.com>
28139 David Sherwood <david.sherwood@arm.com>
28141 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
28142 that the mode size is in the set {1, 2, 4, 8, 16}.
28144 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28145 Alan Hayward <alan.hayward@arm.com>
28146 David Sherwood <david.sherwood@arm.com>
28148 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
28149 Use plus_constant instead of gen_rtx_PLUS.
28151 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28152 Alan Hayward <alan.hayward@arm.com>
28153 David Sherwood <david.sherwood@arm.com>
28155 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
28156 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
28157 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
28158 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
28159 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
28160 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
28161 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
28162 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
28163 * config/i386/i386.c (ix86_push_rounding): ...this new function.
28164 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
28166 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
28167 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
28168 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
28169 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
28170 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
28171 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
28172 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
28173 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
28174 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
28175 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
28177 * expr.c (emit_move_resolve_push): Treat the input and result
28178 of PUSH_ROUNDING as a poly_int64.
28179 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
28180 (emit_push_insn): Likewise.
28181 * lra-eliminations.c (mark_not_eliminable): Likewise.
28182 * recog.c (push_operand): Likewise.
28183 * reload1.c (elimination_effects): Likewise.
28184 * rtlanal.c (nonzero_bits1): Likewise.
28185 * calls.c (store_one_arg): Likewise. Require the padding to be
28186 known at compile time.
28188 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28189 Alan Hayward <alan.hayward@arm.com>
28190 David Sherwood <david.sherwood@arm.com>
28192 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
28193 Use plus_constant instead of gen_rtx_PLUS.
28195 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28196 Alan Hayward <alan.hayward@arm.com>
28197 David Sherwood <david.sherwood@arm.com>
28199 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
28200 rather than an int.
28202 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28203 Alan Hayward <alan.hayward@arm.com>
28204 David Sherwood <david.sherwood@arm.com>
28206 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
28207 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
28208 via stack temporaries. Treat the mode size as polynomial too.
28210 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28211 Alan Hayward <alan.hayward@arm.com>
28212 David Sherwood <david.sherwood@arm.com>
28214 * expr.c (expand_expr_real_2): When handling conversions involving
28215 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
28216 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
28217 as a poly_uint64 too.
28219 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28220 Alan Hayward <alan.hayward@arm.com>
28221 David Sherwood <david.sherwood@arm.com>
28223 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
28225 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28226 Alan Hayward <alan.hayward@arm.com>
28227 David Sherwood <david.sherwood@arm.com>
28229 * combine.c (can_change_dest_mode): Handle polynomial
28230 REGMODE_NATURAL_SIZE.
28231 * expmed.c (store_bit_field_1): Likewise.
28232 * expr.c (store_constructor): Likewise.
28233 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
28234 and polynomial REGMODE_NATURAL_SIZE.
28235 (gen_lowpart_common): Likewise.
28236 * reginfo.c (record_subregs_of_mode): Likewise.
28237 * rtlanal.c (read_modify_subreg_p): Likewise.
28239 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28240 Alan Hayward <alan.hayward@arm.com>
28241 David Sherwood <david.sherwood@arm.com>
28243 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
28244 numbers of elements.
28246 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28247 Alan Hayward <alan.hayward@arm.com>
28248 David Sherwood <david.sherwood@arm.com>
28250 * match.pd: Cope with polynomial numbers of vector elements.
28252 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28253 Alan Hayward <alan.hayward@arm.com>
28254 David Sherwood <david.sherwood@arm.com>
28256 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
28257 in a POINTER_PLUS_EXPR.
28259 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28260 Alan Hayward <alan.hayward@arm.com>
28261 David Sherwood <david.sherwood@arm.com>
28263 * omp-simd-clone.c (simd_clone_subparts): New function.
28264 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
28265 (ipa_simd_modify_function_body): Likewise.
28267 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28268 Alan Hayward <alan.hayward@arm.com>
28269 David Sherwood <david.sherwood@arm.com>
28271 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
28272 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
28273 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
28274 (expand_vector_condition, vector_element): Likewise.
28275 (subparts_gt): New function.
28276 (get_compute_type): Use subparts_gt.
28277 (count_type_subparts): Delete.
28278 (expand_vector_operations_1): Use subparts_gt instead of
28279 count_type_subparts.
28281 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28282 Alan Hayward <alan.hayward@arm.com>
28283 David Sherwood <david.sherwood@arm.com>
28285 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
28286 (vect_compile_time_alias): ...this new function. Do the calculation
28287 on poly_ints rather than trees.
28288 (vect_prune_runtime_alias_test_list): Update call accordingly.
28290 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28291 Alan Hayward <alan.hayward@arm.com>
28292 David Sherwood <david.sherwood@arm.com>
28294 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
28296 (vect_schedule_slp_instance): Likewise.
28298 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28299 Alan Hayward <alan.hayward@arm.com>
28300 David Sherwood <david.sherwood@arm.com>
28302 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
28303 constant and extern definitions for variable-length vectors.
28304 (vect_get_constant_vectors): Note that the number of units
28305 is known to be constant.
28307 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28308 Alan Hayward <alan.hayward@arm.com>
28309 David Sherwood <david.sherwood@arm.com>
28311 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
28312 of units as polynomial. Choose between WIDE and NARROW based
28315 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28316 Alan Hayward <alan.hayward@arm.com>
28317 David Sherwood <david.sherwood@arm.com>
28319 * tree-vect-stmts.c (simd_clone_subparts): New function.
28320 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
28322 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28323 Alan Hayward <alan.hayward@arm.com>
28324 David Sherwood <david.sherwood@arm.com>
28326 * tree-vect-stmts.c (vectorizable_call): Treat the number of
28327 vectors as polynomial. Use build_index_vector for
28328 IFN_GOMP_SIMD_LANE.
28330 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28331 Alan Hayward <alan.hayward@arm.com>
28332 David Sherwood <david.sherwood@arm.com>
28334 * tree-vect-stmts.c (get_load_store_type): Treat the number of
28335 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
28336 for variable-length vectors.
28337 (vectorizable_mask_load_store): Treat the number of units as
28338 polynomial, asserting that it is constant if the condition has
28339 already been enforced.
28340 (vectorizable_store, vectorizable_load): Likewise.
28342 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28343 Alan Hayward <alan.hayward@arm.com>
28344 David Sherwood <david.sherwood@arm.com>
28346 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
28347 of units as polynomial. Punt if we can't tell at compile time
28348 which vector contains the final result.
28350 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28351 Alan Hayward <alan.hayward@arm.com>
28352 David Sherwood <david.sherwood@arm.com>
28354 * tree-vect-loop.c (vectorizable_induction): Treat the number
28355 of units as polynomial. Punt on SLP inductions. Use an integer
28356 VEC_SERIES_EXPR for variable-length integer reductions. Use a
28357 cast of such a series for variable-length floating-point
28360 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28361 Alan Hayward <alan.hayward@arm.com>
28362 David Sherwood <david.sherwood@arm.com>
28364 * tree.h (build_index_vector): Declare.
28365 * tree.c (build_index_vector): New function.
28366 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
28367 of units as polynomial, forcibly converting it to a constant if
28368 vectorizable_reduction has already enforced the condition.
28369 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
28370 to create a {1,2,3,...} vector.
28371 (vectorizable_reduction): Treat the number of units as polynomial.
28372 Choose vectype_in based on the largest scalar element size rather
28373 than the smallest number of units. Enforce the restrictions
28376 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28377 Alan Hayward <alan.hayward@arm.com>
28378 David Sherwood <david.sherwood@arm.com>
28380 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
28381 number of units as polynomial.
28383 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28384 Alan Hayward <alan.hayward@arm.com>
28385 David Sherwood <david.sherwood@arm.com>
28387 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
28388 * target.def (autovectorize_vector_sizes): Return the vector sizes
28389 by pointer, using vector_sizes rather than a bitmask.
28390 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
28391 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
28392 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
28394 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
28395 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
28396 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
28397 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
28398 * omp-general.c (omp_max_vf): Likewise.
28399 * omp-low.c (omp_clause_aligned_alignment): Likewise.
28400 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
28401 * tree-vect-loop.c (vect_analyze_loop): Likewise.
28402 * tree-vect-slp.c (vect_slp_bb): Likewise.
28403 * doc/tm.texi: Regenerate.
28404 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
28406 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
28407 the vector size as a poly_uint64 rather than an unsigned int.
28408 (current_vector_size): Change from an unsigned int to a poly_uint64.
28409 (get_vectype_for_scalar_type): Update accordingly.
28410 * tree.h (build_truth_vector_type): Take the size and number of
28411 units as a poly_uint64 rather than an unsigned int.
28412 (build_vector_type): Add a temporary overload that takes
28413 the number of units as a poly_uint64 rather than an unsigned int.
28414 * tree.c (make_vector_type): Likewise.
28415 (build_truth_vector_type): Take the number of units as a poly_uint64
28416 rather than an unsigned int.
28418 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28419 Alan Hayward <alan.hayward@arm.com>
28420 David Sherwood <david.sherwood@arm.com>
28422 * target.def (get_mask_mode): Take the number of units and length
28423 as poly_uint64s rather than unsigned ints.
28424 * targhooks.h (default_get_mask_mode): Update accordingly.
28425 * targhooks.c (default_get_mask_mode): Likewise.
28426 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
28427 * doc/tm.texi: Regenerate.
28429 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28430 Alan Hayward <alan.hayward@arm.com>
28431 David Sherwood <david.sherwood@arm.com>
28433 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
28434 * omp-general.c (omp_max_vf): Likewise.
28435 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
28436 (expand_omp_simd): Handle polynomial safelen.
28437 * omp-low.c (omplow_simd_context): Add a default constructor.
28438 (omplow_simd_context::max_vf): Change from int to poly_uint64.
28439 (lower_rec_simd_input_clauses): Update accordingly.
28440 (lower_rec_input_clauses): Likewise.
28442 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28443 Alan Hayward <alan.hayward@arm.com>
28444 David Sherwood <david.sherwood@arm.com>
28446 * tree-vectorizer.h (vect_nunits_for_cost): New function.
28447 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
28448 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
28449 (vect_analyze_slp_cost): Likewise.
28450 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
28451 (vect_model_load_cost): Likewise.
28453 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28454 Alan Hayward <alan.hayward@arm.com>
28455 David Sherwood <david.sherwood@arm.com>
28457 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
28458 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
28459 from an unsigned int * to a poly_uint64_pod *.
28460 (calculate_unrolling_factor): New function.
28461 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
28463 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28464 Alan Hayward <alan.hayward@arm.com>
28465 David Sherwood <david.sherwood@arm.com>
28467 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
28468 from an unsigned int to a poly_uint64.
28469 (_loop_vec_info::slp_unrolling_factor): Likewise.
28470 (_loop_vec_info::vectorization_factor): Change from an int
28472 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
28473 (vect_get_num_vectors): New function.
28474 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
28475 (vect_get_num_copies): Use vect_get_num_vectors.
28476 (vect_analyze_data_ref_dependences): Change max_vf from an int *
28477 to an unsigned int *.
28478 (vect_analyze_data_refs): Change min_vf from an int * to a
28480 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
28481 than an unsigned HOST_WIDE_INT.
28482 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
28483 (vect_analyze_data_ref_dependence): Change max_vf from an int *
28484 to an unsigned int *.
28485 (vect_analyze_data_ref_dependences): Likewise.
28486 (vect_compute_data_ref_alignment): Handle polynomial vf.
28487 (vect_enhance_data_refs_alignment): Likewise.
28488 (vect_prune_runtime_alias_test_list): Likewise.
28489 (vect_shift_permute_load_chain): Likewise.
28490 (vect_supportable_dr_alignment): Likewise.
28491 (dependence_distance_ge_vf): Take the vectorization factor as a
28492 poly_uint64 rather than an unsigned HOST_WIDE_INT.
28493 (vect_analyze_data_refs): Change min_vf from an int * to a
28495 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
28496 vfm1 as a poly_uint64 rather than an int. Make the same change
28497 for the returned bound_scalar.
28498 (vect_gen_vector_loop_niters): Handle polynomial vf.
28499 (vect_do_peeling): Likewise. Update call to
28500 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
28501 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
28503 * tree-vect-loop.c (vect_determine_vectorization_factor)
28504 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
28505 (vect_get_known_peeling_cost): Likewise.
28506 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
28507 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
28508 (vect_transform_loop): Likewise. Use the lowest possible VF when
28509 updating the upper bounds of the loop.
28510 (vect_min_worthwhile_factor): Make static. Return an unsigned int
28511 rather than an int.
28512 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
28513 polynomial unroll factors.
28514 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
28515 (vect_make_slp_decision): Likewise.
28516 (vect_supported_load_permutation_p): Likewise, and polynomial
28518 (vect_analyze_slp_cost): Handle polynomial vf.
28519 (vect_slp_analyze_node_operations): Likewise.
28520 (vect_slp_analyze_bb_1): Likewise.
28521 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
28522 than an unsigned HOST_WIDE_INT.
28523 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
28524 (vectorizable_load): Handle polynomial vf.
28525 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
28527 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
28529 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28530 Alan Hayward <alan.hayward@arm.com>
28531 David Sherwood <david.sherwood@arm.com>
28533 * match.pd: Handle bit operations involving three constants
28534 and try to fold one pair.
28536 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28538 * tree-vect-loop-manip.c: Include gimple-fold.h.
28539 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
28540 niters_maybe_zero parameters. Handle other cases besides a step of 1.
28541 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
28542 Add a path that uses a step of VF instead of 1, but disable it
28544 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
28545 and niters_no_overflow parameters. Update calls to
28546 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
28547 Create a new SSA name if the latter choses to use a ste other
28548 than zero, and return it via niters_vector_mult_vf_var.
28549 * tree-vect-loop.c (vect_transform_loop): Update calls to
28550 vect_do_peeling, vect_gen_vector_loop_niters and
28551 slpeel_make_loop_iterate_ntimes.
28552 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
28553 (vect_gen_vector_loop_niters): Update declarations after above changes.
28555 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
28557 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
28558 128-bit round to integer instructions.
28559 (ceil<mode>2): Likewise.
28560 (btrunc<mode>2): Likewise.
28561 (round<mode>2): Likewise.
28563 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28565 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
28566 unaligned VSX load/store on P8/P9.
28567 (expand_block_clear): Allow the use of unaligned VSX
28568 load/store on P8/P9.
28570 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
28572 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
28574 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
28575 swap associated with both a load and a store.
28577 2018-01-02 Andrew Waterman <andrew@sifive.com>
28579 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
28580 * config/riscv/riscv.md (clear_cache): Use it.
28582 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
28584 * web.c: Remove out-of-date comment.
28586 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28588 * expr.c (fixup_args_size_notes): Check that any existing
28589 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
28590 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
28591 (emit_single_push_insn): ...here.
28593 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28595 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
28596 (const_vector_encoded_nelts): New function.
28597 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
28598 (const_vector_int_elt, const_vector_elt): Declare.
28599 * emit-rtl.c (const_vector_int_elt_1): New function.
28600 (const_vector_elt): Likewise.
28601 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
28602 of CONST_VECTOR_ELT.
28604 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28606 * expr.c: Include rtx-vector-builder.h.
28607 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
28608 directly on the tree encoding.
28609 (const_vector_from_tree): Likewise.
28610 * optabs.c: Include rtx-vector-builder.h.
28611 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
28612 sequence of "u" values.
28613 * vec-perm-indices.c: Include rtx-vector-builder.h.
28614 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
28615 directly on the vec_perm_indices encoding.
28617 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28619 * doc/rtl.texi (const_vector): Describe new encoding scheme.
28620 * Makefile.in (OBJS): Add rtx-vector-builder.o.
28621 * rtx-vector-builder.h: New file.
28622 * rtx-vector-builder.c: Likewise.
28623 * rtl.h (rtx_def::u2): Add a const_vector field.
28624 (CONST_VECTOR_NPATTERNS): New macro.
28625 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
28626 (CONST_VECTOR_DUPLICATE_P): Likewise.
28627 (CONST_VECTOR_STEPPED_P): Likewise.
28628 (CONST_VECTOR_ENCODED_ELT): Likewise.
28629 (const_vec_duplicate_p): Check for a duplicated vector encoding.
28630 (unwrap_const_vec_duplicate): Likewise.
28631 (const_vec_series_p): Check for a non-duplicated vector encoding.
28632 Say that the function only returns true for integer vectors.
28633 * emit-rtl.c: Include rtx-vector-builder.h.
28634 (gen_const_vec_duplicate_1): Delete.
28635 (gen_const_vector): Call gen_const_vec_duplicate instead of
28636 gen_const_vec_duplicate_1.
28637 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
28638 (gen_const_vec_duplicate): Use rtx_vector_builder.
28639 (gen_const_vec_series): Likewise.
28640 (gen_rtx_CONST_VECTOR): Likewise.
28641 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
28642 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
28643 Build a new vector rather than modifying a CONST_VECTOR in-place.
28644 (handle_special_swappables): Update call accordingly.
28645 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
28646 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
28647 Build a new vector rather than modifying a CONST_VECTOR in-place.
28648 (handle_special_swappables): Update call accordingly.
28650 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28652 * simplify-rtx.c (simplify_const_binary_operation): Use
28653 CONST_VECTOR_ELT instead of XVECEXP.
28655 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28657 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
28658 the selector elements to be different from the data elements
28659 if the selector is a VECTOR_CST.
28660 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
28661 ssizetype for the selector.
28663 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28665 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
28666 before testing each element individually.
28667 * tree-vect-generic.c (lower_vec_perm): Likewise.
28669 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28671 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
28672 * selftest-run-tests.c (selftest::run_tests): Call it.
28673 * vector-builder.h (vector_builder::operator ==): New function.
28674 (vector_builder::operator !=): Likewise.
28675 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
28676 (vec_perm_indices::all_from_input_p): New function.
28677 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
28678 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
28679 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
28680 instead of reading the VECTOR_CST directly. Detect whether both
28681 vector inputs are the same before constructing the vec_perm_indices,
28682 and update the number of inputs argument accordingly. Use the
28683 utility functions added above. Only construct sel2 if we need to.
28685 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28687 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
28688 the broadcast of the low byte.
28689 (expand_mult_highpart): Use an explicit encoding for the permutes.
28690 * optabs-query.c (can_mult_highpart_p): Likewise.
28691 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
28692 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
28693 (vectorizable_bswap): Likewise.
28694 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
28695 explicit encoding for the power-of-2 permutes.
28696 (vect_permute_store_chain): Likewise.
28697 (vect_grouped_load_supported): Likewise.
28698 (vect_permute_load_chain): Likewise.
28700 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28702 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
28703 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
28704 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
28705 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
28706 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
28707 (vect_gen_perm_mask_any): Likewise.
28709 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28711 * int-vector-builder.h: New file.
28712 * vec-perm-indices.h: Include int-vector-builder.h.
28713 (vec_perm_indices): Redefine as an int_vector_builder.
28714 (auto_vec_perm_indices): Delete.
28715 (vec_perm_builder): Redefine as a stand-alone class.
28716 (vec_perm_indices::vec_perm_indices): New function.
28717 (vec_perm_indices::clamp): Likewise.
28718 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
28719 (vec_perm_indices::new_vector): New function.
28720 (vec_perm_indices::new_expanded_vector): Update for new
28721 vec_perm_indices class.
28722 (vec_perm_indices::rotate_inputs): New function.
28723 (vec_perm_indices::all_in_range_p): Operate directly on the
28724 encoded form, without computing elided elements.
28725 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
28726 encoding. Update for new vec_perm_indices class.
28727 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
28728 the given vec_perm_builder.
28729 (expand_vec_perm_var): Update vec_perm_builder constructor.
28730 (expand_mult_highpart): Use vec_perm_builder instead of
28731 auto_vec_perm_indices.
28732 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
28733 vec_perm_indices instead of auto_vec_perm_indices. Use a single
28734 or double series encoding as appropriate.
28735 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
28736 vec_perm_indices instead of auto_vec_perm_indices.
28737 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28738 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
28739 (vect_permute_store_chain): Likewise.
28740 (vect_grouped_load_supported): Likewise.
28741 (vect_permute_load_chain): Likewise.
28742 (vect_shift_permute_load_chain): Likewise.
28743 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
28744 (vect_transform_slp_perm_load): Likewise.
28745 (vect_schedule_slp_instance): Likewise.
28746 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
28747 (vectorizable_mask_load_store): Likewise.
28748 (vectorizable_bswap): Likewise.
28749 (vectorizable_store): Likewise.
28750 (vectorizable_load): Likewise.
28751 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
28752 vec_perm_indices instead of auto_vec_perm_indices. Use
28753 tree_to_vec_perm_builder to read the vector from a tree.
28754 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
28755 vec_perm_builder instead of a vec_perm_indices.
28756 (have_whole_vector_shift): Use vec_perm_builder and
28757 vec_perm_indices instead of auto_vec_perm_indices. Leave the
28758 truncation to calc_vec_perm_mask_for_shift.
28759 (vect_create_epilog_for_reduction): Likewise.
28760 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
28761 from auto_vec_perm_indices to vec_perm_indices.
28762 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
28763 instead of changing individual elements.
28764 (aarch64_vectorize_vec_perm_const): Use new_vector to install
28765 the vector in d.perm.
28766 * config/arm/arm.c (expand_vec_perm_d::perm): Change
28767 from auto_vec_perm_indices to vec_perm_indices.
28768 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
28769 instead of changing individual elements.
28770 (arm_vectorize_vec_perm_const): Use new_vector to install
28771 the vector in d.perm.
28772 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
28773 Update vec_perm_builder constructor.
28774 (rs6000_expand_interleave): Likewise.
28775 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
28776 (rs6000_expand_interleave): Likewise.
28778 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28780 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
28781 to qimode could truncate the indices.
28782 * optabs.c (expand_vec_perm_var): Likewise.
28784 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28786 * Makefile.in (OBJS): Add vec-perm-indices.o.
28787 * vec-perm-indices.h: New file.
28788 * vec-perm-indices.c: Likewise.
28789 * target.h (vec_perm_indices): Replace with a forward class
28791 (auto_vec_perm_indices): Move to vec-perm-indices.h.
28792 * optabs.h: Include vec-perm-indices.h.
28793 (expand_vec_perm): Delete.
28794 (selector_fits_mode_p, expand_vec_perm_var): Declare.
28795 (expand_vec_perm_const): Declare.
28796 * target.def (vec_perm_const_ok): Replace with...
28797 (vec_perm_const): ...this new hook.
28798 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
28799 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
28800 * doc/tm.texi: Regenerate.
28801 * optabs.def (vec_perm_const): Delete.
28802 * doc/md.texi (vec_perm_const): Likewise.
28803 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
28804 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
28805 expand_vec_perm for constant permutation vectors. Assert that
28806 the mode of variable permutation vectors is the integer equivalent
28807 of the mode that is being permuted.
28808 * optabs-query.h (selector_fits_mode_p): Declare.
28809 * optabs-query.c: Include vec-perm-indices.h.
28810 (selector_fits_mode_p): New function.
28811 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
28812 is defined, instead of checking whether the vec_perm_const_optab
28813 exists. Use targetm.vectorize.vec_perm_const instead of
28814 targetm.vectorize.vec_perm_const_ok. Check whether the indices
28815 fit in the vector mode before using a variable permute.
28816 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
28817 vec_perm_indices instead of an rtx.
28818 (expand_vec_perm): Replace with...
28819 (expand_vec_perm_const): ...this new function. Take the selector
28820 as a vec_perm_indices rather than an rtx. Also take the mode of
28821 the selector. Update call to shift_amt_for_vec_perm_mask.
28822 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
28823 Use vec_perm_indices::new_expanded_vector to expand the original
28824 selector into bytes. Check whether the indices fit in the vector
28825 mode before using a variable permute.
28826 (expand_vec_perm_var): Make global.
28827 (expand_mult_highpart): Use expand_vec_perm_const.
28828 * fold-const.c: Includes vec-perm-indices.h.
28829 * tree-ssa-forwprop.c: Likewise.
28830 * tree-vect-data-refs.c: Likewise.
28831 * tree-vect-generic.c: Likewise.
28832 * tree-vect-loop.c: Likewise.
28833 * tree-vect-slp.c: Likewise.
28834 * tree-vect-stmts.c: Likewise.
28835 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
28837 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
28838 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
28839 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
28840 (aarch64_vectorize_vec_perm_const): ...this new function.
28841 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
28842 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
28843 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
28844 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
28845 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
28846 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
28847 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
28849 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
28850 check for NEON modes.
28851 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
28852 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
28853 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
28854 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
28856 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
28857 the old VEC_PERM_CONST conditions.
28858 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
28859 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
28860 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
28861 (ia64_vectorize_vec_perm_const_ok): Merge into...
28862 (ia64_vectorize_vec_perm_const): ...this new function.
28863 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
28864 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
28865 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
28866 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
28867 * config/mips/mips.c (mips_expand_vec_perm_const)
28868 (mips_vectorize_vec_perm_const_ok): Merge into...
28869 (mips_vectorize_vec_perm_const): ...this new function.
28870 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
28871 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
28872 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
28873 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
28874 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
28875 (rs6000_expand_vec_perm_const): Delete.
28876 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
28878 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
28879 (altivec_expand_vec_perm_const_le): Take each operand individually.
28880 Operate on constant selectors rather than rtxes.
28881 (altivec_expand_vec_perm_const): Likewise. Update call to
28882 altivec_expand_vec_perm_const_le.
28883 (rs6000_expand_vec_perm_const): Delete.
28884 (rs6000_vectorize_vec_perm_const_ok): Delete.
28885 (rs6000_vectorize_vec_perm_const): New function.
28886 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
28887 an element count and rtx array.
28888 (rs6000_expand_extract_even): Update call accordingly.
28889 (rs6000_expand_interleave): Likewise.
28890 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
28891 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
28892 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
28893 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
28894 (rs6000_expand_vec_perm_const): Delete.
28895 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
28896 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
28897 (altivec_expand_vec_perm_const_le): Take each operand individually.
28898 Operate on constant selectors rather than rtxes.
28899 (altivec_expand_vec_perm_const): Likewise. Update call to
28900 altivec_expand_vec_perm_const_le.
28901 (rs6000_expand_vec_perm_const): Delete.
28902 (rs6000_vectorize_vec_perm_const_ok): Delete.
28903 (rs6000_vectorize_vec_perm_const): New function. Remove stray
28904 reference to the SPE evmerge intructions.
28905 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
28906 an element count and rtx array.
28907 (rs6000_expand_extract_even): Update call accordingly.
28908 (rs6000_expand_interleave): Likewise.
28909 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
28910 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
28912 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
28914 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28916 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
28917 vector mode and that that mode matches the mode of the data
28919 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
28920 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
28921 directly using expand_vec_perm_1 when forcing selectors into
28923 (expand_vec_perm_var): New function, split out from expand_vec_perm.
28925 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28927 * optabs-query.h (can_vec_perm_p): Delete.
28928 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
28929 * optabs-query.c (can_vec_perm_p): Split into...
28930 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
28931 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
28932 particular selector is valid.
28933 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28934 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
28935 (vect_grouped_load_supported): Likewise.
28936 (vect_shift_permute_load_chain): Likewise.
28937 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
28938 (vect_transform_slp_perm_load): Likewise.
28939 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
28940 (vectorizable_bswap): Likewise.
28941 (vect_gen_perm_mask_checked): Likewise.
28942 * fold-const.c (fold_ternary_loc): Likewise. Don't take
28943 implementations of variable permutation vectors into account
28944 when deciding which selector to use.
28945 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
28946 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
28947 with a false third argument.
28948 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
28949 to test whether the constant selector is valid and can_vec_perm_var_p
28950 to test whether a variable selector is valid.
28952 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28954 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
28955 * optabs-query.c (can_vec_perm_p): Likewise.
28956 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
28957 instead of vec_perm_indices.
28958 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
28959 (vect_gen_perm_mask_checked): Likewise,
28960 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
28961 (vect_gen_perm_mask_checked): Likewise,
28963 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
28965 * optabs-query.h (qimode_for_vec_perm): Declare.
28966 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
28967 (qimode_for_vec_perm): ...this new function.
28968 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
28970 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28972 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
28973 does not have a conditional at the top.
28975 2018-01-02 Richard Biener <rguenther@suse.de>
28977 * ipa-inline.c (big_speedup_p): Fix expression.
28979 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
28982 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
28985 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
28989 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
28990 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
28991 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
28992 cond_taken_branch_cost 3->4.
28994 2018-01-01 Jakub Jelinek <jakub@redhat.com>
28996 PR tree-optimization/83581
28997 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
28998 TODO_cleanup_cfg if any changes have been made.
29000 PR middle-end/83608
29001 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
29002 convert_modes if target mode has the right side, but different mode
29005 PR middle-end/83609
29006 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
29007 last argument when extracting from CONCAT. If either from_real or
29008 from_imag is NULL, use expansion through memory. If result is not
29009 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
29010 the parts directly to inner mode, if even that fails, use expansion
29013 PR middle-end/83623
29014 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
29015 check for bswap in mode rather than HImode and use that in expand_unop
29018 Copyright (C) 2018 Free Software Foundation, Inc.
29020 Copying and distribution of this file, with or without modification,
29021 are permitted in any medium without royalty provided the copyright
29022 notice and this notice are preserved.