1 2020-01-29 Joel Hutton <Joel.Hutton@arm.com>
4 * ira.c (ira): Revert use of simplified LRA algorithm.
6 2020-01-29 Martin Jambor <mjambor@suse.cz>
8 PR tree-optimization/92706
9 * tree-sra.c (struct access): Fields first_link, last_link,
10 next_queued and grp_queued renamed to first_rhs_link, last_rhs_link,
11 next_rhs_queued and grp_rhs_queued respectively, new fields
12 first_lhs_link, last_lhs_link, next_lhs_queued and grp_lhs_queued.
13 (struct assign_link): Field next renamed to next_rhs, new field
14 next_lhs. Updated comment.
15 (work_queue_head): Renamed to rhs_work_queue_head.
16 (lhs_work_queue_head): New variable.
17 (add_link_to_lhs): New function.
18 (relink_to_new_repr): Also relink LHS lists.
19 (add_access_to_work_queue): Renamed to add_access_to_rhs_work_queue.
20 (add_access_to_lhs_work_queue): New function.
21 (pop_access_from_work_queue): Renamed to
22 pop_access_from_rhs_work_queue.
23 (pop_access_from_lhs_work_queue): New function.
24 (build_accesses_from_assign): Also add links to LHS lists and to LHS
26 (child_would_conflict_in_lacc): Renamed to
27 child_would_conflict_in_acc. Adjusted parameter names.
28 (create_artificial_child_access): New parameter set_grp_read, use it.
29 (subtree_mark_written_and_enqueue): Renamed to
30 subtree_mark_written_and_rhs_enqueue.
31 (propagate_subaccesses_across_link): Renamed to
32 propagate_subaccesses_from_rhs.
33 (propagate_subaccesses_from_lhs): New function.
34 (propagate_all_subaccesses): Also propagate subaccesses from LHSs to
37 2020-01-29 Martin Jambor <mjambor@suse.cz>
39 PR tree-optimization/92706
40 * tree-sra.c (struct access): Adjust comment of
41 grp_total_scalarization.
42 (find_access_in_subtree): Look for single children spanning an entire
44 (scalarizable_type_p): Allow register accesses, adjust callers.
45 (completely_scalarize): Remove function.
46 (scalarize_elem): Likewise.
47 (create_total_scalarization_access): Likewise.
48 (sort_and_splice_var_accesses): Do not track total scalarization
50 (analyze_access_subtree): New parameter totally, adjust to new meaning
51 of grp_total_scalarization.
52 (analyze_access_trees): Pass new parameter to analyze_access_subtree.
53 (can_totally_scalarize_forest_p): New function.
54 (create_total_scalarization_access): Likewise.
55 (create_total_access_and_reshape): Likewise.
56 (total_should_skip_creating_access): Likewise.
57 (totally_scalarize_subtree): Likewise.
58 (analyze_all_variable_accesses): Perform total scalarization after
59 subaccess propagation using the new functions above.
60 (initialize_constant_pool_replacements): Output initializers by
61 traversing the access tree.
63 2020-01-29 Martin Jambor <mjambor@suse.cz>
65 * tree-sra.c (verify_sra_access_forest): New function.
66 (verify_all_sra_access_forests): Likewise.
67 (create_artificial_child_access): Set parent.
68 (analyze_all_variable_accesses): Call the verifier.
70 2020-01-28 Jan Hubicka <hubicka@ucw.cz>
72 * cgraph.c (cgraph_edge::resolve_speculation): Only lookup direct edge
73 if called on indirect edge.
74 (cgraph_edge::redirect_call_stmt_to_callee): Lookup indirect edge of
75 speculative call if needed.
77 2020-01-29 Richard Biener <rguenther@suse.de>
79 PR tree-optimization/93428
80 * tree-vect-slp.c (vect_build_slp_tree_2): Compute the load
81 permutation when the load node is created.
82 (vect_analyze_slp_instance): Re-use it here.
84 2020-01-28 Jan Hubicka <hubicka@ucw.cz>
86 * ipa-prop.c (update_indirect_edges_after_inlining): Fix warning.
88 2020-01-28 Vladimir Makarov <vmakarov@redhat.com>
90 PR rtl-optimization/93272
91 * ira-lives.c (process_out_of_region_eh_regs): New function.
92 (process_bb_node_lives): Call it.
94 2020-01-28 Jan Hubicka <hubicka@ucw.cz>
96 * coverage.c (read_counts_file): Make error message lowercase.
98 2020-01-28 Jan Hubicka <hubicka@ucw.cz>
100 * profile-count.c (profile_quality_display_names): Fix ordering.
102 2020-01-28 Jan Hubicka <hubicka@ucw.cz>
105 * cgraph.c (cgraph_add_edge_to_call_site_hash): Update call site
106 hash only when edge is first within the sequence.
107 (cgraph_edge::set_call_stmt): Update handling of speculative calls.
108 (symbol_table::create_edge): Do not set target_prob.
109 (cgraph_edge::remove_caller): Watch for speculative calls when updating
111 (cgraph_edge::make_speculative): Drop target_prob parameter.
112 (cgraph_edge::speculative_call_info): Remove.
113 (cgraph_edge::first_speculative_call_target): New member function.
114 (update_call_stmt_hash_for_removing_direct_edge): New function.
115 (cgraph_edge::resolve_speculation): Rewrite to new API.
116 (cgraph_edge::speculative_call_for_target): New member function.
117 (cgraph_edge::make_direct): Rewrite to new API; fix handling of
118 multiple speculation targets.
119 (cgraph_edge::redirect_call_stmt_to_callee): Likewise; fix updating
121 (verify_speculative_call): Verify that targets form an interval.
122 * cgraph.h (cgraph_edge::speculative_call_info): Remove.
123 (cgraph_edge::first_speculative_call_target): New member function.
124 (cgraph_edge::next_speculative_call_target): New member function.
125 (cgraph_edge::speculative_call_target_ref): New member function.
126 (cgraph_edge;:speculative_call_indirect_edge): New member funtion.
127 (cgraph_edge): Remove target_prob.
128 * cgraphclones.c (cgraph_node::set_call_stmt_including_clones):
129 Fix handling of speculative calls.
130 * ipa-devirt.c (ipa_devirt): Fix handling of speculative cals.
131 * ipa-fnsummary.c (analyze_function_body): Likewise.
132 * ipa-inline.c (speculation_useful_p): Use new speculative call API.
133 * ipa-profile.c (dump_histogram): Fix formating.
134 (ipa_profile_generate_summary): Watch for overflows.
135 (ipa_profile): Do not require probablity to be 1/2; update to new API.
136 * ipa-prop.c (ipa_make_edge_direct_to_target): Update to new API.
137 (update_indirect_edges_after_inlining): Update to new API.
138 * ipa-utils.c (ipa_merge_profiles): Rewrite merging of speculative call
140 * profile-count.h: (profile_probability::adjusted): New.
141 * tree-inline.c (copy_bb): Update to new speculative call API; fix
143 * value-prof.c (gimple_ic_transform): Rename to ...
144 (dump_ic_profile): ... this one; update dumping.
145 (stream_in_histogram_value): Fix formating.
146 (gimple_value_profile_transformations): Update.
148 2020-01-28 H.J. Lu <hongjiu.lu@intel.com>
151 * config/i386/i386.md (*movoi_internal_avx): Remove
152 TARGET_SSE_TYPELESS_STORES check.
153 (*movti_internal): Prefer TARGET_AVX over
154 TARGET_SSE_TYPELESS_STORES.
155 (*movtf_internal): Likewise.
156 * config/i386/sse.md (mov<mode>_internal): Prefer TARGET_AVX over
157 TARGET_SSE_TYPELESS_STORES. Remove "<MODE_SIZE> == 16" check
158 from TARGET_SSE_TYPELESS_STORES.
160 2020-01-28 David Malcolm <dmalcolm@redhat.com>
162 * diagnostic-core.h (warning_at): Rename overload to...
163 (warning_meta): ...this.
164 (emit_diagnostic_valist): Delete decl of overload taking
166 * diagnostic.c (emit_diagnostic_valist): Likewise for defn.
167 (warning_at): Rename overload taking diagnostic_metadata to...
168 (warning_meta): ...this.
170 2020-01-28 Richard Biener <rguenther@suse.de>
172 PR tree-optimization/93439
173 * tree-parloops.c (create_loop_fn): Move clique bookkeeping...
174 * tree-cfg.c (move_sese_region_to_fn): ... here.
175 (verify_types_in_gimple_reference): Verify used cliques are
178 2020-01-28 H.J. Lu <hongjiu.lu@intel.com>
181 * config/i386/i386-options.c (set_ix86_tune_features): Add an
182 argument of a pointer to struct gcc_options and pass it to
183 parse_mtune_ctrl_str.
184 (ix86_function_specific_restore): Pass opts to
185 set_ix86_tune_features.
186 (ix86_option_override_internal): Likewise.
187 (parse_mtune_ctrl_str): Add an argument of a pointer to struct
188 gcc_options and use it for x_ix86_tune_ctrl_string.
190 2020-01-28 Richard Sandiford <richard.sandiford@arm.com>
192 PR rtl-optimization/87763
193 * simplify-rtx.c (simplify_truncation): Extend sign/zero_extract
194 simplification to handle subregs as well as bare regs.
195 * config/i386/i386.md (*testqi_ext_3): Match QI extracts too.
197 2020-01-28 Richard Sandiford <richard.sandiford@arm.com>
199 * tree-vect-loop.c (vectorizable_reduction): Fail gracefully
200 for reduction chains that (now) include a call.
202 2020-01-28 Richard Sandiford <richard.sandiford@arm.com>
204 PR tree-optimization/92822
205 * tree-ssa-forwprop.c (simplify_vector_constructor): When filling
206 out the don't-care elements of a vector whose significant elements
207 are duplicates, make the don't-care elements duplicates too.
209 2020-01-28 Richard Sandiford <richard.sandiford@arm.com>
211 PR tree-optimization/93434
212 * tree-predcom.c (split_data_refs_to_components): Record which
213 components have had aliasing loads removed. Prevent store-store
214 commoning for all such components.
216 2020-01-28 Jakub Jelinek <jakub@redhat.com>
219 * config/i386/i386.c (ix86_fold_builtin) <do_shift>: If mask is not
220 -1 or is_vshift is true, use new_vector with number of elts npatterns
221 rather than new_unary_operation.
223 PR tree-optimization/93454
224 * gimple-fold.c (fold_array_ctor_reference): Perform
225 elt_size.to_uhwi () just once, instead of calling it in every
226 iteration. Punt if that value is above size of the temporary
227 buffer. Decrease third native_encode_expr argument when
228 bufoff + elt_sz is above size of buf.
230 2020-01-27 Joseph Myers <joseph@codesourcery.com>
232 * config/mips/mips.c (mips_declare_object_name)
233 [USE_GNU_UNIQUE_OBJECT]: Support use of gnu_unique_object.
235 2020-01-27 Martin Liska <mliska@suse.cz>
237 PR gcov-profile/93403
238 * tree-profile.c (gimple_init_gcov_profiler): Generate
239 both __gcov_indirect_call_profiler_v4 and
240 __gcov_indirect_call_profiler_v4_atomic.
242 2020-01-27 Richard Sandiford <richard.sandiford@arm.com>
245 * config/aarch64/aarch64-simd.md (aarch64_get_half<mode>): New
247 (@aarch64_split_simd_mov<mode>): Use it.
248 (aarch64_simd_mov_from_<mode>low): Add a GPR alternative.
249 Leave the vec_extract patterns to handle 2-element vectors.
250 (aarch64_simd_mov_from_<mode>high): Likewise.
251 (vec_extract<VQMOV_NO2E:mode><Vhalf>): New expander.
252 (vec_extractv2dfv1df): Likewise.
254 2020-01-27 Richard Sandiford <richard.sandiford@arm.com>
256 * config/aarch64/aarch64.c (aarch64_if_then_else_costs): Match
257 jump conditions for *compare_condjump<GPI:mode>.
259 2020-01-27 David Malcolm <dmalcolm@redhat.com>
262 * digraph.cc (test_edge::test_edge): Specify template for base
265 2020-01-27 Claudiu Zissulescu <claziss@synopsys.com>
267 * config/arc/arc.c (arc_rtx_costs): Update mul64 cost.
269 2020-01-27 Claudiu Zissulescu <claziss@synopsys.com>
271 * config/arc/arc-protos.h (gen_mlo): Remove.
273 * config/arc/arc.c (AUX_MULHI): Define.
274 (arc_must_save_reister): Special handling for r58/59.
275 (arc_compute_frame_size): Consider mlo/mhi registers.
276 (arc_save_callee_saves): Emit fp/sp move only when emit_move
278 (arc_conditional_register_usage): Remove TARGET_BIG_ENDIAN from
279 mlo/mhi name selection.
280 (arc_restore_callee_saves): Don't early restore blink when ISR.
281 (arc_expand_prologue): Add mlo/mhi saving.
282 (arc_expand_epilogue): Add mlo/mhi restoring.
285 * config/arc/arc.h (DBX_REGISTER_NUMBER): Correct register
286 numbering when MUL64 option is used.
287 (DWARF2_FRAME_REG_OUT): Define.
288 * config/arc/arc.md (arc600_stall): New pattern.
289 (VUNSPEC_ARC_ARC600_STALL): Define.
290 (mulsi64): Use correct mlo/mhi registers.
291 (mulsi_600): Clean it up.
292 * config/arc/predicates.md (mlo_operand): Remove any dependency on
294 (mhi_operand): Likewise.
296 2020-01-27 Claudiu Zissulescu <claziss@synopsys.com>
297 Petro Karashchenko <petro.karashchenko@ring.com>
299 * config/arc/arc.c (arc_is_uncached_mem_p): Check struct
300 attributes if needed.
301 (prepare_move_operands): Generate special unspec instruction for
303 (arc_isuncached_mem_p): Propagate uncached attribute to each
305 * config/arc/arc.md (VUNSPEC_ARC_LDDI): Define.
306 (VUNSPEC_ARC_STDI): Likewise.
307 (ALLI): New mode iterator.
308 (mALLI): New mode attribute.
309 (lddi): New instruction pattern.
311 (stdidi_split): Split instruction for architectures which are not
312 supporting ll64 option.
313 (lddidi_split): Likewise.
315 2020-01-27 Richard Sandiford <richard.sandiford@arm.com>
317 PR rtl-optimization/92989
318 * lra-lives.c (process_bb_lives): Update the live-in set before
319 processing additional clobbers.
321 2020-01-27 Richard Sandiford <richard.sandiford@arm.com>
323 PR rtl-optimization/93170
324 * cselib.c (cselib_invalidate_regno_val): New function, split out
326 (cselib_invalidate_regno): ...here.
327 (cselib_invalidated_by_call_p): New function.
328 (cselib_process_insn): Iterate over all the hard-register entries in
329 REG_VALUES and invalidate any that cross call-clobbered registers.
331 2020-01-27 Richard Sandiford <richard.sandiford@arm.com>
333 * dojump.c (split_comparison): Use HONOR_NANS rather than
334 HONOR_SNANS when splitting LTGT.
336 2020-01-27 Martin Liska <mliska@suse.cz>
339 * opts.c (print_filtered_help): Exclude language-specific
340 options from --help=common unless enabled in all FEs.
342 2020-01-27 Martin Liska <mliska@suse.cz>
344 * opts.c (print_help): Exclude params from
345 all except --help=param.
347 2020-01-27 Martin Liska <mliska@suse.cz>
350 * config/i386/i386-features.c (make_resolver_func):
351 Align the code with ppc64 target implementation.
352 Do not generate a unique name for resolver function.
354 2020-01-27 Richard Biener <rguenther@suse.de>
356 PR tree-optimization/93397
357 * tree-vect-slp.c (vect_analyze_slp_instance): Delay
358 converted reduction chain SLP graph adjustment.
360 2020-01-26 Marek Polacek <polacek@redhat.com>
363 * sanopt.c (sanitize_rewrite_addressable_params): Avoid crash on
366 2020-01-26 Jason Merrill <jason@redhat.com>
369 * tree.c (verify_type_variant): Only verify TYPE_NEEDS_CONSTRUCTING
372 2020-01-26 Darius Galis <darius.galis@cyberthorstudios.com>
374 * config/rx/rx.md (setmemsi): Added rx_allow_string_insns constraint
375 (rx_setmem): Likewise.
377 2020-01-26 Jakub Jelinek <jakub@redhat.com>
380 * config/i386/i386.md (*addv<dwi>4_doubleword, *subv<dwi>4_doubleword):
381 Use nonimmediate_operand instead of x86_64_hilo_general_operand and
382 drop <di> from constraint of last operand.
385 * config/i386/sse.md (*avx_vperm_broadcast_<mode>): Disallow for
386 TARGET_AVX2 and V4DFmode not in the split condition, but in the
387 pattern condition, though allow { 0, 0, 0, 0 } broadcast always.
389 2020-01-25 Feng Xue <fxue@os.amperecomputing.com>
392 * ipa-cp.c (get_info_about_necessary_edges): Remove value
395 2020-01-24 Jeff Law <law@redhat.com>
397 PR tree-optimization/92788
398 * tree-ssa-threadedge.c (thread_across_edge): Check EDGE_COMPLEX
401 2020-01-24 Jakub Jelinek <jakub@redhat.com>
404 * config/i386/sse.md (*avx_vperm_broadcast_v4sf,
405 *avx_vperm_broadcast_<mode>,
406 <sse2_avx_avx512f>_vpermil<mode><mask_name>,
407 *<sse2_avx_avx512f>_vpermilp<mode><mask_name>):
408 Move before avx2_perm<mode>/avx512f_perm<mode>.
411 * simplify-rtx.c (simplify_const_unary_operation,
412 simplify_const_binary_operation): Punt for mode precision above
413 MAX_BITSIZE_MODE_ANY_INT.
415 2020-01-24 Andrew Pinski <apinski@marvell.com>
417 * config/arm/aarch-cost-tables.h (cortexa57_extra_costs): Change
420 2020-01-24 Jeff Law <law@redhat.com>
423 * config/h8300/h8300.c (h8300_print_operand): Only call byte_reg
424 for REGs. Call output_operand_lossage to get more reasonable
427 2020-01-24 Andrew Stubbs <ams@codesourcery.com>
429 * config/gcn/gcn-valu.md (vec_cmp<mode>di): Use
430 gcn_fp_compare_operator.
431 (vec_cmpu<mode>di): Use gcn_compare_operator.
432 (vec_cmp<u>v64qidi): Use gcn_compare_operator.
433 (vec_cmp<mode>di_exec): Use gcn_fp_compare_operator.
434 (vec_cmpu<mode>di_exec): Use gcn_compare_operator.
435 (vec_cmp<u>v64qidi_exec): Use gcn_compare_operator.
436 (vec_cmp<mode>di_dup): Use gcn_fp_compare_operator.
437 (vec_cmp<mode>di_dup_exec): Use gcn_fp_compare_operator.
438 (vcond<VEC_ALLREG_MODE:mode><VEC_ALLREG_ALT:mode>): Use
439 gcn_fp_compare_operator.
440 (vcond<VEC_ALLREG_MODE:mode><VEC_ALLREG_ALT:mode>_exec): Use
441 gcn_fp_compare_operator.
442 (vcondu<VEC_ALLREG_MODE:mode><VEC_ALLREG_INT_MODE:mode>): Use
443 gcn_fp_compare_operator.
444 (vcondu<VEC_ALLREG_MODE:mode><VEC_ALLREG_INT_MODE:mode>_exec): Use
445 gcn_fp_compare_operator.
447 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
449 * doc/install.texi (Cross-Compiler-Specific Options): Document
450 `--with-toolexeclibdir' option.
452 2020-01-24 Hans-Peter Nilsson <hp@axis.com>
454 * target.def (flags_regnum): Also mention effect on delay slot filling.
455 * doc/tm.texi: Regenerate.
457 2020-01-23 Jeff Law <law@redhat.com>
460 * config/h8300/h8300.c (h8300_option_override): Fix diagnostic text.
462 2020-01-23 Mikael Tillenius <mti-1@tillenius.com>
465 * config/h8300/h8300.h (FUNCTION_PROFILER): Fix emission of
468 2020-01-23 Jakub Jelinek <jakub@redhat.com>
470 PR rtl-optimization/93402
471 * postreload.c (reload_combine_recognize_pattern): Don't try to adjust
474 2020-01-23 Dragan Mladjenovic <dmladjenovic@wavecomp.com>
476 * config.in: Regenerated.
477 * config/mips/linux.h (NEED_INDICATE_EXEC_STACK): Define to 1
478 for TARGET_LIBC_GNUSTACK.
479 * configure: Regenerated.
480 * configure.ac: Define TARGET_LIBC_GNUSTACK if glibc version is
481 found to be 2.31 or greater.
483 2020-01-23 Dragan Mladjenovic <dmladjenovic@wavecomp.com>
485 * config/mips/linux.h (NEED_INDICATE_EXEC_STACK): Define to
487 * config/mips/mips.c (TARGET_ASM_FILE_END): Define to ...
488 (mips_asm_file_end): New function. Delegate to
489 file_end_indicate_exec_stack if NEED_INDICATE_EXEC_STACK is true.
490 * config/mips/mips.h (NEED_INDICATE_EXEC_STACK): Define to 0.
492 2020-01-23 Jakub Jelinek <jakub@redhat.com>
495 * config/i386/i386-modes.def (POImode): New mode.
496 (MAX_BITSIZE_MODE_ANY_INT): Change from 128 to 160.
497 * config/i386/i386.md (DPWI): New mode attribute.
498 (addv<mode>4, subv<mode>4): Use <DPWI> instead of <DWI>.
500 (QPWI): ... this. Use POI instead of OI for TImode.
501 (*addv<dwi>4_doubleword, *addv<dwi>4_doubleword_1,
502 *subv<dwi>4_doubleword, *subv<dwi>4_doubleword_1): Use <QPWI>
505 2020-01-23 Richard Sandiford <richard.sandiford@arm.com>
508 * config/aarch64/aarch64.md (UNSPEC_SPECULATION_TRACKER_REV): New
510 (speculation_tracker_rev): New pattern.
511 * config/aarch64/aarch64-speculation.cc (aarch64_do_track_speculation):
512 Use speculation_tracker_rev to track the inverse condition.
514 2020-01-23 Richard Biener <rguenther@suse.de>
516 PR tree-optimization/93381
517 * tree-ssa-sccvn.c (vn_walk_cb_data::push_partial_def): Take
518 alias-set of the def as argument and record the first one.
519 (vn_walk_cb_data::first_set): New member.
520 (vn_reference_lookup_3): Pass the alias-set of the current def
521 to push_partial_def. Fix alias-set used in the aggregate copy
523 (vn_reference_lookup): Consistently set *last_vuse_ptr.
524 * real.c (clear_significand_below): Fix out-of-bound access.
526 2020-01-23 Jakub Jelinek <jakub@redhat.com>
529 * config/i386/i386.md (*bmi2_bzhi_<mode>3_2, *bmi2_bzhi_<mode>3_3):
530 New define_insn patterns.
532 2020-01-23 Richard Sandiford <richard.sandiford@arm.com>
534 * doc/sourcebuild.texi (check-function-bodies): Add an
535 optional target/xfail selector.
537 2020-01-23 Richard Sandiford <richard.sandiford@arm.com>
539 PR rtl-optimization/93124
540 * auto-inc-dec.c (merge_in_block): Don't add auto inc/decs to
541 bare USE and CLOBBER insns.
543 2020-01-22 Andrew Pinski <apinski@marvell.com>
545 * config/arc/arc.c (output_short_suffix): Check insn for nullness.
547 2020-01-22 David Malcolm <dmalcolm@redhat.com>
550 * gdbinit.in (break-on-saved-diagnostic): Update for move of
551 diagnostic_manager into "ana" namespace.
552 * selftest-run-tests.c (selftest::run_tests): Update for move of
553 selftest::run_analyzer_selftests to
554 ana::selftest::run_analyzer_selftests.
556 2020-01-22 Richard Sandiford <richard.sandiford@arm.com>
558 * cfgexpand.c (union_stack_vars): Update the size.
560 2020-01-22 Richard Biener <rguenther@suse.de>
562 PR tree-optimization/93381
563 * tree-ssa-structalias.c (find_func_aliases): Assume offsetting
564 throughout, handle all conversions the same.
566 2020-01-22 Jakub Jelinek <jakub@redhat.com>
569 * config/aarch64/aarch64.c (aarch64_expand_subvti): Only use
570 gen_subdi3_compare1_imm if low_in2 satisfies aarch64_plus_immediate
571 predicate, not whenever it is CONST_INT. Otherwise, force_reg it.
572 Call force_reg on high_in2 unconditionally.
574 2020-01-22 Martin Liska <mliska@suse.cz>
576 PR tree-optimization/92924
577 * profile.c (compute_value_histograms): Divide
580 2020-01-22 Jakub Jelinek <jakub@redhat.com>
583 * output.h (assemble_name_resolve): Declare.
584 * varasm.c (assemble_name_resolve): New function.
585 (assemble_name): Use it.
586 * config/i386/i386.h (ASM_OUTPUT_SYMBOL_REF): Define.
588 2020-01-22 Joseph Myers <joseph@codesourcery.com>
590 * doc/sourcebuild.texi (Texinfo Manuals, Front End): Refer to
591 update_web_docs_git instead of update_web_docs_svn.
593 2020-01-21 Andrew Pinski <apinski@marvell.com>
596 * config/aarch64/aarch64.md (tlsgd_small_<mode>): Have operand 0
597 as PTR mode. Have operand 1 as being modeless, it can be P mode.
598 (*tlsgd_small_<mode>): Likewise.
599 * config/aarch64/aarch64.c (aarch64_load_symref_appropriately)
600 <case SYMBOL_SMALL_TLSGD>: Call gen_tlsgd_small_* with a ptr_mode
601 register. Convert that register back to dest using convert_mode.
603 2020-01-21 Jim Wilson <jimw@sifive.com>
605 * config/riscv/riscv-sr.c (riscv_sr_match_prologue): Use INTVAL
608 2020-01-21 H.J. Lu <hongjiu.lu@intel.com>
609 Uros Bizjak <ubizjak@gmail.com>
612 * config/i386/i386.c (ix86_tls_module_base): Replace Pmode
614 (legitimize_tls_address): Do GNU2 TLS address computation in
615 ptr_mode and zero-extend result to Pmode.
616 * config/i386/i386.md (@tls_dynamic_gnu2_64_<mode>): Replace
617 :P with :PTR and Pmode with ptr_mode.
618 (*tls_dynamic_gnu2_lea_64_<mode>): Likewise.
619 (*tls_dynamic_gnu2_call_64_<mode>): Likewise.
620 (*tls_dynamic_gnu2_combine_64_<mode>): Likewise.
622 2020-01-21 Jakub Jelinek <jakub@redhat.com>
625 * config/riscv/riscv.c (riscv_rtx_costs) <case ZERO_EXTRACT>: Verify
626 the last two operands are CONST_INT_P before using them as such.
628 2020-01-21 Richard Sandiford <richard.sandiford@arm.com>
630 * config/aarch64/aarch64-sve-builtins.def: Use get_typenode_from_name
631 to get the integer element types.
633 2020-01-21 Richard Sandiford <richard.sandiford@arm.com>
635 * config/aarch64/aarch64-sve-builtins.h
636 (function_expander::convert_to_pmode): Declare.
637 * config/aarch64/aarch64-sve-builtins.cc
638 (function_expander::convert_to_pmode): New function.
639 (function_expander::get_contiguous_base): Use it.
640 (function_expander::prepare_gather_address_operands): Likewise.
641 * config/aarch64/aarch64-sve-builtins-sve2.cc
642 (svwhilerw_svwhilewr_impl::expand): Likewise.
644 2020-01-21 Szabolcs Nagy <szabolcs.nagy@arm.com>
647 * config/aarch64/aarch64.c (aarch64_declare_function_name): Set
648 cfun->machine->label_is_assembled.
649 (aarch64_print_patchable_function_entry): New.
650 (TARGET_ASM_PRINT_PATCHABLE_FUNCTION_ENTRY): Define.
651 * config/aarch64/aarch64.h (struct machine_function): New field,
654 2020-01-21 David Malcolm <dmalcolm@redhat.com>
657 * ipa-profile.c (ipa_profile): Delete call_sums and set it to
660 2020-01-18 Jan Hubicka <hubicka@ucw.cz>
663 * cgraph.c (cgraph_edge::resolve_speculation,
664 cgraph_edge::redirect_call_stmt_to_callee): Fix update of
667 2020-01-21 Martin Liska <mliska@suse.cz>
669 * config/rs6000/rs6000.c (common_mode_defined): Remove
672 2020-01-21 Richard Biener <rguenther@suse.de>
674 PR tree-optimization/92328
675 * tree-ssa-sccvn.c (vn_reference_lookup_3): Preserve
676 type when value-numbering same-sized store by inserting a
678 (eliminate_dom_walker::eliminate_stmt): When eliminating
679 a redundant store handle bit-reinterpretation of the same value.
681 2020-01-21 Andrew Pinski <apinski@marvel.com>
684 * tree-into-ssa.c (prepare_block_for_update_1): Split out
686 (prepare_block_for_update): This. Use a worklist instead of
689 2020-01-21 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
691 * gcc/config/arm/arm.c (clear_operation_p):
692 Initialise last_regno, skip first iteration
693 based on the first_set value and use ints instead
694 of the unnecessary HOST_WIDE_INTs.
696 2020-01-21 Jakub Jelinek <jakub@redhat.com>
699 * config/rs6000/rs6000.c (rs6000_emit_cmove): If using fsel, punt for
700 compare_mode other than SFmode or DFmode.
702 2020-01-21 Kito Cheng <kito.cheng@sifive.com>
705 * config/riscv/riscv-protos.h (riscv_hard_regno_rename_ok): New.
706 * config/riscv/riscv.c (riscv_hard_regno_rename_ok): New.
707 * config/riscv/riscv.h (HARD_REGNO_RENAME_OK): Defined.
709 2020-01-20 Wilco Dijkstra <wdijkstr@arm.com>
711 * config/aarch64/aarch64.c (neoversen1_tunings): Set jump_align to 4.
713 2020-01-20 Andrew Pinski <apinski@marvell.com>
716 * targhooks.c (default_print_patchable_function_entry): Use
717 output_asm_insn to emit the nop instruction.
719 2020-01-20 Fangrui Song <maskray@google.com>
722 * targhooks.c (default_print_patchable_function_entry): Align to
725 2020-01-20 H.J. Lu <hongjiu.lu@intel.com>
728 * config/i386/i386.c (legitimize_tls_address): Pass Pmode to
729 gen_tls_dynamic_gnu2_64. Compute GNU2 TLS address in ptr_mode.
730 * config/i386/i386.md (tls_dynamic_gnu2_64): Renamed to ...
731 (@tls_dynamic_gnu2_64_<mode>): This. Replace DI with P.
732 (*tls_dynamic_gnu2_lea_64): Renamed to ...
733 (*tls_dynamic_gnu2_lea_64_<mode>): This. Replace DI with P.
734 Remove the {q} suffix from lea.
735 (*tls_dynamic_gnu2_call_64): Renamed to ...
736 (*tls_dynamic_gnu2_call_64_<mode>): This. Replace DI with P.
737 (*tls_dynamic_gnu2_combine_64): Renamed to ...
738 (*tls_dynamic_gnu2_combine_64_<mode>): This. Replace DI with P.
739 Pass Pmode to gen_tls_dynamic_gnu2_64.
741 2020-01-20 Wilco Dijkstra <wdijkstr@arm.com>
743 * config/aarch64/aarch64.h (SLOW_BYTE_ACCESS): Set to 1.
745 2020-01-20 Richard Sandiford <richard.sandiford@arm.com>
747 * config/aarch64/aarch64-sve-builtins-base.cc
748 (svld1ro_impl::memory_vector_mode): Remove parameter name.
750 2020-01-20 Richard Biener <rguenther@suse.de>
753 * dwarf2out.c (prune_unused_types): Unconditionally mark
754 called function DIEs.
756 2020-01-20 Martin Liska <mliska@suse.cz>
758 PR tree-optimization/93199
759 * tree-eh.c (struct leh_state): Add
760 new field outer_non_cleanup.
761 (cleanup_is_dead_in): Pass leh_state instead
762 of eh_region. Add a checking that state->outer_non_cleanup
763 points to outer non-clean up region.
764 (lower_try_finally): Record outer_non_cleanup
766 (lower_catch): Likewise.
767 (lower_eh_filter): Likewise.
768 (lower_eh_must_not_throw): Likewise.
769 (lower_cleanup): Likewise.
771 2020-01-20 Richard Biener <rguenther@suse.de>
773 PR tree-optimization/93094
774 * tree-vectorizer.h (vect_loop_versioning): Adjust.
775 (vect_transform_loop): Likewise.
776 * tree-vectorizer.c (try_vectorize_loop_1): Pass down
777 loop_vectorized_call to vect_transform_loop.
778 * tree-vect-loop.c (vect_transform_loop): Pass down
779 loop_vectorized_call to vect_loop_versioning.
780 * tree-vect-loop-manip.c (vect_loop_versioning): Use
781 the earlier discovered loop_vectorized_call.
783 2020-01-19 Eric S. Raymond <esr@thyrsus.com>
785 * doc/contribute.texi: Update for SVN -> Git transition.
786 * doc/install.texi: Likewise.
788 2020-01-18 Jan Hubicka <hubicka@ucw.cz>
791 * cgraph.c (cgraph_edge::make_speculative): Increase number of
793 (verify_speculative_call): New function
794 (cgraph_node::verify_node): Use it.
795 * ipa-profile.c (ipa_profile): Fix formating; do not set number of
798 2020-01-18 Jan Hubicka <hubicka@ucw.cz>
801 * cgraph.c (cgraph_edge::resolve_speculation): Fix foramting.
802 (cgraph_edge::make_direct): Remove all indirect targets.
803 (cgraph_edge::redirect_call_stmt_to_callee): Use make_direct..
804 (cgraph_node::verify_node): Verify that only one call_stmt or
806 * cgraphclones.c (cgraph_edge::clone): Set only one call_stmt or
808 * lto-cgraph.c (lto_output_edge): Simplify streaming of stmt.
809 (lto_output_ref): Simplify streaming of stmt.
810 * lto-streamer-in.c (fixup_call_stmt_edges_1): Clear lto_stmt_uid.
812 2020-01-18 Tamar Christina <tamar.christina@arm.com>
814 * config/aarch64/aarch64-sve-builtins-base.cc (memory_vector_mode):
815 Mark parameter unused.
817 2020-01-18 Hans-Peter Nilsson <hp@axis.com>
819 * config.gcc <obsolete targets>: Add crisv32-*-* and cris-*-linux*
821 2019-01-18 Gerald Pfeifer <gerald@pfeifer.com>
823 * varpool.c (ctor_useable_for_folding_p): Fix grammar.
825 2020-01-18 Iain Sandoe <iain@sandoe.co.uk>
827 * Makefile.in: Add coroutine-passes.o.
828 * builtin-types.def (BT_CONST_SIZE): New.
829 (BT_FN_BOOL_PTR): New.
830 (BT_FN_PTR_PTR_CONST_SIZE_BOOL): New.
831 * builtins.def (DEF_COROUTINE_BUILTIN): New.
832 * coroutine-builtins.def: New file.
833 * coroutine-passes.cc: New file.
834 * function.h (struct GTY function): Add a bit to indicate that the
835 function is a coroutine component.
836 * internal-fn.c (expand_CO_FRAME): New.
837 (expand_CO_YIELD): New.
838 (expand_CO_SUSPN): New.
839 (expand_CO_ACTOR): New.
840 * internal-fn.def (CO_ACTOR): New.
844 * passes.def: Add pass_coroutine_lower_builtins,
845 pass_coroutine_early_expand_ifns.
846 * tree-pass.h (make_pass_coroutine_lower_builtins): New.
847 (make_pass_coroutine_early_expand_ifns): New.
848 * doc/invoke.texi: Document the fcoroutines command line
851 2020-01-18 Jakub Jelinek <jakub@redhat.com>
853 * config/arm/vfp.md (*clear_vfp_multiple): Remove unused variable.
856 * config/arm/arm.c (clear_operation_p): Don't use REGNO until
857 after checking the argument is a REG. Don't use REGNO (reg)
858 again to set last_regno, reuse regno variable instead.
860 2020-01-17 David Malcolm <dmalcolm@redhat.com>
862 * doc/analyzer.texi (Limitations): Add note about NaN.
864 2020-01-17 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
865 Sudakshina Das <sudi.das@arm.com>
867 * config/arm/arm.md (ashldi3): Generate thumb2_lsll for both reg
869 (ashrdi3): Generate thumb2_asrl for both reg and valid immediate.
870 (lshrdi3): Generate thumb2_lsrl for valid immediates.
871 * config/arm/constraints.md (Pg): New.
872 * config/arm/predicates.md (long_shift_imm): New.
873 (arm_reg_or_long_shift_imm): Likewise.
874 * config/arm/thumb2.md (thumb2_asrl): New immediate alternative.
875 (thumb2_lsll): Likewise.
878 2020-01-17 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
879 Sudakshina Das <sudi.das@arm.com>
881 * config/arm/arm.md (ashldi3): Generate thumb2_lsll for TARGET_HAVE_MVE.
882 (ashrdi3): Generate thumb2_asrl for TARGET_HAVE_MVE.
883 * config/arm/arm.c (arm_hard_regno_mode_ok): Allocate even odd
884 register pairs for doubleword quantities for ARMv8.1M-Mainline.
885 * config/arm/thumb2.md (thumb2_asrl): New.
886 (thumb2_lsll): Likewise.
888 2020-01-17 Jakub Jelinek <jakub@redhat.com>
890 * config/arm/arm.c (cmse_nonsecure_call_inline_register_clear): Remove
893 2020-01-17 Alexander Monakov <amonakov@ispras.ru>
895 * gdbinit.in (help-gcc-hooks): New command.
896 (pp, pr, prl, pt, pct, pgg, pgq, pgs, pge, pmz, ptc, pdn, ptn, pdd, prc,
897 pi, pbm, pel, trt): Take $arg0 instead of $ if supplied. Update
900 2020-01-17 Matthew Malcomson <matthew.malcomson@arm.com>
902 * config/aarch64/aarch64-sve.md (@aarch64_sve_ld1ro<mode>): Use the
903 correct target macro.
905 2020-01-17 Matthew Malcomson <matthew.malcomson@arm.com>
907 * config/aarch64/aarch64-protos.h
908 (aarch64_sve_ld1ro_operand_p): New.
909 * config/aarch64/aarch64-sve-builtins-base.cc
910 (class load_replicate): New.
911 (class svld1ro_impl): New.
912 (class svld1rq_impl): Change to inherit from load_replicate.
913 (svld1ro): New sve intrinsic function base.
914 * config/aarch64/aarch64-sve-builtins-base.def (svld1ro):
915 New DEF_SVE_FUNCTION.
916 * config/aarch64/aarch64-sve-builtins-base.h
918 * config/aarch64/aarch64-sve-builtins.cc
919 (function_expander::add_mem_operand): Modify assert to allow
921 * config/aarch64/aarch64-sve.md (@aarch64_sve_ld1ro<mode>): New
923 * config/aarch64/aarch64.c
924 (aarch64_sve_ld1rq_operand_p): Implement in terms of ...
925 (aarch64_sve_ld1rq_ld1ro_operand_p): This.
926 (aarch64_sve_ld1ro_operand_p): New.
927 * config/aarch64/aarch64.md (UNSPEC_LD1RO): New unspec.
928 * config/aarch64/constraints.md (UOb,UOh,UOw,UOd): New.
929 * config/aarch64/predicates.md
930 (aarch64_sve_ld1ro_operand_{b,h,w,d}): New.
932 2020-01-17 Matthew Malcomson <matthew.malcomson@arm.com>
934 * config/aarch64/aarch64-c.c (_ARM_FEATURE_MATMUL_FLOAT64):
935 Introduce this ACLE specified predefined macro.
936 * config/aarch64/aarch64-option-extensions.def (f64mm): New.
937 (fp): Disabling this disables f64mm.
938 (simd): Disabling this disables f64mm.
939 (fp16): Disabling this disables f64mm.
940 (sve): Disabling this disables f64mm.
941 * config/aarch64/aarch64.h (AARCH64_FL_F64MM): New.
942 (AARCH64_ISA_F64MM): New.
944 * doc/invoke.texi (f64mm): Document new option.
946 2020-01-17 Wilco Dijkstra <wdijkstr@arm.com>
948 * config/aarch64/aarch64.c (generic_tunings): Add branch fusion.
949 (neoversen1_tunings): Likewise.
951 2020-01-17 Wilco Dijkstra <wdijkstr@arm.com>
954 * config/aarch64/aarch64.c (aarch64_split_compare_and_swap)
955 Add assert to ensure prolog has been emitted.
956 (aarch64_split_atomic_op): Likewise.
957 * config/aarch64/atomics.md (aarch64_compare_and_swap<mode>)
958 Use epilogue_completed rather than reload_completed.
959 (aarch64_atomic_exchange<mode>): Likewise.
960 (aarch64_atomic_<atomic_optab><mode>): Likewise.
961 (atomic_nand<mode>): Likewise.
962 (aarch64_atomic_fetch_<atomic_optab><mode>): Likewise.
963 (atomic_fetch_nand<mode>): Likewise.
964 (aarch64_atomic_<atomic_optab>_fetch<mode>): Likewise.
965 (atomic_nand_fetch<mode>): Likewise.
967 2020-01-17 Richard Sandiford <richard.sandiford@arm.com>
970 * config/aarch64/aarch64.h (REVERSIBLE_CC_MODE): Return false
972 (REVERSE_CONDITION): Delete.
973 * config/aarch64/iterators.md (CC_ONLY): New mode iterator.
974 (CCFP_CCFPE): Likewise.
975 (e): New mode attribute.
976 * config/aarch64/aarch64.md (ccmp<GPI:mode>): Rename to...
977 (@ccmp<CC_ONLY:mode><GPI:mode>): ...this, using CC_ONLY instead of CC.
978 (fccmp<GPF:mode>, fccmpe<GPF:mode>): Merge into...
979 (@ccmp<CCFP_CCFPE:mode><GPF:mode>): ...this combined pattern.
980 (@ccmp<CC_ONLY:mode><GPI:mode>_rev): New pattern.
981 (@ccmp<CCFP_CCFPE:mode><GPF:mode>_rev): Likewise.
982 * config/aarch64/aarch64.c (aarch64_gen_compare_reg): Update
983 name of generator from gen_ccmpdi to gen_ccmpccdi.
984 (aarch64_gen_ccmp_next): Use code_for_ccmp. If we want to reverse
985 the previous comparison but aren't able to, use the new ccmp_rev
988 2020-01-17 Richard Sandiford <richard.sandiford@arm.com>
990 * gimplify.c (gimplify_return_expr): Use poly_int_tree_p rather
991 than testing directly for INTEGER_CST.
992 (gimplify_target_expr, gimplify_omp_depend): Likewise.
994 2020-01-17 Jakub Jelinek <jakub@redhat.com>
996 PR tree-optimization/93292
997 * tree-vect-stmts.c (vectorizable_comparison): Punt also if
998 get_vectype_for_scalar_type returns NULL.
1000 2020-01-16 Jan Hubicka <hubicka@ucw.cz>
1002 * params.opt (-param=max-predicted-iterations): Increase range from 0.
1003 * predict.c (estimate_loops): Add 1 to param_max_predicted_iterations.
1005 2020-01-16 Jan Hubicka <hubicka@ucw.cz>
1007 * ipa-fnsummary.c (estimate_calls_size_and_time): Fix formating of
1009 * params.opt: (max-predicted-iterations): Set bounds.
1010 * predict.c (real_almost_one, real_br_prob_base,
1011 real_inv_br_prob_base, real_one_half, real_bb_freq_max): Remove.
1012 (propagate_freq): Add max_cyclic_prob parameter; cap cyclic
1013 probabilities; do not truncate to reg_br_prob_bases.
1014 (estimate_loops_at_level): Pass max_cyclic_prob.
1015 (estimate_loops): Compute max_cyclic_prob.
1016 (estimate_bb_frequencies): Do not initialize real_*; update calculation
1018 * profile-count.c (profile_probability::to_sreal): New.
1019 * profile-count.h (class sreal): Move up in file.
1020 (profile_probability::to_sreal): Declare.
1022 2020-01-16 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1025 (arm_invalid_conversion): New function for target hook.
1026 (arm_invalid_unary_op): New function for target hook.
1027 (arm_invalid_binary_op): New function for target hook.
1029 2020-01-16 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1031 * config.gcc: Add arm_bf16.h.
1032 * config/arm/arm-builtins.c (arm_mangle_builtin_type): Fix comment.
1033 (arm_simd_builtin_std_type): Add BFmode.
1034 (arm_init_simd_builtin_types): Define element types for vector types.
1035 (arm_init_bf16_types): New function.
1036 (arm_init_builtins): Add arm_init_bf16_types function call.
1037 * config/arm/arm-modes.def: Add BFmode and V4BF, V8BF vector modes.
1038 * config/arm/arm-simd-builtin-types.def: Add V4BF, V8BF.
1039 * config/arm/arm.c (aapcs_vfp_sub_candidate): Add BFmode.
1040 (arm_hard_regno_mode_ok): Add BFmode and tidy up statements.
1041 (arm_vector_mode_supported_p): Add V4BF, V8BF.
1042 (arm_mangle_type): Add __bf16.
1043 * config/arm/arm.h: Add V4BF, V8BF to VALID_NEON_DREG_MODE,
1044 VALID_NEON_QREG_MODE respectively. Add export arm_bf16_type_node,
1045 arm_bf16_ptr_type_node.
1046 * config/arm/arm.md: Add BFmode to movhf expand, mov pattern and
1047 define_split between ARM registers.
1048 * config/arm/arm_bf16.h: New file.
1049 * config/arm/arm_neon.h: Add arm_bf16.h and Bfloat vector types.
1050 * config/arm/iterators.md: (ANY64_BF, VDXMOV, VHFBF, HFBF, fporbf): New.
1052 * config/arm/neon.md: Add BF vector types to movhf NEON move patterns.
1053 * config/arm/vfp.md: Add BFmode to movhf patterns.
1055 2020-01-16 Mihail Ionescu <mihail.ionescu@arm.com>
1056 Andre Vieira <andre.simoesdiasvieira@arm.com>
1058 * config/arm/arm-cpus.in (mve, mve_float): New features.
1059 (dsp, mve, mve.fp): New options.
1060 * config/arm/arm.h (TARGET_HAVE_MVE, TARGET_HAVE_MVE_FLOAT): Define.
1061 * config/arm/t-rmprofile: Map v8.1-M multilibs to v8-M.
1062 * doc/invoke.texi: Document the armv8.1-m mve and dps options.
1064 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1065 Thomas Preud'homme <thomas.preudhomme@arm.com>
1067 * config/arm/arm-cpus.in (ARMv8_1m_main): Redefine as an extension to
1069 * config/arm/arm.c (arm_options_perform_arch_sanity_checks): Remove
1070 error for using -mcmse when targeting Armv8.1-M Mainline.
1072 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1073 Thomas Preud'homme <thomas.preudhomme@arm.com>
1075 * config/arm/arm.md (nonsecure_call_internal): Do not force memory
1076 address in r4 when targeting Armv8.1-M Mainline.
1077 (nonsecure_call_value_internal): Likewise.
1078 * config/arm/thumb2.md (nonsecure_call_reg_thumb2): Make memory address
1079 a register match_operand again. Emit BLXNS when targeting
1081 (nonsecure_call_value_reg_thumb2): Likewise.
1083 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1084 Thomas Preud'homme <thomas.preudhomme@arm.com>
1086 * config/arm/arm.c (arm_add_cfa_adjust_cfa_note): Declare early.
1087 (cmse_nonsecure_call_inline_register_clear): Define new lazy_fpclear
1088 variable as true when floating-point ABI is not hard. Replace
1089 check against TARGET_HARD_FLOAT_ABI by checks against lazy_fpclear.
1090 Generate VLSTM and VLLDM instruction respectively before and
1091 after a function call to cmse_nonsecure_call function.
1092 * config/arm/unspecs.md (VUNSPEC_VLSTM): Define unspec.
1093 (VUNSPEC_VLLDM): Likewise.
1094 * config/arm/vfp.md (lazy_store_multiple_insn): New define_insn.
1095 (lazy_load_multiple_insn): Likewise.
1097 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1098 Thomas Preud'homme <thomas.preudhomme@arm.com>
1100 * config/arm/arm.c (vfp_emit_fstmd): Declare early.
1101 (arm_emit_vfp_multi_reg_pop): Likewise.
1102 (cmse_nonsecure_call_inline_register_clear): Abstract number of VFP
1103 registers to clear in max_fp_regno. Emit VPUSH and VPOP to save and
1104 restore callee-saved VFP registers.
1106 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1107 Thomas Preud'homme <thomas.preudhomme@arm.com>
1109 * config/arm/arm.c (arm_emit_multi_reg_pop): Declare early.
1110 (cmse_nonsecure_call_clear_caller_saved): Rename into ...
1111 (cmse_nonsecure_call_inline_register_clear): This. Save and clear
1112 callee-saved GPRs as well as clear ip register before doing a nonsecure
1113 call then restore callee-saved GPRs after it when targeting
1115 (arm_reorg): Adapt to function rename.
1117 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1118 Thomas Preud'homme <thomas.preudhomme@arm.com>
1120 * config/arm/arm-protos.h (clear_operation_p): Adapt prototype.
1121 * config/arm/arm.c (clear_operation_p): Extend to be able to check a
1122 clear_vfp_multiple pattern based on a new vfp parameter.
1123 (cmse_clear_registers): Generate VSCCLRM to clear VFP registers when
1124 targeting Armv8.1-M Mainline.
1125 (cmse_nonsecure_entry_clear_before_return): Clear VFP registers
1126 unconditionally when targeting Armv8.1-M Mainline architecture. Check
1127 whether VFP registers are available before looking call_used_regs for a
1129 * config/arm/predicates.md (clear_multiple_operation): Adapt to change
1130 of prototype of clear_operation_p.
1131 (clear_vfp_multiple_operation): New predicate.
1132 * config/arm/unspecs.md (VUNSPEC_VSCCLRM_VPR): New volatile unspec.
1133 * config/arm/vfp.md (clear_vfp_multiple): New define_insn.
1135 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1136 Thomas Preud'homme <thomas.preudhomme@arm.com>
1138 * config/arm/arm-protos.h (clear_operation_p): Declare.
1139 * config/arm/arm.c (clear_operation_p): New function.
1140 (cmse_clear_registers): Generate clear_multiple instruction pattern if
1141 targeting Armv8.1-M Mainline or successor.
1142 (output_return_instruction): Only output APSR register clearing if
1143 Armv8.1-M Mainline instructions not available.
1144 (thumb_exit): Likewise.
1145 * config/arm/predicates.md (clear_multiple_operation): New predicate.
1146 * config/arm/thumb2.md (clear_apsr): New define_insn.
1147 (clear_multiple): Likewise.
1148 * config/arm/unspecs.md (VUNSPEC_CLRM_APSR): New volatile unspec.
1150 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1151 Thomas Preud'homme <thomas.preudhomme@arm.com>
1153 * config/arm/arm.c (fp_sysreg_names): Declare and define.
1154 (use_return_insn): Also return false for Armv8.1-M Mainline.
1155 (output_return_instruction): Skip FPSCR clearing if Armv8.1-M
1156 Mainline instructions are available.
1157 (arm_compute_frame_layout): Allocate space in frame for FPCXTNS
1158 when targeting Armv8.1-M Mainline Security Extensions.
1159 (arm_expand_prologue): Save FPCXTNS if this is an Armv8.1-M
1160 Mainline entry function.
1161 (cmse_nonsecure_entry_clear_before_return): Clear IP and r4 if
1162 targeting Armv8.1-M Mainline or successor.
1163 (arm_expand_epilogue): Fix indentation of caller-saved register
1164 clearing. Restore FPCXTNS if this is an Armv8.1-M Mainline
1166 * config/arm/arm.h (TARGET_HAVE_FP_CMSE): New macro.
1167 (FP_SYSREGS): Likewise.
1168 (enum vfp_sysregs_encoding): Define enum.
1169 (fp_sysreg_names): Declare.
1170 * config/arm/unspecs.md (VUNSPEC_VSTR_VLDR): New volatile unspec.
1171 * config/arm/vfp.md (push_fpsysreg_insn): New define_insn.
1172 (pop_fpsysreg_insn): Likewise.
1174 2020-01-16 Mihail-Calin Ionescu <mihail.ionescu@arm.com>
1175 Thomas Preud'homme <thomas.preudhomme@arm.com>
1177 * config/arm/arm-cpus.in (armv8_1m_main): New feature.
1178 (ARMv4, ARMv4t, ARMv5t, ARMv5te, ARMv5tej, ARMv6, ARMv6j, ARMv6k,
1179 ARMv6z, ARMv6kz, ARMv6zk, ARMv6t2, ARMv6m, ARMv7, ARMv7a, ARMv7ve,
1180 ARMv7r, ARMv7m, ARMv7em, ARMv8a, ARMv8_1a, ARMv8_2a, ARMv8_3a,
1181 ARMv8_4a, ARMv8_5a, ARMv8m_base, ARMv8m_main, ARMv8r): Reindent.
1182 (ARMv8_1m_main): New feature group.
1183 (armv8.1-m.main): New architecture.
1184 * config/arm/arm-tables.opt: Regenerate.
1185 * config/arm/arm.c (arm_arch8_1m_main): Define and default initialize.
1186 (arm_option_reconfigure_globals): Initialize arm_arch8_1m_main.
1187 (arm_options_perform_arch_sanity_checks): Error out when targeting
1188 Armv8.1-M Mainline Security Extensions.
1189 * config/arm/arm.h (arm_arch8_1m_main): Declare.
1191 2020-01-16 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1193 * config/aarch64/aarch64-simd-builtins.def (aarch64_bfdot,
1194 aarch64_bfdot_lane, aarch64_bfdot_laneq): New.
1195 * config/aarch64/aarch64-simd.md (aarch64_bfdot, aarch64_bfdot_lane,
1196 aarch64_bfdot_laneq): New.
1197 * config/aarch64/arm_bf16.h (vbfdot_f32, vbfdotq_f32,
1198 vbfdot_lane_f32, vbfdotq_lane_f32, vbfdot_laneq_f32,
1199 vbfdotq_laneq_f32): New.
1200 * config/aarch64/iterators.md (UNSPEC_BFDOT, Vbfdottype,
1201 VBFMLA_W, VBF): New.
1202 (isquadop): Add V4BF, V8BF.
1204 2020-01-16 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1206 * config/aarch64/aarch64-builtins.c: (enum aarch64_type_qualifiers):
1207 New qualifier_lane_quadtup_index, TYPES_TERNOP_SSUS,
1208 TYPES_QUADOPSSUS_LANE_QUADTUP, TYPES_QUADOPSSSU_LANE_QUADTUP.
1209 (aarch64_simd_expand_args): Add case SIMD_ARG_LANE_QUADTUP_INDEX.
1210 (aarch64_simd_expand_builtin): Add qualifier_lane_quadtup_index.
1211 * config/aarch64/aarch64-simd-builtins.def (usdot, usdot_lane,
1212 usdot_laneq, sudot_lane,sudot_laneq): New.
1213 * config/aarch64/aarch64-simd.md (aarch64_usdot): New.
1214 (aarch64_<sur>dot_lane): New.
1215 * config/aarch64/arm_neon.h (vusdot_s32): New.
1217 (vusdot_lane_s32): New.
1218 (vsudot_lane_s32): New.
1219 * config/aarch64/iterators.md (DOTPROD_I8MM): New iterator.
1220 (UNSPEC_USDOT, UNSPEC_SUDOT): New unspecs.
1222 2020-01-16 Martin Liska <mliska@suse.cz>
1224 * value-prof.c (dump_histogram_value): Fix
1225 obvious spacing issue.
1227 2020-01-16 Andrew Pinski <apinski@marvell.com>
1229 * tree-ssa-sccvn.c(vn_reference_lookup_3): Check lhs for
1230 !storage_order_barrier_p.
1232 2020-01-16 Andrew Pinski <apinski@marvell.com>
1234 * sched-int.h (_dep): Add unused bit-field field for the padding.
1235 * sched-deps.c (init_dep_1): Init unused field.
1237 2020-01-16 Andrew Pinski <apinski@marvell.com>
1239 * optabs.h (create_expand_operand): Initialize target field also.
1241 2020-01-16 Andre Vieira <andre.simoesdiasvieira@arm.com>
1243 PR tree-optimization/92429
1244 * tree-ssa-loop-niter.h (simplify_replace_tree): Add parameter.
1245 * tree-ssa-loop-niter.c (simplify_replace_tree): Add parameter to
1247 * tree-vect-loop.c (update_epilogue_vinfo): Do not fold when replacing
1250 2020-01-16 Richard Sandiford <richard.sandiford@arm.com>
1252 * config/aarch64/aarch64.c (aarch64_split_sve_subreg_move): Apply
1253 aarch64_sve_int_mode to each mode.
1255 2020-01-15 David Malcolm <dmalcolm@redhat.com>
1257 * doc/analyzer.texi (Overview): Add note about
1258 -fdump-ipa-analyzer.
1260 2020-01-15 Wilco Dijkstra <wdijkstr@arm.com>
1262 PR tree-optimization/93231
1263 * tree-ssa-forwprop.c (optimize_count_trailing_zeroes): Check
1264 input_type is unsigned. Use tree_to_shwi for shift constant.
1265 Check CST_STRING element size is CHAR_TYPE_SIZE bits.
1266 (simplify_count_trailing_zeroes): Add test to handle known non-zero
1267 inputs more efficiently.
1269 2020-01-15 Uroš Bizjak <ubizjak@gmail.com>
1271 * config/i386/i386.md (*movsf_internal): Do not require
1272 SSE2 ISA for alternatives 14 and 15.
1274 2020-01-15 Richard Biener <rguenther@suse.de>
1277 * tree-eh.c (sink_clobbers): If we already visited the destination
1278 block do not defer insertion.
1279 (pass_lower_eh_dispatch::execute): Maintain BB_VISITED for
1280 the purpose of defered insertion.
1282 2020-01-15 Jakub Jelinek <jakub@redhat.com>
1284 * BASE-VER: Bump to 10.0.1.
1286 2020-01-15 Richard Sandiford <richard.sandiford@arm.com>
1288 PR tree-optimization/93247
1289 * tree-vect-loop.c (update_epilogue_loop_vinfo): Check the access
1290 type of the stmt that we're going to vectorize.
1292 2020-01-15 Richard Sandiford <richard.sandiford@arm.com>
1294 * tree-vect-slp.c (vectorize_slp_instance_root_stmt): Use a
1295 VIEW_CONVERT_EXPR if the vectorized constructor has a diffeent
1298 2020-01-15 Martin Liska <mliska@suse.cz>
1300 * ipa-profile.c (ipa_profile_read_edge_summary): Do not allow
1301 2 calls of streamer_read_hwi in a function call.
1303 2020-01-15 Richard Biener <rguenther@suse.de>
1305 * alias.c (record_alias_subset): Avoid redundant work when
1306 subset is already recorded.
1308 2020-01-14 David Malcolm <dmalcolm@redhat.com>
1310 * doc/invoke.texi (-fdiagnostics-show-cwe): Add note that some of
1311 the analyzer options provide CWE identifiers.
1313 2020-01-14 David Malcolm <dmalcolm@redhat.com>
1315 * tree-diagnostic-path.cc (path_summary::event_range::print):
1316 When testing for UNKNOWN_LOCATION, look through ad-hoc wrappers
1317 using get_pure_location.
1319 2020-01-15 Jakub Jelinek <jakub@redhat.com>
1321 PR tree-optimization/93262
1322 * tree-ssa-dse.c (maybe_trim_memstar_call): For *_chk builtins,
1323 perform head trimming only if the last argument is constant,
1324 either all ones, or larger or equal to head trim, in the latter
1325 case decrease the last argument by head_trim.
1327 PR tree-optimization/93249
1328 * tree-ssa-dse.c: Include builtins.h and gimple-fold.h.
1329 (maybe_trim_memstar_call): Move head_trim and tail_trim vars to
1330 function body scope, reindent. For BUILTIN_IN_STRNCPY*, don't
1331 perform head trim unless we can prove there are no '\0' chars
1332 from the source among the first head_trim chars.
1334 2020-01-14 David Malcolm <dmalcolm@redhat.com>
1336 * Makefile.in (ANALYZER_OBJS): Add analyzer/function-set.o.
1338 2020-01-15 Jakub Jelinek <jakub@redhat.com>
1341 * config/i386/sse.md
1342 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1,
1343 *<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1,
1344 *<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1,
1345 *<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1): Use
1346 just a single alternative instead of two, make operands 1 and 2
1349 2020-01-14 Jan Hubicka <hubicka@ucw.cz>
1352 * ipa-devirt.c (odr_types_equivalent_p): Compare TREE_ADDRESSABLE and
1355 2020-01-14 David Malcolm <dmalcolm@redhat.com>
1357 * Makefile.in (lang_opt_files): Add analyzer.opt.
1358 (ANALYZER_OBJS): New.
1359 (OBJS): Add digraph.o, graphviz.o, ordered-hash-map-tests.o,
1360 tristate.o and ANALYZER_OBJS.
1361 (TEXI_GCCINT_FILES): Add analyzer.texi.
1362 * common.opt (-fanalyzer): New driver option.
1363 * config.in: Regenerate.
1364 * configure: Regenerate.
1365 * configure.ac (--disable-analyzer, ENABLE_ANALYZER): New option.
1366 (gccdepdir): Also create depdir for "analyzer" subdir.
1367 * digraph.cc: New file.
1368 * digraph.h: New file.
1369 * doc/analyzer.texi: New file.
1370 * doc/gccint.texi ("Static Analyzer") New menu item.
1371 (analyzer.texi): Include it.
1372 * doc/invoke.texi ("Static Analyzer Options"): New list and new section.
1373 ("Warning Options"): Add static analysis warnings to the list.
1374 (-Wno-analyzer-double-fclose): New option.
1375 (-Wno-analyzer-double-free): New option.
1376 (-Wno-analyzer-exposure-through-output-file): New option.
1377 (-Wno-analyzer-file-leak): New option.
1378 (-Wno-analyzer-free-of-non-heap): New option.
1379 (-Wno-analyzer-malloc-leak): New option.
1380 (-Wno-analyzer-possible-null-argument): New option.
1381 (-Wno-analyzer-possible-null-dereference): New option.
1382 (-Wno-analyzer-null-argument): New option.
1383 (-Wno-analyzer-null-dereference): New option.
1384 (-Wno-analyzer-stale-setjmp-buffer): New option.
1385 (-Wno-analyzer-tainted-array-index): New option.
1386 (-Wno-analyzer-use-after-free): New option.
1387 (-Wno-analyzer-use-of-pointer-in-stale-stack-frame): New option.
1388 (-Wno-analyzer-use-of-uninitialized-value): New option.
1389 (-Wanalyzer-too-complex): New option.
1390 (-fanalyzer-call-summaries): New warning.
1391 (-fanalyzer-checker=): New warning.
1392 (-fanalyzer-fine-grained): New warning.
1393 (-fno-analyzer-state-merge): New warning.
1394 (-fno-analyzer-state-purge): New warning.
1395 (-fanalyzer-transitivity): New warning.
1396 (-fanalyzer-verbose-edges): New warning.
1397 (-fanalyzer-verbose-state-changes): New warning.
1398 (-fanalyzer-verbosity=): New warning.
1399 (-fdump-analyzer): New warning.
1400 (-fdump-analyzer-callgraph): New warning.
1401 (-fdump-analyzer-exploded-graph): New warning.
1402 (-fdump-analyzer-exploded-nodes): New warning.
1403 (-fdump-analyzer-exploded-nodes-2): New warning.
1404 (-fdump-analyzer-exploded-nodes-3): New warning.
1405 (-fdump-analyzer-supergraph): New warning.
1406 * doc/sourcebuild.texi (dg-require-dot): New.
1407 (dg-check-dot): New.
1408 * gdbinit.in (break-on-saved-diagnostic): New command.
1409 * graphviz.cc: New file.
1410 * graphviz.h: New file.
1411 * ordered-hash-map-tests.cc: New file.
1412 * ordered-hash-map.h: New file.
1413 * passes.def (pass_analyzer): Add before
1414 pass_ipa_whole_program_visibility.
1415 * selftest-run-tests.c (selftest::run_tests): Call
1416 selftest::ordered_hash_map_tests_cc_tests.
1417 * selftest.h (selftest::ordered_hash_map_tests_cc_tests): New
1419 * shortest-paths.h: New file.
1420 * timevar.def (TV_ANALYZER): New timevar.
1421 (TV_ANALYZER_SUPERGRAPH): Likewise.
1422 (TV_ANALYZER_STATE_PURGE): Likewise.
1423 (TV_ANALYZER_PLAN): Likewise.
1424 (TV_ANALYZER_SCC): Likewise.
1425 (TV_ANALYZER_WORKLIST): Likewise.
1426 (TV_ANALYZER_DUMP): Likewise.
1427 (TV_ANALYZER_DIAGNOSTICS): Likewise.
1428 (TV_ANALYZER_SHORTEST_PATHS): Likewise.
1429 * tree-pass.h (make_pass_analyzer): New decl.
1430 * tristate.cc: New file.
1431 * tristate.h: New file.
1433 2020-01-14 Uroš Bizjak <ubizjak@gmail.com>
1436 * config/i386/i386.md (*movsf_internal): Require SSE2 ISA for
1437 alternatives 9 and 10.
1439 2020-01-14 David Malcolm <dmalcolm@redhat.com>
1441 * attribs.c (excl_hash_traits::empty_zero_p): New static constant.
1442 * gcov.c (function_start_pair_hash::empty_zero_p): Likewise.
1443 * graphite.c (struct sese_scev_hash::empty_zero_p): Likewise.
1444 * hash-map-tests.c (selftest::test_nonzero_empty_key): New selftest.
1445 (selftest::hash_map_tests_c_tests): Call it.
1446 * hash-map-traits.h (simple_hashmap_traits::empty_zero_p):
1447 New static constant, using the value of = H::empty_zero_p.
1448 (unbounded_hashmap_traits::empty_zero_p): Likewise, using the value
1449 from default_hash_traits <Value>.
1450 * hash-map.h (hash_map::empty_zero_p): Likewise, using the value
1452 * hash-set-tests.c (value_hash_traits::empty_zero_p): Likewise.
1453 * hash-table.h (hash_table::alloc_entries): Guard the loop of
1454 calls to mark_empty with !Descriptor::empty_zero_p.
1455 (hash_table::empty_slow): Conditionalize the memset call with a
1456 check that Descriptor::empty_zero_p; otherwise, loop through the
1457 entries calling mark_empty on them.
1458 * hash-traits.h (int_hash::empty_zero_p): New static constant.
1459 (pointer_hash::empty_zero_p): Likewise.
1460 (pair_hash::empty_zero_p): Likewise.
1461 * ipa-devirt.c (default_hash_traits <type_pair>::empty_zero_p):
1463 * ipa-prop.c (ipa_bit_ggc_hash_traits::empty_zero_p): Likewise.
1464 (ipa_vr_ggc_hash_traits::empty_zero_p): Likewise.
1465 * profile.c (location_triplet_hash::empty_zero_p): Likewise.
1466 * sanopt.c (sanopt_tree_triplet_hash::empty_zero_p): Likewise.
1467 (sanopt_tree_couple_hash::empty_zero_p): Likewise.
1468 * tree-hasher.h (int_tree_hasher::empty_zero_p): Likewise.
1469 * tree-ssa-sccvn.c (vn_ssa_aux_hasher::empty_zero_p): Likewise.
1470 * tree-vect-slp.c (bst_traits::empty_zero_p): Likewise.
1472 (default_hash_traits<scalar_cond_masked_key>::empty_zero_p):
1475 2020-01-14 Kewen Lin <linkw@gcc.gnu.org>
1477 * cfgloopanal.c (average_num_loop_insns): Free bbs when early return,
1478 fix typo on return value.
1480 2020-01-14 Xiong Hu Luo <luoxhu@linux.ibm.com>
1483 * cgraph.c (symbol_table::create_edge): Init speculative_id and
1485 (cgraph_edge::make_speculative): Add param for setting speculative_id
1487 (cgraph_edge::speculative_call_info): Update comments and find reference
1488 by speculative_id for multiple indirect targets.
1489 (cgraph_edge::resolve_speculation): Decrease the speculations
1490 for indirect edge, drop it's speculative if not direct target
1491 left. Update comments.
1492 (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
1493 (cgraph_node::dump): Print num_speculative_call_targets.
1494 (cgraph_node::verify_node): Don't report error if speculative
1495 edge not include statement.
1496 (cgraph_edge::num_speculative_call_targets_p): New function.
1497 * cgraph.h (int common_target_id): Remove.
1498 (int common_target_probability): Remove.
1499 (num_speculative_call_targets): New variable.
1500 (make_speculative): Add param for setting speculative_id.
1501 (cgraph_edge::num_speculative_call_targets_p): New declare.
1502 (target_prob): New variable.
1503 (speculative_id): New variable.
1504 * ipa-fnsummary.c (analyze_function_body): Create and duplicate
1505 call summaries for multiple speculative call targets.
1506 * cgraphclones.c (cgraph_node::create_clone): Clone speculative_id.
1507 * ipa-profile.c (struct speculative_call_target): New struct.
1508 (class speculative_call_summary): New class.
1509 (class speculative_call_summaries): New class.
1510 (call_sums): New variable.
1511 (ipa_profile_generate_summary): Generate indirect multiple targets summaries.
1512 (ipa_profile_write_edge_summary): New function.
1513 (ipa_profile_write_summary): Stream out indirect multiple targets summaries.
1514 (ipa_profile_dump_all_summaries): New function.
1515 (ipa_profile_read_edge_summary): New function.
1516 (ipa_profile_read_summary_section): New function.
1517 (ipa_profile_read_summary): Stream in indirect multiple targets summaries.
1518 (ipa_profile): Generate num_speculative_call_targets from
1520 * ipa-ref.h (speculative_id): New variable.
1521 * ipa-utils.c (ipa_merge_profiles): Update with target_prob.
1522 * lto-cgraph.c (lto_output_edge): Remove indirect common_target_id and
1523 common_target_probability. Stream out speculative_id and
1524 num_speculative_call_targets.
1525 (input_edge): Likewise.
1526 * predict.c (dump_prediction): Remove edges count assert to be
1528 * symtab.c (symtab_node::create_reference): Init speculative_id.
1529 (symtab_node::clone_references): Clone speculative_id.
1530 (symtab_node::clone_referring): Clone speculative_id.
1531 (symtab_node::clone_reference): Clone speculative_id.
1532 (symtab_node::clear_stmts_in_references): Clear speculative_id.
1533 * tree-inline.c (copy_bb): Duplicate all the speculative edges
1534 if indirect call contains multiple speculative targets.
1535 * value-prof.h (check_ic_target): Remove.
1536 * value-prof.c (gimple_value_profile_transformations):
1537 Use void function gimple_ic_transform.
1538 * value-prof.c (gimple_ic_transform): Handle topn case.
1539 Fix comment typos. Change it to a void function.
1541 2020-01-13 Andrew Pinski <apinski@marvell.com>
1543 * config/aarch64/aarch64-cores.def (octeontx2): New define.
1544 (octeontx2t98): New define.
1545 (octeontx2t96): New define.
1546 (octeontx2t93): New define.
1547 (octeontx2f95): New define.
1548 (octeontx2f95n): New define.
1549 (octeontx2f95mm): New define.
1550 * config/aarch64/aarch64-tune.md: Regenerate.
1551 * doc/invoke.texi (-mcpu=): Document the new cpu types.
1553 2020-01-13 Jason Merrill <jason@redhat.com>
1555 PR c++/33799 - destroy return value if local cleanup throws.
1556 * gimplify.c (gimplify_return_expr): Handle COMPOUND_EXPR.
1558 2020-01-13 Martin Liska <mliska@suse.cz>
1560 * ipa-cp.c (get_max_overall_size): Use newly
1561 renamed param param_ipa_cp_unit_growth.
1562 * params.opt: Remove legacy param name.
1564 2020-01-13 Martin Sebor <msebor@redhat.com>
1566 PR tree-optimization/93213
1567 * tree-ssa-strlen.c (handle_store): Only allow single-byte nul-over-nul
1568 stores to be eliminated.
1570 2020-01-13 Martin Liska <mliska@suse.cz>
1572 * opts.c (print_help): Do not print CL_PARAM
1573 and CL_WARNING for CL_OPTIMIZATION.
1575 2020-01-13 Jonathan Wakely <jwakely@redhat.com>
1578 * doc/invoke.texi (Warning Options): Add caveat about some warnings
1579 depending on optimization settings.
1581 2020-01-13 Jakub Jelinek <jakub@redhat.com>
1583 PR tree-optimization/90838
1584 * tree-ssa-forwprop.c (simplify_count_trailing_zeroes): Use
1585 SCALAR_INT_TYPE_MODE directly in CTZ_DEFINED_VALUE_AT_ZERO macro
1586 argument rather than to initialize temporary for targets that
1587 don't use the mode argument at all. Initialize ctzval to avoid
1590 2020-01-10 Thomas Schwinge <thomas@codesourcery.com>
1592 * tree.h (OMP_CLAUSE_USE_DEVICE_PTR_IF_PRESENT): New definition.
1593 * tree-core.h: Document it.
1594 * gimplify.c (gimplify_omp_workshare): Set it.
1595 * omp-low.c (lower_omp_target): Use it.
1596 * tree-pretty-print.c (dump_omp_clause): Print it.
1598 * omp-low.c (lower_omp_target) <OMP_CLAUSE_USE_DEVICE_PTR etc.>:
1599 Assert that for OpenACC we always have 'GOMP_MAP_USE_DEVICE_PTR'.
1601 2020-01-10 David Malcolm <dmalcolm@redhat.com>
1603 * Makefile.in (OBJS): Add tree-diagnostic-path.o.
1604 * common.opt (fdiagnostics-path-format=): New option.
1605 (diagnostic_path_format): New enum.
1606 (fdiagnostics-show-path-depths): New option.
1607 * coretypes.h (diagnostic_event_id_t): New forward decl.
1608 * diagnostic-color.c (color_dict): Add "path".
1609 * diagnostic-event-id.h: New file.
1610 * diagnostic-format-json.cc (json_from_expanded_location): Make
1612 (json_end_diagnostic): Call context->make_json_for_path if it
1613 exists and the diagnostic has a path.
1614 (diagnostic_output_format_init): Clear context->print_path.
1615 * diagnostic-path.h: New file.
1616 * diagnostic-show-locus.c (colorizer::set_range): Special-case
1617 when printing a run of events in a diagnostic_path so that they
1618 all get the same color.
1619 (layout::m_diagnostic_path_p): New field.
1620 (layout::layout): Initialize it.
1621 (layout::print_any_labels): Don't colorize the label text for an
1622 event in a diagnostic_path.
1623 (gcc_rich_location::add_location_if_nearby): Add
1624 "restrict_to_current_line_spans" and "label" params. Pass the
1625 former to layout.maybe_add_location_range; pass the latter
1626 when calling add_range.
1627 * diagnostic.c: Include "diagnostic-path.h".
1628 (diagnostic_initialize): Initialize context->path_format and
1629 context->show_path_depths.
1630 (diagnostic_show_any_path): New function.
1631 (diagnostic_path::interprocedural_p): New function.
1632 (diagnostic_report_diagnostic): Call diagnostic_show_any_path.
1633 (simple_diagnostic_path::num_events): New function.
1634 (simple_diagnostic_path::get_event): New function.
1635 (simple_diagnostic_path::add_event): New function.
1636 (simple_diagnostic_event::simple_diagnostic_event): New ctor.
1637 (simple_diagnostic_event::~simple_diagnostic_event): New dtor.
1638 (debug): New overload taking a diagnostic_path *.
1639 * diagnostic.def (DK_DIAGNOSTIC_PATH): New.
1640 * diagnostic.h (enum diagnostic_path_format): New enum.
1641 (json::value): New forward decl.
1642 (diagnostic_context::path_format): New field.
1643 (diagnostic_context::show_path_depths): New field.
1644 (diagnostic_context::print_path): New callback field.
1645 (diagnostic_context::make_json_for_path): New callback field.
1646 (diagnostic_show_any_path): New decl.
1647 (json_from_expanded_location): New decl.
1648 * doc/invoke.texi (-fdiagnostics-path-format=): New option.
1649 (-fdiagnostics-show-path-depths): New option.
1650 (-fdiagnostics-color): Add "path" to description of default
1651 GCC_COLORS; describe it.
1652 (-fdiagnostics-format=json): Document how diagnostic paths are
1653 represented in the JSON output format.
1654 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
1655 Add optional params "restrict_to_current_line_spans" and "label".
1656 * opts.c (common_handle_option): Handle
1657 OPT_fdiagnostics_path_format_ and
1658 OPT_fdiagnostics_show_path_depths.
1659 * pretty-print.c: Include "diagnostic-event-id.h".
1660 (pp_format): Implement "%@" format code for printing
1661 diagnostic_event_id_t *.
1662 (selftest::test_pp_format): Add tests for "%@".
1663 * selftest-run-tests.c (selftest::run_tests): Call
1664 selftest::tree_diagnostic_path_cc_tests.
1665 * selftest.h (selftest::tree_diagnostic_path_cc_tests): New decl.
1666 * toplev.c (general_init): Initialize global_dc->path_format and
1667 global_dc->show_path_depths.
1668 * tree-diagnostic-path.cc: New file.
1669 * tree-diagnostic.c (maybe_unwind_expanded_macro_loc): Make
1670 non-static. Drop "diagnostic" param in favor of storing the
1671 original value of "where" and re-using it.
1672 (virt_loc_aware_diagnostic_finalizer): Update for dropped param of
1673 maybe_unwind_expanded_macro_loc.
1674 (tree_diagnostics_defaults): Initialize context->print_path and
1675 context->make_json_for_path.
1676 * tree-diagnostic.h (default_tree_diagnostic_path_printer): New
1678 (default_tree_make_json_for_path): New decl.
1679 (maybe_unwind_expanded_macro_loc): New decl.
1681 2020-01-10 Jakub Jelinek <jakub@redhat.com>
1683 PR tree-optimization/93210
1684 * fold-const.h (native_encode_initializer,
1685 can_native_interpret_type_p): Declare.
1686 * fold-const.c (native_encode_string): Fix up handling with off != -1,
1688 (native_encode_initializer): New function, moved from dwarf2out.c.
1689 Adjust to native_encode_expr compatible arguments, including dry-run
1690 and partial extraction modes. Don't handle STRING_CST.
1691 (can_native_interpret_type_p): No longer static.
1692 * gimple-fold.c (fold_ctor_reference): For native_encode_expr, verify
1693 offset / BITS_PER_UNIT fits into int and don't call it if
1694 can_native_interpret_type_p fails. If suboff is NULL and for
1695 CONSTRUCTOR fold_{,non}array_ctor_reference returns NULL, retry with
1696 native_encode_initializer.
1697 (fold_const_aggregate_ref_1): Formatting fix.
1698 * dwarf2out.c (native_encode_initializer): Moved to fold-const.c.
1699 (tree_add_const_value_attribute): Adjust caller.
1701 PR tree-optimization/90838
1702 * tree-ssa-forwprop.c (simplify_count_trailing_zeroes): Use
1703 SCALAR_INT_TYPE_MODE instead of TYPE_MODE as operand of
1704 CTZ_DEFINED_VALUE_AT_ZERO.
1706 2020-01-10 Vladimir Makarov <vmakarov@redhat.com>
1709 * lra-constraints.c (match_reload): Permit input operands have the
1710 same mode as output while other input operands have a different
1713 2020-01-10 Wilco Dijkstra <wdijkstr@arm.com>
1715 PR tree-optimization/90838
1716 * tree-ssa-forwprop.c (check_ctz_array): Add new function.
1717 (check_ctz_string): Likewise.
1718 (optimize_count_trailing_zeroes): Likewise.
1719 (simplify_count_trailing_zeroes): Likewise.
1720 (pass_forwprop::execute): Try ctz simplification.
1721 * match.pd: Add matching for ctz idioms.
1723 2020-01-10 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1725 * config/aarch64/aarch64.c (aarch64_invalid_conversion): New function
1727 (aarch64_invalid_unary_op): New function for target hook.
1728 (aarch64_invalid_binary_op): New function for target hook.
1730 2020-01-10 Stam Markianos-Wright <stam.markianos-wright@arm.com>
1732 * config.gcc: Add arm_bf16.h.
1733 * config/aarch64/aarch64-builtins.c
1734 (aarch64_simd_builtin_std_type): Add BFmode.
1735 (aarch64_init_simd_builtin_types): Define element types for vector
1737 (aarch64_init_bf16_types): New function.
1738 (aarch64_general_init_builtins): Add arm_init_bf16_types function call.
1739 * config/aarch64/aarch64-modes.def: Add BFmode and V4BF, V8BF vector
1741 * config/aarch64/aarch64-simd-builtin-types.def: Add BF SIMD types.
1742 * config/aarch64/aarch64-simd.md: Add BF vector types to NEON move
1744 * config/aarch64/aarch64.h (AARCH64_VALID_SIMD_DREG_MODE): Add V4BF.
1745 (AARCH64_VALID_SIMD_QREG_MODE): Add V8BF.
1746 * config/aarch64/aarch64.c
1747 (aarch64_classify_vector_mode): Add support for BF types.
1748 (aarch64_gimplify_va_arg_expr): Add support for BF types.
1749 (aarch64_vq_mode): Add support for BF types.
1750 (aarch64_simd_container_mode): Add support for BF types.
1751 (aarch64_mangle_type): Add support for BF scalar type.
1752 * config/aarch64/aarch64.md: Add BFmode to movhf pattern.
1753 * config/aarch64/arm_bf16.h: New file.
1754 * config/aarch64/arm_neon.h: Add arm_bf16.h and Bfloat vector types.
1755 * config/aarch64/iterators.md: Add BF types to mode attributes.
1756 (HFBF, GPF_TF_F16_MOV, VDMOV, VQMOV, VQMOV_NO2Em VALL_F16MOV): New.
1758 2020-01-10 Jason Merrill <jason@redhat.com>
1760 PR c++/93173 - incorrect tree sharing.
1761 * gimplify.c (copy_if_shared): No longer static.
1762 * gimplify.h: Declare it.
1764 2020-01-10 Richard Sandiford <richard.sandiford@arm.com>
1766 * doc/invoke.texi (-msve-vector-bits=): Document that
1767 -msve-vector-bits=128 now generates VL-specific code for
1768 little-endian targets.
1769 * config/aarch64/aarch64-sve-builtins.cc (register_builtin_types): Use
1770 build_vector_type_for_mode to construct the data vector types.
1771 * config/aarch64/aarch64.c (aarch64_convert_sve_vector_bits): Generate
1772 VL-specific code for -msve-vector-bits=128 on little-endian targets.
1773 (aarch64_simd_container_mode): Always prefer Advanced SIMD modes
1774 for 128-bit vectors.
1776 2020-01-10 Richard Sandiford <richard.sandiford@arm.com>
1778 * config/aarch64/aarch64.c (aarch64_evpc_sel): Fix gen_vcond_mask
1781 2020-01-10 Richard Sandiford <richard.sandiford@arm.com>
1783 * config/aarch64/aarch64-builtins.c
1784 (aarch64_builtin_vectorized_function): Check for specific vector modes,
1785 rather than checking the number of elements and the element mode.
1787 2020-01-10 Richard Sandiford <richard.sandiford@arm.com>
1789 * tree-vect-loop.c (vect_create_epilog_for_reduction): Use
1790 get_related_vectype_for_scalar_type rather than build_vector_type
1791 to create the index type for a conditional reduction.
1793 2020-01-10 Richard Sandiford <richard.sandiford@arm.com>
1795 * tree-vect-loop.c (update_epilogue_loop_vinfo): Update DR_REF
1796 for any type of gather or scatter, including strided accesses.
1798 2020-01-10 Andre Vieira <andre.simoesdiasvieira@arm.com>
1800 * tree-vectorizer.h (get_dr_vinfo_offset): Add missing function
1803 2020-01-10 Andre Vieira <andre.simoesdiasvieira@arm.com>
1805 * tree-vect-data-refs.c (vect_create_addr_base_for_vector_ref): Use
1807 * tree-vect-loop.c (update_epilogue_loop_vinfo): Remove orig_drs_init
1808 parameter and its use to reset DR_OFFSET's.
1809 (vect_transform_loop): Remove orig_drs_init argument.
1810 * tree-vect-loop-manip.c (vect_update_init_of_dr): Update the offset
1811 member of dr_vec_info rather than the offset of the associated
1812 data_reference's innermost_loop_behavior.
1813 (vect_update_init_of_dr): Pass dr_vec_info instead of data_reference.
1814 (vect_do_peeling): Remove orig_drs_init parameter and its construction.
1815 * tree-vect-stmts.c (check_scan_store): Replace use of DR_OFFSET with
1816 get_dr_vinfo_offset.
1817 (vectorizable_store): Likewise.
1818 (vectorizable_load): Likewise.
1820 2020-01-10 Richard Biener <rguenther@suse.de>
1822 * gimple-ssa-store-merging
1823 (pass_store_merging::terminate_all_aliasing_chains): Cache alias info.
1825 2020-01-10 Martin Liska <mliska@suse.cz>
1828 * ipa-inline-analysis.c (offline_size): Make proper parenthesis
1829 encapsulation that was there before r280040.
1831 2020-01-10 Richard Biener <rguenther@suse.de>
1834 * tree-eh.c (sink_clobbers): Move clobbers to out-of-IL
1835 sequences to avoid walking them again for secondary opportunities.
1836 (pass_lower_eh_dispatch::execute): Instead actually insert
1839 2020-01-10 Richard Biener <rguenther@suse.de>
1842 * tree-eh.c (redirect_eh_edge_1): Avoid some work if possible.
1843 (cleanup_all_empty_eh): Walk landing pads in reverse order to
1844 avoid quadraticness.
1846 2020-01-10 Martin Jambor <mjambor@suse.cz>
1848 * params.opt (param_ipa_sra_max_replacements): Mark as Optimization.
1849 * ipa-sra.c (pull_accesses_from_callee): New parameter caller, use it
1850 to get param_ipa_sra_max_replacements.
1851 (param_splitting_across_edge): Pass the caller to
1852 pull_accesses_from_callee.
1854 2020-01-10 Martin Jambor <mjambor@suse.cz>
1856 * params.opt (param_ipcp_unit_growth): Mark as Optimization.
1857 * ipa-cp.c (max_new_size): Removed.
1858 (orig_overall_size): New variable.
1859 (get_max_overall_size): New function.
1860 (estimate_local_effects): Use it. Adjust dump.
1861 (decide_about_value): Likewise.
1862 (ipcp_propagate_stage): Do not calculate max_new_size, just store
1863 orig_overall_size. Adjust dump.
1864 (ipa_cp_c_finalize): Clear orig_overall_size instead of max_new_size.
1866 2020-01-10 Martin Jambor <mjambor@suse.cz>
1868 * params.opt (param_ipa_max_agg_items): Mark as Optimization
1869 * ipa-cp.c (merge_agg_lats_step): New parameter max_agg_items, use
1870 instead of param_ipa_max_agg_items.
1871 (merge_aggregate_lattices): Extract param_ipa_max_agg_items from
1872 optimization info for the callee.
1874 2020-01-09 Kwok Cheung Yeung <kcy@codesourcery.com>
1876 * lto-streamer-in.c (input_function): Remove streamed-in inline debug
1877 markers if debug_inline_points is false.
1879 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
1881 * config.gcc (aarch64*-*-*): Add aarch64-sve-builtins-sve2.o to
1883 * config/aarch64/t-aarch64 (aarch64-sve-builtins.o): Depend on
1884 aarch64-sve-builtins-base.def, aarch64-sve-builtins-sve2.def and
1885 aarch64-sve-builtins-sve2.h.
1886 (aarch64-sve-builtins-sve2.o): New rule.
1887 * config/aarch64/aarch64.h (AARCH64_ISA_SVE2_AES): New macro.
1888 (AARCH64_ISA_SVE2_BITPERM, AARCH64_ISA_SVE2_SHA3): Likewise.
1889 (AARCH64_ISA_SVE2_SM4, TARGET_SVE2_AES, TARGET_SVE2_BITPERM): Likewise.
1890 (TARGET_SVE2_SHA, TARGET_SVE2_SM4): Likewise.
1891 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
1892 TARGET_SVE2_AES, TARGET_SVE2_BITPERM, TARGET_SVE2_SHA3 and
1894 * config/aarch64/aarch64-sve.md: Update comments with SVE2
1895 instructions that are handled here.
1896 (@cond_asrd<mode>): Generalize to...
1897 (@cond_<SVE_INT_SHIFT_IMM:sve_int_op><mode>): ...this.
1898 (*cond_asrd<mode>_2): Generalize to...
1899 (*cond_<SVE_INT_SHIFT_IMM:sve_int_op><mode>_2): ...this.
1900 (*cond_asrd<mode>_z): Generalize to...
1901 (*cond_<SVE_INT_SHIFT_IMM:sve_int_op><mode>_z): ...this.
1902 * config/aarch64/aarch64.md (UNSPEC_LDNT1_GATHER): New unspec.
1903 (UNSPEC_STNT1_SCATTER, UNSPEC_WHILEGE, UNSPEC_WHILEGT): Likewise.
1904 (UNSPEC_WHILEHI, UNSPEC_WHILEHS): Likewise.
1905 * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>): New
1907 (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode><SVE_PARTIAL_I:mode>)
1908 (@aarch64_scatter_stnt<mode>): Likewise.
1909 (@aarch64_scatter_stnt_<SVE_FULL_SDI:mode><SVE_PARTIAL_I:mode>)
1910 (@aarch64_mul_lane_<mode>): Likewise.
1911 (@aarch64_sve_suqadd<mode>_const): Likewise.
1912 (*<sur>h<addsub><mode>): Generalize to...
1913 (@aarch64_pred_<SVE2_COND_INT_BINARY_REV:sve_int_op><mode>): ...this
1915 (@cond_<SVE2_COND_INT_BINARY:sve_int_op><mode>): New expander.
1916 (*cond_<SVE2_COND_INT_BINARY:sve_int_op><mode>_2): New pattern.
1917 (*cond_<SVE2_COND_INT_BINARY:sve_int_op><mode>_3): Likewise.
1918 (*cond_<SVE2_COND_INT_BINARY:sve_int_op><mode>_any): Likewise.
1919 (*cond_<SVE2_COND_INT_BINARY_NOREV:sve_int_op><mode>_z): Likewise.
1920 (@aarch64_sve_<SVE2_INT_BINARY:sve_int_op><mode>):: Likewise.
1921 (@aarch64_sve_<SVE2_INT_BINARY:sve_int_op>_lane_<mode>): Likewise.
1922 (@aarch64_pred_<SVE2_COND_INT_SHIFT:sve_int_op><mode>): Likewise.
1923 (@cond_<SVE2_COND_INT_SHIFT:sve_int_op><mode>): New expander.
1924 (*cond_<SVE2_COND_INT_SHIFT:sve_int_op><mode>_2): New pattern.
1925 (*cond_<SVE2_COND_INT_SHIFT:sve_int_op><mode>_3): Likewise.
1926 (*cond_<SVE2_COND_INT_SHIFT:sve_int_op><mode>_any): Likewise.
1927 (@aarch64_sve_<SVE2_INT_TERNARY:sve_int_op><mode>): Likewise.
1928 (@aarch64_sve_<SVE2_INT_TERNARY_LANE:sve_int_op>_lane_<mode>)
1929 (@aarch64_sve_add_mul_lane_<mode>): Likewise.
1930 (@aarch64_sve_sub_mul_lane_<mode>): Likewise.
1931 (@aarch64_sve2_xar<mode>): Likewise.
1932 (@aarch64_sve2_bcax<mode>): Likewise.
1933 (*aarch64_sve2_eor3<mode>): Rename to...
1934 (@aarch64_sve2_eor3<mode>): ...this.
1935 (@aarch64_sve2_bsl<mode>): New expander.
1936 (@aarch64_sve2_nbsl<mode>): Likewise.
1937 (@aarch64_sve2_bsl1n<mode>): Likewise.
1938 (@aarch64_sve2_bsl2n<mode>): Likewise.
1939 (@aarch64_sve_add_<SHIFTRT:sve_int_op><mode>): Likewise.
1940 (*aarch64_sve2_sra<mode>): Add MOVPRFX support.
1941 (@aarch64_sve_add_<VRSHR_N:sve_int_op><mode>): New pattern.
1942 (@aarch64_sve_<SVE2_INT_SHIFT_INSERT:sve_int_op><mode>): Likewise.
1943 (@aarch64_sve2_<USMAX:su>aba<mode>): New expander.
1944 (*aarch64_sve2_<USMAX:su>aba<mode>): New pattern.
1945 (@aarch64_sve_<SVE2_INT_BINARY_WIDE:sve_int_op><mode>): Likewise.
1946 (<su>mull<bt><Vwide>): Generalize to...
1947 (@aarch64_sve_<SVE2_INT_BINARY_LONG:sve_int_op><mode>): ...this new
1949 (@aarch64_sve_<SVE2_INT_BINARY_LONG_lANE:sve_int_op>_lane_<mode>)
1950 (@aarch64_sve_<SVE2_INT_SHIFT_IMM_LONG:sve_int_op><mode>)
1951 (@aarch64_sve_add_<SVE2_INT_ADD_BINARY_LONG:sve_int_op><mode>)
1952 (@aarch64_sve_add_<SVE2_INT_ADD_BINARY_LONG_LANE:sve_int_op>_lane_<mode>)
1953 (@aarch64_sve_qadd_<SVE2_INT_QADD_BINARY_LONG:sve_int_op><mode>)
1954 (@aarch64_sve_qadd_<SVE2_INT_QADD_BINARY_LONG_LANE:sve_int_op>_lane_<mode>)
1955 (@aarch64_sve_sub_<SVE2_INT_SUB_BINARY_LONG:sve_int_op><mode>)
1956 (@aarch64_sve_sub_<SVE2_INT_SUB_BINARY_LONG_LANE:sve_int_op>_lane_<mode>)
1957 (@aarch64_sve_qsub_<SVE2_INT_QSUB_BINARY_LONG:sve_int_op><mode>)
1958 (@aarch64_sve_qsub_<SVE2_INT_QSUB_BINARY_LONG_LANE:sve_int_op>_lane_<mode>)
1959 (@aarch64_sve_<SVE2_FP_TERNARY_LONG:sve_fp_op><mode>): New patterns.
1960 (@aarch64_<SVE2_FP_TERNARY_LONG_LANE:sve_fp_op>_lane_<mode>)
1961 (@aarch64_sve_<SVE2_INT_UNARY_NARROWB:sve_int_op><mode>): Likewise.
1962 (@aarch64_sve_<SVE2_INT_UNARY_NARROWT:sve_int_op><mode>): Likewise.
1963 (@aarch64_sve_<SVE2_INT_BINARY_NARROWB:sve_int_op><mode>): Likewise.
1964 (@aarch64_sve_<SVE2_INT_BINARY_NARROWT:sve_int_op><mode>): Likewise.
1965 (<SHRNB:r>shrnb<mode>): Generalize to...
1966 (@aarch64_sve_<SVE2_INT_SHIFT_IMM_NARROWB:sve_int_op><mode>): ...this
1968 (<SHRNT:r>shrnt<mode>): Generalize to...
1969 (@aarch64_sve_<SVE2_INT_SHIFT_IMM_NARROWT:sve_int_op><mode>): ...this
1971 (@aarch64_pred_<SVE2_INT_BINARY_PAIR:sve_int_op><mode>): New pattern.
1972 (@aarch64_pred_<SVE2_FP_BINARY_PAIR:sve_fp_op><mode>): Likewise.
1973 (@cond_<SVE2_INT_BINARY_PAIR_LONG:sve_int_op><mode>): New expander.
1974 (*cond_<SVE2_INT_BINARY_PAIR_LONG:sve_int_op><mode>_2): New pattern.
1975 (*cond_<SVE2_INT_BINARY_PAIR_LONG:sve_int_op><mode>_z): Likewise.
1976 (@aarch64_sve_<SVE2_INT_CADD:optab><mode>): Likewise.
1977 (@aarch64_sve_<SVE2_INT_CMLA:optab><mode>): Likewise.
1978 (@aarch64_<SVE2_INT_CMLA:optab>_lane_<mode>): Likewise.
1979 (@aarch64_sve_<SVE2_INT_CDOT:optab><mode>): Likewise.
1980 (@aarch64_<SVE2_INT_CDOT:optab>_lane_<mode>): Likewise.
1981 (@aarch64_pred_<SVE2_COND_FP_UNARY_LONG:sve_fp_op><mode>): Likewise.
1982 (@cond_<SVE2_COND_FP_UNARY_LONG:sve_fp_op><mode>): New expander.
1983 (*cond_<SVE2_COND_FP_UNARY_LONG:sve_fp_op><mode>): New pattern.
1984 (@aarch64_sve2_cvtnt<mode>): Likewise.
1985 (@aarch64_pred_<SVE2_COND_FP_UNARY_NARROWB:sve_fp_op><mode>): Likewise.
1986 (@cond_<SVE2_COND_FP_UNARY_NARROWB:sve_fp_op><mode>): New expander.
1987 (*cond_<SVE2_COND_FP_UNARY_NARROWB:sve_fp_op><mode>_any): New pattern.
1988 (@aarch64_sve2_cvtxnt<mode>): Likewise.
1989 (@aarch64_pred_<SVE2_U32_UNARY:sve_int_op><mode>): Likewise.
1990 (@cond_<SVE2_U32_UNARY:sve_int_op><mode>): New expander.
1991 (*cond_<SVE2_U32_UNARY:sve_int_op><mode>): New pattern.
1992 (@aarch64_pred_<SVE2_COND_INT_UNARY_FP:sve_fp_op><mode>): Likewise.
1993 (@cond_<SVE2_COND_INT_UNARY_FP:sve_fp_op><mode>): New expander.
1994 (*cond_<SVE2_COND_INT_UNARY_FP:sve_fp_op><mode>): New pattern.
1995 (@aarch64_sve2_pmul<mode>): Likewise.
1996 (@aarch64_sve_<SVE2_PMULL:optab><mode>): Likewise.
1997 (@aarch64_sve_<SVE2_PMULL_PAIR:optab><mode>): Likewise.
1998 (@aarch64_sve2_tbl2<mode>): Likewise.
1999 (@aarch64_sve2_tbx<mode>): Likewise.
2000 (@aarch64_sve_<SVE2_INT_BITPERM:sve_int_op><mode>): Likewise.
2001 (@aarch64_sve2_histcnt<mode>): Likewise.
2002 (@aarch64_sve2_histseg<mode>): Likewise.
2003 (@aarch64_pred_<SVE2_MATCH:sve_int_op><mode>): Likewise.
2004 (*aarch64_pred_<SVE2_MATCH:sve_int_op><mode>_cc): Likewise.
2005 (*aarch64_pred_<SVE2_MATCH:sve_int_op><mode>_ptest): Likewise.
2006 (aarch64_sve2_aes<CRYPTO_AES:aes_op>): Likewise.
2007 (aarch64_sve2_aes<CRYPTO_AESMC:aesmc_op>): Likewise.
2008 (*aarch64_sve2_aese_fused, *aarch64_sve2_aesd_fused): Likewise.
2009 (aarch64_sve2_rax1, aarch64_sve2_sm4e, aarch64_sve2_sm4ekey): Likewise.
2010 (<su>mulh<r>s<mode>3): Update after above pattern name changes.
2011 * config/aarch64/iterators.md (VNx16QI_ONLY, VNx4SF_ONLY)
2012 (SVE_STRUCT2, SVE_FULL_BHI, SVE_FULL_HSI, SVE_FULL_HDI)
2013 (SVE2_PMULL_PAIR_I): New mode iterators.
2014 (UNSPEC_ADCLB, UNSPEC_ADCLT, UNSPEC_ADDHNB, UNSPEC_ADDHNT, UNSPEC_BDEP)
2015 (UNSPEC_BEXT, UNSPEC_BGRP, UNSPEC_CADD90, UNSPEC_CADD270, UNSPEC_CDOT)
2016 (UNSPEC_CDOT90, UNSPEC_CDOT180, UNSPEC_CDOT270, UNSPEC_CMLA)
2017 (UNSPEC_CMLA90, UNSPEC_CMLA180, UNSPEC_CMLA270, UNSPEC_COND_FCVTLT)
2018 (UNSPEC_COND_FCVTNT, UNSPEC_COND_FCVTX, UNSPEC_COND_FCVTXNT)
2019 (UNSPEC_COND_FLOGB, UNSPEC_EORBT, UNSPEC_EORTB, UNSPEC_FADDP)
2020 (UNSPEC_FMAXP, UNSPEC_FMAXNMP, UNSPEC_FMLALB, UNSPEC_FMLALT)
2021 (UNSPEC_FMLSLB, UNSPEC_FMLSLT, UNSPEC_FMINP, UNSPEC_FMINNMP)
2022 (UNSPEC_HISTCNT, UNSPEC_HISTSEG, UNSPEC_MATCH, UNSPEC_NMATCH)
2023 (UNSPEC_PMULLB, UNSPEC_PMULLB_PAIR, UNSPEC_PMULLT, UNSPEC_PMULLT_PAIR)
2024 (UNSPEC_RADDHNB, UNSPEC_RADDHNT, UNSPEC_RSUBHNB, UNSPEC_RSUBHNT)
2025 (UNSPEC_SLI, UNSPEC_SRI, UNSPEC_SABDLB, UNSPEC_SABDLT, UNSPEC_SADDLB)
2026 (UNSPEC_SADDLBT, UNSPEC_SADDLT, UNSPEC_SADDWB, UNSPEC_SADDWT)
2027 (UNSPEC_SBCLB, UNSPEC_SBCLT, UNSPEC_SMAXP, UNSPEC_SMINP)
2028 (UNSPEC_SQCADD90, UNSPEC_SQCADD270, UNSPEC_SQDMULLB, UNSPEC_SQDMULLBT)
2029 (UNSPEC_SQDMULLT, UNSPEC_SQRDCMLAH, UNSPEC_SQRDCMLAH90)
2030 (UNSPEC_SQRDCMLAH180, UNSPEC_SQRDCMLAH270, UNSPEC_SQRSHRNB)
2031 (UNSPEC_SQRSHRNT, UNSPEC_SQRSHRUNB, UNSPEC_SQRSHRUNT, UNSPEC_SQSHRNB)
2032 (UNSPEC_SQSHRNT, UNSPEC_SQSHRUNB, UNSPEC_SQSHRUNT, UNSPEC_SQXTNB)
2033 (UNSPEC_SQXTNT, UNSPEC_SQXTUNB, UNSPEC_SQXTUNT, UNSPEC_SSHLLB)
2034 (UNSPEC_SSHLLT, UNSPEC_SSUBLB, UNSPEC_SSUBLBT, UNSPEC_SSUBLT)
2035 (UNSPEC_SSUBLTB, UNSPEC_SSUBWB, UNSPEC_SSUBWT, UNSPEC_SUBHNB)
2036 (UNSPEC_SUBHNT, UNSPEC_TBL2, UNSPEC_UABDLB, UNSPEC_UABDLT)
2037 (UNSPEC_UADDLB, UNSPEC_UADDLT, UNSPEC_UADDWB, UNSPEC_UADDWT)
2038 (UNSPEC_UMAXP, UNSPEC_UMINP, UNSPEC_UQRSHRNB, UNSPEC_UQRSHRNT)
2039 (UNSPEC_UQSHRNB, UNSPEC_UQSHRNT, UNSPEC_UQXTNB, UNSPEC_UQXTNT)
2040 (UNSPEC_USHLLB, UNSPEC_USHLLT, UNSPEC_USUBLB, UNSPEC_USUBLT)
2041 (UNSPEC_USUBWB, UNSPEC_USUBWT): New unspecs.
2042 (UNSPEC_SMULLB, UNSPEC_SMULLT, UNSPEC_UMULLB, UNSPEC_UMULLT)
2043 (UNSPEC_SMULHS, UNSPEC_SMULHRS, UNSPEC_UMULHS, UNSPEC_UMULHRS)
2044 (UNSPEC_RSHRNB, UNSPEC_RSHRNT, UNSPEC_SHRNB, UNSPEC_SHRNT): Move
2046 (VNARROW, Ventype): New mode attributes.
2047 (Vewtype): Handle VNx2DI. Fix typo in comment.
2048 (VDOUBLE): New mode attribute.
2049 (sve_lane_con): Handle VNx8HI.
2050 (SVE_INT_UNARY): Include ss_abs and ss_neg for TARGET_SVE2.
2051 (SVE_INT_BINARY): Likewise ss_plus, us_plus, ss_minus and us_minus.
2052 (sve_int_op, sve_int_op_rev): Handle the above codes.
2053 (sve_pred_int_rhs2_operand): Likewise.
2054 (MULLBT, SHRNB, SHRNT): Delete.
2055 (SVE_INT_SHIFT_IMM): New int iterator.
2056 (SVE_WHILE): Add UNSPEC_WHILEGE, UNSPEC_WHILEGT, UNSPEC_WHILEHI
2057 and UNSPEC_WHILEHS for TARGET_SVE2.
2058 (SVE2_U32_UNARY, SVE2_INT_UNARY_NARROWB, SVE2_INT_UNARY_NARROWT)
2059 (SVE2_INT_BINARY, SVE2_INT_BINARY_LANE, SVE2_INT_BINARY_LONG)
2060 (SVE2_INT_BINARY_LONG_LANE, SVE2_INT_BINARY_NARROWB)
2061 (SVE2_INT_BINARY_NARROWT, SVE2_INT_BINARY_PAIR, SVE2_FP_BINARY_PAIR)
2062 (SVE2_INT_BINARY_PAIR_LONG, SVE2_INT_BINARY_WIDE): New int iterators.
2063 (SVE2_INT_SHIFT_IMM_LONG, SVE2_INT_SHIFT_IMM_NARROWB): Likewise.
2064 (SVE2_INT_SHIFT_IMM_NARROWT, SVE2_INT_SHIFT_INSERT, SVE2_INT_CADD)
2065 (SVE2_INT_BITPERM, SVE2_INT_TERNARY, SVE2_INT_TERNARY_LANE): Likewise.
2066 (SVE2_FP_TERNARY_LONG, SVE2_FP_TERNARY_LONG_LANE, SVE2_INT_CMLA)
2067 (SVE2_INT_CDOT, SVE2_INT_ADD_BINARY_LONG, SVE2_INT_QADD_BINARY_LONG)
2068 (SVE2_INT_SUB_BINARY_LONG, SVE2_INT_QSUB_BINARY_LONG): Likewise.
2069 (SVE2_INT_ADD_BINARY_LONG_LANE, SVE2_INT_QADD_BINARY_LONG_LANE)
2070 (SVE2_INT_SUB_BINARY_LONG_LANE, SVE2_INT_QSUB_BINARY_LONG_LANE)
2071 (SVE2_COND_INT_UNARY_FP, SVE2_COND_FP_UNARY_LONG): Likewise.
2072 (SVE2_COND_FP_UNARY_NARROWB, SVE2_COND_INT_BINARY): Likewise.
2073 (SVE2_COND_INT_BINARY_NOREV, SVE2_COND_INT_BINARY_REV): Likewise.
2074 (SVE2_COND_INT_SHIFT, SVE2_MATCH, SVE2_PMULL): Likewise.
2075 (optab): Handle the new unspecs.
2076 (su, r): Remove entries for UNSPEC_SHRNB, UNSPEC_SHRNT, UNSPEC_RSHRNB
2078 (lr): Handle the new unspecs.
2080 (cmp_op, while_optab_cmp, sve_int_op): Handle the new unspecs.
2081 (sve_int_op_rev, sve_int_add_op, sve_int_qadd_op, sve_int_sub_op)
2082 (sve_int_qsub_op): New int attributes.
2083 (sve_fp_op, rot): Handle the new unspecs.
2084 * config/aarch64/aarch64-sve-builtins.h
2085 (function_resolver::require_matching_pointer_type): Declare.
2086 (function_resolver::resolve_unary): Add an optional boolean argument.
2087 (function_resolver::finish_opt_n_resolution): Add an optional
2088 type_suffix_index argument.
2089 (gimple_folder::redirect_call): Declare.
2090 (gimple_expander::prepare_gather_address_operands): Add an optional
2092 * config/aarch64/aarch64-sve-builtins.cc: Include
2093 aarch64-sve-builtins-sve2.h.
2094 (TYPES_b_unsigned, TYPES_b_integer, TYPES_bh_integer): New macros.
2095 (TYPES_bs_unsigned, TYPES_hs_signed, TYPES_hs_integer): Likewise.
2096 (TYPES_hd_unsigned, TYPES_hsd_signed): Likewise.
2097 (TYPES_hsd_integer): Use TYPES_hsd_signed.
2098 (TYPES_s_float_hsd_integer, TYPES_s_float_sd_integer): New macros.
2099 (TYPES_s_unsigned): Likewise.
2100 (TYPES_s_integer): Use TYPES_s_unsigned.
2101 (TYPES_sd_signed, TYPES_sd_unsigned): New macros.
2102 (TYPES_sd_integer): Use them.
2103 (TYPES_d_unsigned): New macro.
2104 (TYPES_d_integer): Use it.
2105 (TYPES_d_data, TYPES_cvt_long, TYPES_cvt_narrow_s): New macros.
2106 (TYPES_cvt_narrow): Likewise.
2107 (DEF_SVE_TYPES_ARRAY): Include the new types macros above.
2108 (preds_mx): New variable.
2109 (function_builder::add_overloaded_function): Allow the new feature
2110 set to be more restrictive than the original one.
2111 (function_resolver::infer_pointer_type): Remove qualifiers from
2112 the pointer type before printing it.
2113 (function_resolver::require_matching_pointer_type): New function.
2114 (function_resolver::resolve_sv_displacement): Handle functions
2115 that don't support 32-bit vector indices or svint32_t vector offsets.
2116 (function_resolver::finish_opt_n_resolution): Take the inferred type
2117 as a separate argument.
2118 (function_resolver::resolve_unary): Optionally treat all forms in
2119 the same way as normal merging functions.
2120 (gimple_folder::redirect_call): New function.
2121 (function_expander::prepare_gather_address_operands): Add an argument
2122 that says whether scaled forms are available. If they aren't,
2123 handle scaling of vector indices and don't add the extension and
2125 (function_expander::map_to_unspecs): If aarch64_sve isn't available,
2126 fall back to using cond_* instead.
2127 * config/aarch64/aarch64-sve-builtins-functions.h (rtx_code_function):
2128 Split out the member variables into...
2129 (rtx_code_function_base): ...this new base class.
2130 (rtx_code_function_rotated): Inherit rtx_code_function_base.
2131 (unspec_based_function): Split out the member variables into...
2132 (unspec_based_function_base): ...this new base class.
2133 (unspec_based_function_rotated): Inherit unspec_based_function_base.
2134 (unspec_based_function_exact_insn): New class.
2135 (unspec_based_add_function, unspec_based_add_lane_function)
2136 (unspec_based_lane_function, unspec_based_pred_function)
2137 (unspec_based_qadd_function, unspec_based_qadd_lane_function)
2138 (unspec_based_qsub_function, unspec_based_qsub_lane_function)
2139 (unspec_based_sub_function, unspec_based_sub_lane_function): New
2141 (unspec_based_fused_function): New class.
2142 (unspec_based_mla_function, unspec_based_mls_function): New typedefs.
2143 (unspec_based_fused_lane_function): New class.
2144 (unspec_based_mla_lane_function, unspec_based_mls_lane_function): New
2146 (CODE_FOR_MODE1): New macro.
2147 (fixed_insn_function): New class.
2148 (while_comparison): Likewise.
2149 * config/aarch64/aarch64-sve-builtins-shapes.h (binary_long_lane)
2150 (binary_long_opt_n, binary_narrowb_opt_n, binary_narrowt_opt_n)
2151 (binary_to_uint, binary_wide, binary_wide_opt_n, compare, compare_ptr)
2152 (load_ext_gather_index_restricted, load_ext_gather_offset_restricted)
2153 (load_gather_sv_restricted, shift_left_imm_long): Declare.
2154 (shift_left_imm_to_uint, shift_right_imm_narrowb): Likewise.
2155 (shift_right_imm_narrowt, shift_right_imm_narrowb_to_uint): Likewise.
2156 (shift_right_imm_narrowt_to_uint, store_scatter_index_restricted)
2157 (store_scatter_offset_restricted, tbl_tuple, ternary_long_lane)
2158 (ternary_long_opt_n, ternary_qq_lane_rotate, ternary_qq_rotate)
2159 (ternary_shift_left_imm, ternary_shift_right_imm, ternary_uint)
2160 (unary_convert_narrowt, unary_long, unary_narrowb, unary_narrowt)
2161 (unary_narrowb_to_uint, unary_narrowt_to_uint, unary_to_int): Likewise.
2162 * config/aarch64/aarch64-sve-builtins-shapes.cc (apply_predication):
2163 Also add an initial argument for unary_convert_narrowt, regardless
2164 of the predication type.
2165 (build_32_64): Allow loads and stores to specify MODE_none.
2166 (build_sv_index64, build_sv_uint_offset): New functions.
2167 (long_type_suffix): New function.
2168 (binary_imm_narrowb_base, binary_imm_narrowt_base): New classes.
2169 (binary_imm_long_base, load_gather_sv_base): Likewise.
2170 (shift_right_imm_narrow_wrapper, ternary_shift_imm_base): Likewise.
2171 (ternary_resize2_opt_n_base, ternary_resize2_lane_base): Likewise.
2172 (unary_narrowb_base, unary_narrowt_base): Likewise.
2173 (binary_long_lane_def, binary_long_lane): New shape.
2174 (binary_long_opt_n_def, binary_long_opt_n): Likewise.
2175 (binary_narrowb_opt_n_def, binary_narrowb_opt_n): Likewise.
2176 (binary_narrowt_opt_n_def, binary_narrowt_opt_n): Likewise.
2177 (binary_to_uint_def, binary_to_uint): Likewise.
2178 (binary_wide_def, binary_wide): Likewise.
2179 (binary_wide_opt_n_def, binary_wide_opt_n): Likewise.
2180 (compare_def, compare): Likewise.
2181 (compare_ptr_def, compare_ptr): Likewise.
2182 (load_ext_gather_index_restricted_def,
2183 load_ext_gather_index_restricted): Likewise.
2184 (load_ext_gather_offset_restricted_def,
2185 load_ext_gather_offset_restricted): Likewise.
2186 (load_gather_sv_def): Inherit from load_gather_sv_base.
2187 (load_gather_sv_restricted_def, load_gather_sv_restricted): New shape.
2188 (shift_left_imm_def, shift_left_imm): Likewise.
2189 (shift_left_imm_long_def, shift_left_imm_long): Likewise.
2190 (shift_left_imm_to_uint_def, shift_left_imm_to_uint): Likewise.
2191 (store_scatter_index_restricted_def,
2192 store_scatter_index_restricted): Likewise.
2193 (store_scatter_offset_restricted_def,
2194 store_scatter_offset_restricted): Likewise.
2195 (tbl_tuple_def, tbl_tuple): Likewise.
2196 (ternary_long_lane_def, ternary_long_lane): Likewise.
2197 (ternary_long_opt_n_def, ternary_long_opt_n): Likewise.
2198 (ternary_qq_lane_def): Inherit from ternary_resize2_lane_base.
2199 (ternary_qq_lane_rotate_def, ternary_qq_lane_rotate): New shape
2200 (ternary_qq_opt_n_def): Inherit from ternary_resize2_opt_n_base.
2201 (ternary_qq_rotate_def, ternary_qq_rotate): New shape.
2202 (ternary_shift_left_imm_def, ternary_shift_left_imm): Likewise.
2203 (ternary_shift_right_imm_def, ternary_shift_right_imm): Likewise.
2204 (ternary_uint_def, ternary_uint): Likewise.
2205 (unary_convert): Fix typo in comment.
2206 (unary_convert_narrowt_def, unary_convert_narrowt): New shape.
2207 (unary_long_def, unary_long): Likewise.
2208 (unary_narrowb_def, unary_narrowb): Likewise.
2209 (unary_narrowt_def, unary_narrowt): Likewise.
2210 (unary_narrowb_to_uint_def, unary_narrowb_to_uint): Likewise.
2211 (unary_narrowt_to_uint_def, unary_narrowt_to_uint): Likewise.
2212 (unary_to_int_def, unary_to_int): Likewise.
2213 * config/aarch64/aarch64-sve-builtins-base.cc (unspec_cmla)
2214 (unspec_fcmla, unspec_cond_fcmla, expand_mla_mls_lane): New functions.
2215 (svasrd_impl): Delete.
2216 (svcadd_impl::expand): Handle integer operations too.
2217 (svcmla_impl::expand, svcmla_lane::expand): Likewise, using the
2218 new functions to derive the unspec numbers.
2219 (svmla_svmls_lane_impl): Replace with...
2220 (svmla_lane_impl, svmls_lane_impl): ...these new classes. Handle
2221 integer operations too.
2222 (svwhile_impl): Rename to...
2223 (svwhilelx_impl): ...this and inherit from while_comparison.
2224 (svasrd): Use unspec_based_function.
2225 (svmla_lane): Use svmla_lane_impl.
2226 (svmls_lane): Use svmls_lane_impl.
2227 (svrecpe, svrsqrte): Handle unsigned integer operations too.
2228 (svwhilele, svwhilelt): Use svwhilelx_impl.
2229 * config/aarch64/aarch64-sve-builtins-sve2.h: New file.
2230 * config/aarch64/aarch64-sve-builtins-sve2.cc: Likewise.
2231 * config/aarch64/aarch64-sve-builtins-sve2.def: Likewise.
2232 * config/aarch64/aarch64-sve-builtins.def: Include
2233 aarch64-sve-builtins-sve2.def.
2235 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2237 * config/aarch64/aarch64-protos.h (aarch64_sve_arith_immediate_p)
2238 (aarch64_sve_sqadd_sqsub_immediate_p): Add a machine_mode argument.
2239 * config/aarch64/aarch64.c (aarch64_sve_arith_immediate_p)
2240 (aarch64_sve_sqadd_sqsub_immediate_p): Likewise. Handle scalar
2241 immediates as well as vector ones.
2242 * config/aarch64/predicates.md (aarch64_sve_arith_immediate)
2243 (aarch64_sve_sub_arith_immediate, aarch64_sve_qadd_immediate)
2244 (aarch64_sve_qsub_immediate): Update calls accordingly.
2246 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2248 * config/aarch64/aarch64-sve2.md: Add banner comments.
2249 (<su>mulh<r>s<mode>3): Move further up file.
2250 (<su>mull<bt><Vwide>, <r>shrnb<mode>, <r>shrnt<mode>)
2251 (*aarch64_sve2_sra<mode>): Move further down file.
2252 * config/aarch64/t-aarch64 (s-check-sve-md): Check aarch64-sve2.md too.
2254 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2256 * config/aarch64/iterators.md (SVE_WHILE): Add UNSPEC_WHILERW
2258 (while_optab_cmp): Handle them.
2259 * config/aarch64/aarch64-sve.md
2260 (*while_<while_optab_cmp><GPI:mode><PRED_ALL:mode>_ptest): Make public
2261 and add a "@" marker.
2262 * config/aarch64/aarch64-sve2.md (check_<raw_war>_ptrs<mode>): Use it
2263 instead of gen_aarch64_sve2_while_ptest.
2264 (@aarch64_sve2_while<cmp_op><GPI:mode><PRED_ALL:mode>_ptest): Delete.
2266 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2268 * config/aarch64/aarch64.md (UNSPEC_WHILE_LE): Rename to...
2269 (UNSPEC_WHILELE): ...this.
2270 (UNSPEC_WHILE_LO): Rename to...
2271 (UNSPEC_WHILELO): ...this.
2272 (UNSPEC_WHILE_LS): Rename to...
2273 (UNSPEC_WHILELS): ...this.
2274 (UNSPEC_WHILE_LT): Rename to...
2275 (UNSPEC_WHILELT): ...this.
2276 * config/aarch64/iterators.md (SVE_WHILE): Update accordingly.
2277 (cmp_op, while_optab_cmp): Likewise.
2278 * config/aarch64/aarch64.c (aarch64_sve_move_pred_via_while): Likewise.
2279 * config/aarch64/aarch64-sve-builtins-base.cc (svwhilele): Likewise.
2280 (svwhilelt): Likewise.
2282 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2284 * config/aarch64/aarch64-sve-builtins-shapes.h (unary_count): Delete.
2285 (unary_to_uint): Define.
2286 * config/aarch64/aarch64-sve-builtins-shapes.cc (unary_count_def)
2287 (unary_count): Rename to...
2288 (unary_to_uint_def, unary_to_uint): ...this.
2289 * config/aarch64/aarch64-sve-builtins-base.def: Update accordingly.
2291 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2293 * config/aarch64/aarch64-sve-builtins-functions.h
2294 (code_for_mode_function): New class.
2295 (CODE_FOR_MODE0, QUIET_CODE_FOR_MODE0): New macros.
2296 * config/aarch64/aarch64-sve-builtins-base.cc (svcompact_impl)
2297 (svext_impl, svmul_lane_impl, svsplice_impl, svtmad_impl): Delete.
2298 (svcompact, svext, svsplice): Use QUIET_CODE_FOR_MODE0.
2299 (svmul_lane, svtmad): Use CODE_FOR_MODE0.
2301 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2303 * config/aarch64/iterators.md (addsub): New code attribute.
2304 * config/aarch64/aarch64-simd.md (aarch64_<su_optab><optab><mode>):
2306 (aarch64_<su_optab>q<addsub><mode>): ...this, making the same change
2307 in the asm string and attributes. Fix indentation.
2308 * config/aarch64/aarch64-sve.md (@aarch64_<su_optab><optab><mode>):
2310 (@aarch64_sve_<optab><mode>): ...this.
2311 * config/aarch64/aarch64-sve-builtins.h
2312 (function_expander::expand_signed_unpred_op): Delete.
2313 * config/aarch64/aarch64-sve-builtins.cc
2314 (function_expander::expand_signed_unpred_op): Likewise.
2315 (function_expander::map_to_rtx_codes): If the optab isn't defined,
2316 try using code_for_aarch64_sve instead.
2317 * config/aarch64/aarch64-sve-builtins-base.cc (svqadd_impl): Delete.
2318 (svqsub_impl): Likewise.
2319 (svqadd, svqsub): Use rtx_code_function instead.
2321 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2323 * config/aarch64/iterators.md (SRHSUB, URHSUB): Delete.
2324 (HADDSUB, sur, addsub): Remove them.
2326 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2328 * tree-nrv.c (pass_return_slot::execute): Handle all internal
2329 functions the same way, rather than singling out those that
2330 aren't mapped directly to optabs.
2332 2020-01-09 Richard Sandiford <richard.sandiford@arm.com>
2334 * target.def (compatible_vector_types_p): New target hook.
2335 * hooks.h (hook_bool_const_tree_const_tree_true): Declare.
2336 * hooks.c (hook_bool_const_tree_const_tree_true): New function.
2337 * doc/tm.texi.in (TARGET_COMPATIBLE_VECTOR_TYPES_P): New hook.
2338 * doc/tm.texi: Regenerate.
2339 * gimple-expr.c: Include target.h.
2340 (useless_type_conversion_p): Use targetm.compatible_vector_types_p.
2341 * config/aarch64/aarch64.c (aarch64_compatible_vector_types_p): New
2343 (TARGET_COMPATIBLE_VECTOR_TYPES_P): Define.
2344 * config/aarch64/aarch64-sve-builtins.cc (gimple_folder::convert_pred):
2345 Use the original predicate if it already has a suitable type.
2347 2020-01-09 Martin Jambor <mjambor@suse.cz>
2349 * cgraph.h (cgraph_edge): Make remove, set_call_stmt, make_direct,
2350 resolve_speculation and redirect_call_stmt_to_callee static. Change
2351 return type of set_call_stmt to cgraph_edge *.
2352 * auto-profile.c (afdo_indirect_call): Adjust call to
2353 redirect_call_stmt_to_callee.
2354 * cgraph.c (cgraph_edge::set_call_stmt): Make return cgraph-edge *,
2355 make the this pointer explicit, adjust self-recursive calls and the
2356 call top make_direct. Return the resulting edge.
2357 (cgraph_edge::remove): Make this pointer explicit.
2358 (cgraph_edge::resolve_speculation): Likewise, adjust call to remove.
2359 (cgraph_edge::make_direct): Likewise, adjust call to
2360 resolve_speculation.
2361 (cgraph_edge::redirect_call_stmt_to_callee): Likewise, also adjust
2362 call to set_call_stmt.
2363 (cgraph_update_edges_for_call_stmt_node): Update call to
2364 set_call_stmt and remove.
2365 * cgraphclones.c (cgraph_node::set_call_stmt_including_clones):
2366 Renamed edge to master_edge. Adjusted calls to set_call_stmt.
2367 (cgraph_node::create_edge_including_clones): Moved "first" definition
2368 of edge to the block where it was used. Adjusted calls to
2370 (cgraph_node::remove_symbol_and_inline_clones): Adjust call to
2371 cgraph_edge::remove.
2372 * cgraphunit.c (walk_polymorphic_call_targets): Adjusted calls to
2373 make_direct and redirect_call_stmt_to_callee.
2374 * ipa-fnsummary.c (redirect_to_unreachable): Adjust calls to
2375 resolve_speculation and make_direct.
2376 * ipa-inline-transform.c (inline_transform): Adjust call to
2377 redirect_call_stmt_to_callee.
2378 (check_speculations_1):: Adjust call to resolve_speculation.
2379 * ipa-inline.c (resolve_noninline_speculation): Adjust call to
2380 resolve-speculation.
2381 (inline_small_functions): Adjust call to resolve_speculation.
2382 (ipa_inline): Likewise.
2383 * ipa-prop.c (ipa_make_edge_direct_to_target): Adjust call to
2385 * ipa-visibility.c (function_and_variable_visibility): Make iteration
2386 safe with regards to edge removal, adjust calls to
2387 redirect_call_stmt_to_callee.
2388 * ipa.c (walk_polymorphic_call_targets): Adjust calls to make_direct
2389 and redirect_call_stmt_to_callee.
2390 * multiple_target.c (create_dispatcher_calls): Adjust call to
2391 redirect_call_stmt_to_callee
2392 (redirect_to_specific_clone): Likewise.
2393 * tree-cfgcleanup.c (delete_unreachable_blocks_update_callgraph):
2394 Adjust calls to cgraph_edge::remove.
2395 * tree-inline.c (copy_bb): Adjust call to set_call_stmt.
2396 (redirect_all_calls): Adjust call to redirect_call_stmt_to_callee.
2397 (expand_call_inline): Adjust call to cgraph_edge::remove.
2399 2020-01-09 Martin Liska <mliska@suse.cz>
2401 * params.opt: Set Optimization for
2402 param_max_speculative_devirt_maydefs.
2404 2020-01-09 Martin Sebor <msebor@redhat.com>
2408 * builtins.c (compute_objsize): Avoid handling MEM_REFs of vector type.
2410 2020-01-09 Martin Liska <mliska@suse.cz>
2412 * auto-profile.c (auto_profile): Use opt_for_fn
2414 * ipa-cp.c (ipcp_lattice::add_value): Likewise.
2415 (propagate_vals_across_arith_jfunc): Likewise.
2416 (hint_time_bonus): Likewise.
2417 (incorporate_penalties): Likewise.
2418 (good_cloning_opportunity_p): Likewise.
2419 (perform_estimation_of_a_value): Likewise.
2420 (estimate_local_effects): Likewise.
2421 (ipcp_propagate_stage): Likewise.
2422 * ipa-fnsummary.c (decompose_param_expr): Likewise.
2423 (set_switch_stmt_execution_predicate): Likewise.
2424 (analyze_function_body): Likewise.
2425 * ipa-inline-analysis.c (offline_size): Likewise.
2426 * ipa-inline.c (early_inliner): Likewise.
2427 * ipa-prop.c (ipa_analyze_node): Likewise.
2428 (ipcp_transform_function): Likewise.
2429 * ipa-sra.c (process_scan_results): Likewise.
2430 (ipa_sra_summarize_function): Likewise.
2431 * params.opt: Rename ipcp-unit-growth to
2432 ipa-cp-unit-growth. Add Optimization for various
2433 IPA-related parameters.
2435 2020-01-09 Richard Biener <rguenther@suse.de>
2438 * gimplify.c (gimplify_expr): Deal with NOP definitions.
2440 2020-01-09 Richard Biener <rguenther@suse.de>
2442 PR tree-optimization/93040
2443 * gimple-ssa-store-merging.c (find_bswap_or_nop): Raise search limit.
2445 2020-01-09 Georg-Johann Lay <avr@gjlay.de>
2447 * common/config/avr/avr-common.c (avr_option_optimization_table)
2448 [OPT_LEVELS_1_PLUS]: Set -fsplit-wide-types-early.
2450 2020-01-09 Martin Liska <mliska@suse.cz>
2452 * cgraphclones.c (symbol_table::materialize_all_clones):
2453 Use cgraph_node::dump_name.
2455 2020-01-09 Jakub Jelinek <jakub@redhat.com>
2458 * config/riscv/riscv.c (riscv_print_operand_reloc): Use
2459 output_operand_lossage instead of gcc_unreachable.
2460 * doc/md.texi (riscv f constraint): Fix typo.
2463 * config/i386/i386.md (subv<mode>4): Use SWIDWI iterator instead of
2464 SWI. Use <general_hilo_operand> instead of <general_operand>. Use
2465 CONST_SCALAR_INT_P instead of CONST_INT_P.
2466 (*subv<mode>4_1): Rename to ...
2467 (subv<mode>4_1): ... this.
2468 (*subv<dwi>4_doubleword, *addv<dwi>4_doubleword_1): New
2469 define_insn_and_split patterns.
2470 (*subv<mode>4_overflow_1, *addv<mode>4_overflow_2): New define_insn
2473 2020-01-08 David Malcolm <dmalcolm@redhat.com>
2475 * vec.c (class selftest::count_dtor): New class.
2476 (selftest::test_auto_delete_vec): New test.
2477 (selftest::vec_c_tests): Call it.
2478 * vec.h (class auto_delete_vec): New class template.
2479 (auto_delete_vec<T>::~auto_delete_vec): New dtor.
2481 2020-01-08 David Malcolm <dmalcolm@redhat.com>
2483 * sbitmap.h (auto_sbitmap): Add operator const_sbitmap.
2485 2020-01-08 Jim Wilson <jimw@sifive.com>
2487 * config/riscv/riscv.c (riscv_legitimize_tls_address): Ifdef out
2488 use of TLS_MODEL_LOCAL_EXEC when not pic.
2490 2020-01-08 David Malcolm <dmalcolm@redhat.com>
2492 * hash-map-tests.c (selftest::test_map_of_strings_to_int): Fix
2495 2020-01-08 Jakub Jelinek <jakub@redhat.com>
2498 * config/i386/i386.md (*stack_protect_set_2_<mode> peephole2,
2499 *stack_protect_set_3 peephole2): Also check that the second
2500 insns source is general_operand.
2503 * config/i386/i386.md (addcarry<mode>_0): Use nonimmediate_operand
2504 predicate for output operand instead of register_operand.
2505 (addcarry<mode>, addcarry<mode>_1): Likewise. Add alternative with
2506 memory destination and non-memory operands[2].
2508 2020-01-08 Martin Liska <mliska@suse.cz>
2510 * cgraph.c (cgraph_node::dump): Use ::dump_name or
2511 ::dump_asm_name instead of (::name or ::asm_name).
2512 * cgraphclones.c (symbol_table::materialize_all_clones): Likewise.
2513 * cgraphunit.c (walk_polymorphic_call_targets): Likewise.
2514 (analyze_functions): Likewise.
2515 (expand_all_functions): Likewise.
2516 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
2517 (propagate_bits_across_jump_function): Likewise.
2518 (dump_profile_updates): Likewise.
2519 (ipcp_store_bits_results): Likewise.
2520 (ipcp_store_vr_results): Likewise.
2521 * ipa-devirt.c (dump_targets): Likewise.
2522 * ipa-fnsummary.c (analyze_function_body): Likewise.
2523 * ipa-hsa.c (check_warn_node_versionable): Likewise.
2524 (process_hsa_functions): Likewise.
2525 * ipa-icf.c (sem_item_optimizer::merge_classes): Likewise.
2526 (set_alias_uids): Likewise.
2527 * ipa-inline-transform.c (save_inline_function_body): Likewise.
2528 * ipa-inline.c (recursive_inlining): Likewise.
2529 (inline_to_all_callers_1): Likewise.
2530 (ipa_inline): Likewise.
2531 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
2532 (ipa_propagate_frequency): Likewise.
2533 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
2534 (remove_described_reference): Likewise.
2535 * ipa-pure-const.c (worse_state): Likewise.
2536 (check_retval_uses): Likewise.
2537 (analyze_function): Likewise.
2538 (propagate_pure_const): Likewise.
2539 (propagate_nothrow): Likewise.
2540 (dump_malloc_lattice): Likewise.
2541 (propagate_malloc): Likewise.
2542 (pass_local_pure_const::execute): Likewise.
2543 * ipa-visibility.c (optimize_weakref): Likewise.
2544 (function_and_variable_visibility): Likewise.
2545 * ipa.c (symbol_table::remove_unreachable_nodes): Likewise.
2546 (ipa_discover_variable_flags): Likewise.
2547 * lto-streamer-out.c (output_function): Likewise.
2548 (output_constructor): Likewise.
2549 * tree-inline.c (copy_bb): Likewise.
2550 * tree-ssa-structalias.c (ipa_pta_execute): Likewise.
2551 * varpool.c (symbol_table::remove_unreferenced_decls): Likewise.
2553 2020-01-08 Richard Biener <rguenther@suse.de>
2556 * tree-eh.c (sink_clobbers): Update virtual operands for
2557 the first and last stmt only. Add a dry-run capability.
2558 (pass_lower_eh_dispatch::execute): Perform clobber sinking
2559 after CFG manipulations and in RPO order to catch all
2560 secondary opportunities reliably.
2562 2020-01-08 Georg-Johann Lay <avr@gjlay.de>
2565 * doc/invoke.texi (AVR Options) <-nodevicespecs>: Document.
2567 2019-01-08 Richard Biener <rguenther@suse.de>
2570 * gimple-fold.c (rewrite_to_defined_overflow): Mark stmt modified.
2571 * tree-ssa-loop-im.c (move_computations_worker): Properly adjust
2572 virtual operand, also updating SSA use.
2573 * gimple-loop-interchange.cc (loop_cand::undo_simple_reduction):
2574 Update stmt after resetting virtual operand.
2575 (tree_loop_interchange::move_code_to_inner_loop): Likewise.
2576 * gimple-iterator.c (gsi_remove): When not removing the stmt
2577 permanently do not delink immediate uses or mark the stmt modified.
2579 2020-01-08 Martin Liska <mliska@suse.cz>
2581 * ipa-fnsummary.c (dump_ipa_call_summary): Use symtab_node::dump_name.
2582 (ipa_call_context::estimate_size_and_time): Likewise.
2583 (inline_analyze_function): Likewise.
2585 2020-01-08 Martin Liska <mliska@suse.cz>
2587 * cgraph.c (cgraph_node::dump): Use systematically
2590 2020-01-08 Georg-Johann Lay <avr@gjlay.de>
2592 Add -nodevicespecs option for avr.
2595 * config/avr/avr.opt (-nodevicespecs): New driver option.
2596 * config/avr/driver-avr.c (avr_devicespecs_file): Only issue
2597 "-specs=device-specs/..." if that option is not set.
2598 * doc/invoke.texi (AVR Options) <-nodevicespecs>: Document.
2600 2020-01-08 Georg-Johann Lay <avr@gjlay.de>
2602 Implement 64-bit double functions for avr.
2605 * config.gcc (tm_defines) [target=avr]: Support --with-libf7,
2606 --with-double-comparison.
2607 * doc/install.texi: Document them.
2608 * config/avr/avr-c.c (avr_cpu_cpp_builtins)
2609 <WITH_LIBF7_LIBGCC, WITH_LIBF7_MATH, WITH_LIBF7_MATH_SYMBOLS>
2610 <WITH_DOUBLE_COMPARISON>: New built-in defines.
2611 * doc/invoke.texi (AVR Built-in Macros): Document them.
2612 * config/avr/avr-protos.h (avr_float_lib_compare_returns_bool): New.
2613 * config/avr/avr.c (avr_float_lib_compare_returns_bool): New function.
2614 * config/avr/avr.h (FLOAT_LIB_COMPARE_RETURNS_BOOL): New macro.
2616 2020-01-08 Richard Earnshaw <rearnsha@arm.com>
2619 * config/arm/t-multilib (MULTILIB_MATCHES): Add rules to match
2620 armv7-a{+mp,+sec,+mp+sec} to appropriate armv7 multilib variants
2621 when only building rm-profile multilibs.
2623 2020-01-08 Feng Xue <fxue@os.amperecomputing.com>
2626 * ipa-cp.c (self_recursively_generated_p): Find matched aggregate
2627 lattice for a value to check.
2628 (propagate_vals_across_arith_jfunc): Add an assertion to ensure
2629 finite propagation in self-recursive scc.
2631 2020-01-08 Luo Xiong Hu <luoxhu@linux.ibm.com>
2633 * ipa-inline.c (caller_growth_limits): Restore the AND.
2635 2020-01-07 Andrew Stubbs <ams@codesourcery.com>
2637 * config/gcn/gcn-valu.md (VEC_1REG_INT_ALT): Delete iterator.
2638 (VEC_ALLREG_ALT): New iterator.
2639 (VEC_ALLREG_INT_MODE): New iterator.
2640 (VCMP_MODE): New iterator.
2641 (VCMP_MODE_INT): New iterator.
2642 (vec_cmpu<mode>di): Use VCMP_MODE_INT.
2643 (vec_cmp<u>v64qidi): New define_expand.
2644 (vec_cmp<mode>di_exec): Use VCMP_MODE.
2645 (vec_cmpu<mode>di_exec): New define_expand.
2646 (vec_cmp<u>v64qidi_exec): New define_expand.
2647 (vec_cmp<mode>di_dup): Use VCMP_MODE.
2648 (vec_cmp<mode>di_dup_exec): Use VCMP_MODE.
2649 (vcond<VEC_ALL1REG_MODE:mode><VEC_1REG_ALT:mode>): Rename ...
2650 (vcond<VEC_ALLREG_MODE:mode><VEC_ALLREG_ALT:mode>): ... to this.
2651 (vcond<VEC_ALL1REG_MODE:mode><VEC_1REG_ALT:mode>_exec): Rename ...
2652 (vcond<VEC_ALLREG_MODE:mode><VEC_ALLREG_ALT:mode>_exec): ... to this.
2653 (vcondu<VEC_ALL1REG_MODE:mode><VEC_1REG_INT_ALT:mode>): Rename ...
2654 (vcondu<VEC_ALLREG_MODE:mode><VEC_ALLREG_INT_MODE:mode>): ... to this.
2655 (vcondu<VEC_ALL1REG_MODE:mode><VEC_1REG_INT_ALT:mode>_exec): Rename ...
2656 (vcondu<VEC_ALLREG_MODE:mode><VEC_ALLREG_INT_MODE:mode>_exec): ... to
2658 * config/gcn/gcn.c (print_operand): Fix 8 and 16 bit suffixes.
2659 * config/gcn/gcn.md (expander): Add sign_extend and zero_extend.
2661 2020-01-07 Andrew Stubbs <ams@codesourcery.com>
2663 * config/gcn/constraints.md (DA): Update description and match.
2665 (Db): New constraint.
2666 * config/gcn/gcn-protos.h (gcn_inline_constant64_p): Add second
2668 * config/gcn/gcn.c (gcn_inline_constant64_p): Add 'mixed' parameter.
2669 Implement 'Db' mixed immediate type.
2670 * config/gcn/gcn-valu.md (addcv64si3<exec_vcc>): Rework constraints.
2671 (addcv64si3_dup<exec_vcc>): Delete.
2672 (subcv64si3<exec_vcc>): Rework constraints.
2673 (addv64di3): Rework constraints.
2674 (addv64di3_exec): Rework constraints.
2675 (subv64di3): Rework constraints.
2676 (addv64di3_dup): Delete.
2677 (addv64di3_dup_exec): Delete.
2678 (addv64di3_zext): Rework constraints.
2679 (addv64di3_zext_exec): Rework constraints.
2680 (addv64di3_zext_dup): Rework constraints.
2681 (addv64di3_zext_dup_exec): Rework constraints.
2682 (addv64di3_zext_dup2): Rework constraints.
2683 (addv64di3_zext_dup2_exec): Rework constraints.
2684 (addv64di3_sext_dup2): Rework constraints.
2685 (addv64di3_sext_dup2_exec): Rework constraints.
2687 2020-01-07 Andre Vieira <andre.simoesdiasvieira@arm.com>
2689 * doc/sourcebuild.texi (arm_little_endian, arm_nothumb): Documented
2690 existing target checks.
2692 2020-01-07 Richard Biener <rguenther@suse.de>
2694 * doc/install.texi: Bump minimal supported MPC version.
2696 2020-01-07 Richard Sandiford <richard.sandiford@arm.com>
2698 * langhooks-def.h (lhd_simulate_enum_decl): Declare.
2699 (LANG_HOOKS_SIMULATE_ENUM_DECL): Use it.
2700 * langhooks.c: Include stor-layout.h.
2701 (lhd_simulate_enum_decl): New function.
2702 * config/aarch64/aarch64-sve-builtins.cc (init_builtins): Call
2703 handle_arm_sve_h for the LTO frontend.
2704 (register_vector_type): Cope with null returns from pushdecl.
2706 2020-01-07 Richard Sandiford <richard.sandiford@arm.com>
2708 * config/aarch64/aarch64-protos.h (aarch64_sve::svbool_type_p)
2709 (aarch64_sve::nvectors_if_data_type): Replace with...
2710 (aarch64_sve::builtin_type_p): ...this.
2711 * config/aarch64/aarch64-sve-builtins.cc: Include attribs.h.
2712 (find_vector_type): Delete.
2713 (add_sve_type_attribute): New function.
2714 (lookup_sve_type_attribute): Likewise.
2715 (register_builtin_types): Add an "SVE type" attribute to each type.
2716 (register_tuple_type): Likewise.
2717 (svbool_type_p, nvectors_if_data_type): Delete.
2718 (mangle_builtin_type): Use lookup_sve_type_attribute.
2719 (builtin_type_p): Likewise. Add an overload that returns the
2720 number of constituent vector and predicate registers.
2721 * config/aarch64/aarch64.c (aarch64_sve_argument_p): Delete.
2722 (aarch64_returns_value_in_sve_regs_p): Use aarch64_sve::builtin_type_p
2723 instead of aarch64_sve_argument_p.
2724 (aarch64_takes_arguments_in_sve_regs_p): Likewise.
2725 (aarch64_pass_by_reference): Likewise.
2726 (aarch64_function_value_1): Likewise.
2727 (aarch64_return_in_memory): Likewise.
2728 (aarch64_layout_arg): Likewise.
2730 2020-01-07 Jakub Jelinek <jakub@redhat.com>
2732 PR tree-optimization/93156
2733 * tree-ssa-ccp.c (bit_value_binop): For x * x note that the second
2734 least significant bit is always clear.
2736 PR tree-optimization/93118
2737 * match.pd ((x >> c) << c -> x & (-1<<c)): Add nop_convert?. Add new
2738 simplifier with two intermediate conversions.
2740 2020-01-07 Martin Liska <mliska@suse.cz>
2742 * params.opt: Add Optimization for various parameters.
2744 2020-01-07 Martin Liska <mliska@suse.cz>
2747 * doc/extend.texi: Explain cloning for target_clone
2750 2020-01-07 Martin Liska <mliska@suse.cz>
2752 PR tree-optimization/92860
2753 * common.opt: Make in Optimization option
2754 as it is affected by -O0, which is an Optimization
2756 * tree-inline.c (tree_inlinable_function_p):
2757 Use opt_for_fn for warn_inline.
2758 (expand_call_inline): Likewise.
2760 2020-01-07 Martin Liska <mliska@suse.cz>
2762 PR tree-optimization/92860
2763 * common.opt: Make flag_ree as optimization
2766 2020-01-07 Martin Liska <mliska@suse.cz>
2768 PR optimization/92860
2769 * params.opt: Mark param_min_crossjump_insns with Optimization
2772 2020-01-07 Luo Xiong Hu <luoxhu@linux.ibm.com>
2774 * ipa-inline-analysis.c (estimate_growth): Fix typo.
2775 * ipa-inline.c (caller_growth_limits): Use OR instead of AND.
2777 2020-01-06 Michael Meissner <meissner@linux.ibm.com>
2779 * config/rs6000/rs6000.c (hard_reg_and_mode_to_addr_mask): New
2780 helper function to return the valid addressing formats for a given
2781 hard register and mode.
2782 (rs6000_adjust_vec_address): Call hard_reg_and_mode_to_addr_mask.
2784 * config/rs6000/constraints.md (Q constraint): Update
2786 * doc/md.texi (RS/6000 constraints): Update 'Q' cosntraint
2789 * config/rs6000/vsx.md (vsx_extract_<mode>_var, VSX_D iterator):
2790 Use 'Q' for doing vector extract from memory.
2791 (vsx_extract_v4sf_var): Use 'Q' for doing vector extract from
2793 (vsx_extract_<mode>_var, VSX_EXTRACT_I iterator): Use 'Q' for
2794 doing vector extract from memory.
2795 (vsx_extract_<mode>_<VS_scalar>mode_var): Use 'Q' for doing vector
2796 extract from memory.
2798 * config/rs6000/rs6000.c (rs6000_adjust_vec_address): Add support
2799 for the offset being 34-bits when -mcpu=future is used.
2801 2020-01-06 John David Anglin <danglin@gcc.gnu.org>
2803 * config/pa/pa.md: Revert change to use ordered_comparison_operator
2804 instead of cmpib_comparison_operator in cmpib patterns.
2805 * config/pa/predicates.md (cmpib_comparison_operator): Revert removal
2806 of cmpib_comparison_operator. Revise comment.
2808 2020-01-06 Richard Sandiford <richard.sandiford@arm.com>
2810 * tree-vect-slp.c (vect_build_slp_tree_1): Require all shifts
2811 in an IFN_DIV_POW2 node to be equal.
2813 2020-01-06 Richard Sandiford <richard.sandiford@arm.com>
2815 * tree-vect-stmts.c (vect_check_load_store_mask): Rename to...
2816 (vect_check_scalar_mask): ...this.
2817 (vectorizable_store, vectorizable_load): Update call accordingly.
2818 (vectorizable_call): Use vect_check_scalar_mask to check the mask
2819 argument in calls to conditional internal functions.
2821 2020-01-06 Andrew Stubbs <ams@codesourcery.com>
2823 * config/gcn/gcn-valu.md (subv64di3): Use separate alternatives for
2824 '0' matching inputs.
2825 (subv64di3_exec): Likewise.
2827 2020-01-06 Bryan Stenson <bryan@siliconvortex.com>
2829 * config/mips/mips.c (vr4130_align_insns): Fix typo.
2830 * doc/md.texi (movstr): Likewise.
2832 2020-01-06 Andrew Stubbs <ams@codesourcery.com>
2834 * config/gcn/gcn-valu.md (vec_extract<mode><scalar_mode>): Add early
2837 2020-01-06 Richard Sandiford <richard.sandiford@arm.com>
2839 * config/aarch64/t-aarch64 ($(srcdir)/config/aarch64/aarch64-tune.md):
2841 (s-aarch64-tune-md): ...this new stamp file. Pipe the new contents
2842 to a temporary file and use move-if-change to update the real
2843 file where necessary.
2845 2020-01-06 Richard Sandiford <richard.sandiford@arm.com>
2847 * config/aarch64/aarch64-sve.md (@aarch64_sel_dup<mode>): Use Upl
2848 rather than Upa for CPY /M.
2850 2020-01-06 Andrew Stubbs <ams@codesourcery.com>
2852 * config/gcn/gcn.c (gcn_inline_constant_p): Allow 64 as an inline
2855 2020-01-06 Martin Liska <mliska@suse.cz>
2857 PR tree-optimization/92860
2858 * params.opt: Mark param_max_combine_insns with Optimization
2861 2020-01-05 Jakub Jelinek <jakub@redhat.com>
2864 * config/i386/i386.md (SWIDWI): New mode iterator.
2865 (DWI, dwi): Add TImode variants.
2866 (addv<mode>4): Use SWIDWI iterator instead of SWI. Use
2867 <general_hilo_operand> instead of <general_operand>. Use
2868 CONST_SCALAR_INT_P instead of CONST_INT_P.
2869 (*addv<mode>4_1): Rename to ...
2870 (addv<mode>4_1): ... this.
2871 (QWI): New mode attribute.
2872 (*addv<dwi>4_doubleword, *addv<dwi>4_doubleword_1): New
2873 define_insn_and_split patterns.
2874 (*addv<mode>4_overflow_1, *addv<mode>4_overflow_2): New define_insn
2876 (uaddv<mode>4): Use SWIDWI iterator instead of SWI. Use
2877 <general_hilo_operand> instead of <general_operand>.
2878 (*addcarry<mode>_1): New define_insn.
2879 (*add<dwi>3_doubleword_cc_overflow_1): New define_insn_and_split.
2881 2020-01-03 Konstantin Kharlamov <Hi-Angel@yandex.ru>
2883 * gdbinit.in (pr, prl, pt, pct, pgg, pgq, pgs, pge, pmz, pdd, pbs, pbm):
2884 Use "call" instead of "set".
2886 2020-01-03 Martin Jambor <mjambor@suse.cz>
2889 * ipa-cp.c (print_all_lattices): Skip functions without info.
2891 2020-01-03 Jakub Jelinek <jakub@redhat.com>
2894 * config/i386/i386-options.c (ix86_simd_clone_adjust): If
2895 TARGET_PREFER_AVX128, use prefer-vector-width=256 for 'c' and 'd'
2896 simd clones. If TARGET_PREFER_AVX256, use prefer-vector-width=512
2897 for 'e' simd clones.
2900 * config/i386/i386.opt (x_prefer_vector_width_type): Remove TargetSave
2902 (mprefer-vector-width=): Add Save.
2903 * config/i386/i386-options.c (ix86_target_string): Add PVW argument, print
2904 -mprefer-vector-width= if non-zero. Fix up -mfpmath= comment.
2905 (ix86_debug_options, ix86_function_specific_print): Adjust
2906 ix86_target_string callers.
2907 (ix86_valid_target_attribute_inner_p): Handle prefer-vector-width=.
2908 (ix86_valid_target_attribute_tree): Likewise.
2909 * config/i386/i386-options.h (ix86_target_string): Add PVW argument.
2910 * config/i386/i386-expand.c (ix86_expand_builtin): Adjust
2911 ix86_target_string caller.
2914 * config/i386/i386.md (abs<mode>2): Use expand_simple_binop instead of
2915 emitting ASHIFTRT, XOR and MINUS by hand. Use gen_int_mode with QImode
2916 instead of gen_int_shift_amount + convert_modes.
2918 PR rtl-optimization/93088
2919 * loop-iv.c (find_single_def_src): Punt after looking through
2920 128 reg copies for regs with single definitions. Move definitions
2923 2020-01-02 Dennis Zhang <dennis.zhang@arm.com>
2925 * config/arm/arm-c.c (arm_cpu_builtins): Define
2926 __ARM_FEATURE_MATMUL_INT8, __ARM_FEATURE_BF16_VECTOR_ARITHMETIC,
2927 __ARM_FEATURE_BF16_SCALAR_ARITHMETIC, and
2928 __ARM_BF16_FORMAT_ALTERNATIVE when enabled.
2929 * config/arm/arm-cpus.in (armv8_6, i8mm, bf16): New features.
2930 * config/arm/arm-tables.opt: Regenerated.
2931 * config/arm/arm.c (arm_option_reconfigure_globals): Initialize
2932 arm_arch_i8mm and arm_arch_bf16 when enabled.
2933 * config/arm/arm.h (TARGET_I8MM): New macro.
2934 (TARGET_BF16_FP, TARGET_BF16_SIMD): Likewise.
2935 * config/arm/t-aprofile: Add matching rules for -march=armv8.6-a.
2936 * config/arm/t-arm-elf (all_v8_archs): Add armv8.6-a.
2937 * config/arm/t-multilib: Add matching rules for -march=armv8.6-a.
2938 (v8_6_a_simd_variants): New.
2939 (v8_*_a_simd_variants): Add i8mm and bf16.
2940 * doc/invoke.texi (armv8.6-a, i8mm, bf16): Document new options.
2942 2020-01-02 Jakub Jelinek <jakub@redhat.com>
2945 * predict.c (compute_function_frequency): Don't call
2946 warn_function_cold on functions that already have cold attribute.
2948 2020-01-01 John David Anglin <danglin@gcc.gnu.org>
2951 * config/pa/pa.c (pa_elf_select_rtx_section): New. Put references to
2952 COMDAT group function labels in .data.rel.ro.local section.
2953 * config/pa/pa32-linux.h (TARGET_ASM_SELECT_RTX_SECTION): Define.
2956 * config/pa/pa.md (scc): Use ordered_comparison_operator instead of
2957 comparison_operator in B and S integer comparisons. Likewise, use
2958 ordered_comparison_operator instead of cmpib_comparison_operator in
2960 * config/pa/predicates.md (cmpib_comparison_operator): Remove.
2962 2020-01-01 Jakub Jelinek <jakub@redhat.com>
2964 Update copyright years.
2966 * gcc.c (process_command): Update copyright notice dates.
2967 * gcov-dump.c (print_version): Ditto.
2968 * gcov.c (print_version): Ditto.
2969 * gcov-tool.c (print_version): Ditto.
2970 * gengtype.c (create_file): Ditto.
2971 * doc/cpp.texi: Bump @copying's copyright year.
2972 * doc/cppinternals.texi: Ditto.
2973 * doc/gcc.texi: Ditto.
2974 * doc/gccint.texi: Ditto.
2975 * doc/gcov.texi: Ditto.
2976 * doc/install.texi: Ditto.
2977 * doc/invoke.texi: Ditto.
2979 2020-01-01 Jan Hubicka <hubicka@ucw.cz>
2981 * ipa.c (walk_polymorphic_call_targets): Fix updating of overall
2984 2020-01-01 Jakub Jelinek <jakub@redhat.com>
2986 PR tree-optimization/93098
2987 * match.pd (popcount): For shift amounts, use integer_onep
2988 or wi::to_widest () == cst instead of tree_to_uhwi () == cst
2989 tests. Make sure that precision is power of two larger than or equal
2990 to 16. Ensure shift is never negative. Use HOST_WIDE_INT_UC macro
2991 instead of ULL suffixed constants. Formatting fixes.
2993 Copyright (C) 2020 Free Software Foundation, Inc.
2995 Copying and distribution of this file, with or without modification,
2996 are permitted in any medium without royalty provided the copyright
2997 notice and this notice are preserved.