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